ABC!
05-27-2012, 08:04 AM
Title, says it all really, im trying to put a failsafe into place, if it cant find any toads in the loaction its at i want it to move so I try to use 'findcolorspiraltolerance', but it doesnt do anything :/
Function PickUpFrog:Boolean;
begin
repeat
FindNormalRandoms
if FindObjCustom(x, y, ['Swamp', 'toad'], [2189375], 10) then
begin
Wait(500 + random(100));
Mouse(x, y, 0, 0, false);
ChooseOption('Take');
end else
begin
writeln('Cannot find any Toads, Moving to another spot!');
x := MMCX;
y := MMCY;
if (FindColorSpiralTolerance(x, y, 208 , 1, 2, 1, 2, 7)) then
Mouse(x, y, 0, 0, True);
end;
begin
repeat
until not IsUpText('toad') or (InvFull);
end;
until(InvFull);
end;
Debug Box:
Cannot find any Toads, Moving to another spot!
Cannot find any Toads, Moving to another spot!
Cannot find any Toads, Moving to another spot!
Cannot find any Toads, Moving to another spot!
Cannot find any Toads, Moving to another spot!
Function PickUpFrog:Boolean;
begin
repeat
FindNormalRandoms
if FindObjCustom(x, y, ['Swamp', 'toad'], [2189375], 10) then
begin
Wait(500 + random(100));
Mouse(x, y, 0, 0, false);
ChooseOption('Take');
end else
begin
writeln('Cannot find any Toads, Moving to another spot!');
x := MMCX;
y := MMCY;
if (FindColorSpiralTolerance(x, y, 208 , 1, 2, 1, 2, 7)) then
Mouse(x, y, 0, 0, True);
end;
begin
repeat
until not IsUpText('toad') or (InvFull);
end;
until(InvFull);
end;
Debug Box:
Cannot find any Toads, Moving to another spot!
Cannot find any Toads, Moving to another spot!
Cannot find any Toads, Moving to another spot!
Cannot find any Toads, Moving to another spot!
Cannot find any Toads, Moving to another spot!