Fixed the above.
program PennyAuctionBidClicker;
begin
Repeat
If (GetColor(X,Y)=Color) and (GetColor(X,Y)=Color) and (GetColor(X,Y)=Color) and (GetColor(X,Y)=Color) and (GetColor(X,Y)=Color)
and NOT (GetColor(X,Y)=BadColor) then
begin
ClickMouse(X,Y,True);
Wait(8000)...