rsbots2013
2013-05-28 19:10:53
I wanted my script to find a 1. find a color 2. move mouse to color 3. right click color 4. click option 5. go to next procedure. 6. I got if fails all over so if it fails it restarts procedure.
Problem: it keeps restarting when it shouldn't and I don't understand why it's doing it.
Problem: it keeps restarting when it shouldn't and I don't understand why it's doing it.
procedure LeavingBalancingLedgeRoomLadder;
var
x, y : integer;
aFound : extended;
begin
MakeCompass('S');
SetAngle(SRL_ANGLE_HIGH);
Wait(1500);
if FindColorSpiralTolerance( x, y, LedgeLadder, 190, 87, 339, 185, 5) then
// If finds Ladder
begin
MoveMouse( x, y);
end else
begin
WriteLn('Failed to Find Ladder');
LeavingBalancingLedgeRoomLadder;
end;
if WaitUptextMulti(['Clim', 'limb', 'dow'], 600) then
begin
WriteLn('Found Balancing Ladder');
Mouse( x, y, 0, 0, False);
Wait(1000);
end else
begin
WriteLn('Failed to Find Ladder');
LeavingBalancingLedgeRoomLadder;
end;
if WaitOptionMulti(['Clim', 'limb', 'b-d'], 600) then
begin
WriteLn('Successfully Clicked on Ladder!');
Exit;
end;
end;