SRL Archive - OSR Help

Walking help


Thief

2013-04-29 09:39:08

Hey, so I'm clicking in an unwalkable area and using
flag;
to wait until it reaches the bank before it searches for the bankers. It works ok, but the trouble is, it's sort of slow. It walks to the bank, waits for like 5 seconds before actually banking (because the flag remains on the mini map).

Could i use something like
Wait (until is not moving);
^^ not sure what it actually is, but have seen something similar used in another script somewhere. Thanks :D

Sjoe

2013-04-29 09:47:58


while IsMoving do Wait(100);

or



WaitNotMoving(False);


Same thing :)

Thief

2013-04-29 10:24:45

Awesome, thanks! Will try this out :D

Edit:
 WaitNotMoving(False);
Didn't work for some reason but

      while IsMoving do Wait(100); 

works perferctly. Thanks.

King

2013-04-29 10:43:15

From: pure_thief
Awesome, thanks! Will try this out :D

Edit:
 WaitNotMoving(False);
Didn't work for some reason but

      while IsMoving do Wait(100); 

works perferctly. Thanks.


You can also use

Procedure WaitWhileWalking;
var
X: integer;
Begin
while ismoving do
Begin
Marktime(x);
Repeat
Wait(randomrange(25,75));
Until(FFlag(1)or (Timefrommark(x)>= 25000));
End;
End;

That will repeatedly wait between 25,75 milk seconds before checking the distance from the flag. It will repeat that until you reach the flag distance of 1 or you hit 25 seconds. You can change the distance from the flag by changing E number in FFlag();

Sorry for any stupid errors, I'm on my ipad :D

t4q

2013-04-29 11:29:26

You can use just
Fflag(2);
It waits until your distance from red flag on minimap is 2..

Sjoe

2013-04-29 11:52:57

Yeah just use FFlag(1); or FFlag(2); and add a Wait(550 + Random(100)); or something after it :)

but most of the time I use while Ismoving Do Wait(100);

Thief

2013-04-30 03:53:38

Sweet thanks for all the different ideas! I'll try them all out and see which works best :D

Chris!

2013-04-30 05:03:11

FFlag(); is a great option for less waiting when walking, definitely! I find it works better when running longish distances because it won't wait for my character to reach the point it clicked and will keep going. :)