procedure TForm1.FormActivate(Sender: TObject);
var a, x, y : Integer;
Bild : array [1..4, 1..12, 1..12] of TImage;
begin
for a := 1 to 4 do
for x := 1 to 12 do
for y := 1 to 12 do
begin
Bild[a, x, y] := TImage.Create(Self);
Bild[a, x, y].Height := 15;
Bild[a, x, y].Width := 15;
if a = 1 then
begin
Bild[a, x, y].Top := y * 15 + 1;
Bild[a, x, y].Left := x * 15 + 1;
end;
if a = 2 then
begin
Bild[a, x, y].Top := y * 15 + 1 + 195;
Bild[a, x, y].Left := x * 15 + 1;
end;
if a = 3 then
begin
Bild[a, x, y].Top := y * 15 + 1;
Bild[a, x, y].Left := x * 15 + 1 + 195;
end;
if a = 4 then
begin
Bild[a, x, y].Top := y * 15 + 1 + 195;
Bild[a, x, y].Left := x * 15 + 1 + 195;
end;
end;
Bild[1, 1, 1].Picture.LoadFromFile('C:\Program Files\Borland\Delphi6\Projects\MazeMaker\images\none.bmp');
for a := 2 to 4 do
for x := 1 to 12 do
for y := 1 to 12 do
Bild[a, x, y].Picture.Assign(Bild[1, 1, 1].Picture);
a := 1;
for x := 2 to 12 do
for y := 1 to 12 do
Bild[a, x, y].Picture.Assign(Bild[1, 1, 1].Picture);
x := 1;
for y := 2 to 12 do
Bild[a, x, y].Picture.Assign(Bild[1, 1, 1].Picture);
end;