var x, y : integer;
Procedure FindImage;
begin
if (FindColor(x, y, 1392284, 0, 0, 1023, 767)) then
begin
writeln('FOUND COLOR!')
MoveMouse(x, y)
wait(300)
ClickMouse(x, y, true)
end;
end;
begin
repeat
wait(200)
FindImage;
wait(1000)
until(false)
end.