Versuch es mal so:
Code:
procedure TForm1.FormCreate(Sender: TObject);
begin
Randomize;
Progressbar1.Max := Width;
Progressbar2.Max := Height;
end;
procedure TForm1.Timer1Timer(Sender: TObject);
var
x, y: DWORD;
begin
x := Random(Width);
y := Random(Height);
Form1.Canvas.Pixels[x,y] := clRed;
Form1.Canvas.Pixels[x+1,y+1] := clRed;
Form1.Canvas.Pixels[x+1,y] := clRed;
Form1.Canvas.Pixels[x,y+1] := clRed;
Progressbar1.Position := x;
Progressbar2.Position := y;
end;
Schöne Animation mit den Progessbars.