WPI 1801 (Replica)

Скрипт WPI 1801 (Replica) 17.08

Нет прав для скачивания
code_language.pascal:
procedure OnProcess(Sender: TObject);
begin
  if Round(Slide[Counter].GetCurrentTime) = 30 then
  if Counter = {#Background} then
  begin
    SlideFade[Counter + 1].Enabled(True);
  end else
  begin
    SlideFade[Counter + 1].Enabled(True);
    Slide[Counter + 1].Enabled(True);
  end;
end;

procedure OnFinish(Sender: TObject);
var
  i: Integer;
begin
  if Counter = {#Background} then
  begin
  for i:= 1 to {#Background} + 1 do
  begin
    Slide[i].Enabled(False);
    SlideFade[i].Enabled(False);
    SlideShow[i].Opacity(0);
    SlideShow[i].Left(0);
  end;

    SlideShow[1].Opacity(1);
    Counter:= 1;
    Slide[Counter].Enabled(True);
  end else
  begin
    Counter:= Counter + 1;
  end;
end;

procedure FormOnShow(Sender: TObject);
var
  i, j: Integer;
begin
  for i:= 1 to {#Background} + 1 do
  begin
    SlideShow[i].FCreate(Background.Handle);
    SlideShow[i].SetBounds(0, 0, 1280, 720);
    SlideShow[i].Opacity(0);
    //
    Slide[i].FCreate(SlideShow[i].Handle);
    Slide[i].AnimationType(atIn, 32, 0, False, False, False);
    Slide[i].PropertyName('Position.X');
    Slide[i].SetValues(0, - 426);
    Slide[i].OnProcess(@OnProcess);
    //
    SlideFade[i].FCreate(SlideShow[i].Handle);
    SlideFade[i].AnimationType(atIn, 2, 0, False, False, False);
    SlideFade[i].PropertyName('Opacity');
    SlideFade[i].SetValues(0, 1);
    SlideFade[i].OnFinish(@OnFinish);
  end;

  for j:= 1 to {#Background} do
  begin
    SlideShow[j].FillPicture(ExtractAndLoad(IntToStr(j) + '.jpg'), wmTileStretch);
  end;

  SlideShow[{#Background} + 1].FillPicture(ExtractAndLoad('1.jpg'), wmTileStretch);
  SlideShow[1].Opacity(1);
  Counter:= 1;

  if SlideShow[Counter].GetLeft = 0 then
  begin
    Slide[Counter].Enabled(True);
  end;
end;
Thanks to @hitman797
  • Like
Реакции: hitman797
Сверху