Looks ok, probably gets the job done...
2 remarks though:
- You should replace the until (x=...) with until False, you're obviously trying to create an infinite loop, though your method works, I suppose, it requires a lot more processing power, which means more time to execute, which means it slows down the script... The until loop, loops until the statement validates as True, so while it's False, it will keep looping, simply putting False therefor suffices to make it loop.
- Also, try to keep in mind coding conventions, format your code with indentations and use proper capitalization for the functions
[scar]var
x, y, ballcolor: Integer;
begin
ballcolor := GetColor(324,91);
repeat
FindColor(x, y, ballcolor, 5, 4, 631, 449);
ClickMouse(x, y, True);
Wait(5 + Random(10));
until False;
end.[/scar]