SRL Archive - General Botting Help

Issue with timing


kladinko

2015-02-24 09:51:23

I'm currently trying to perform the special move from a familiar on each item in the backpack (up until slot 26), however the time it takes to move from slot to slot, performing the special move seems to change despite there currently being no reason to,

TypeSend('=',False);
wait(randomRange(350,445));
tabBackpack.mouseSlot(i, MOUSE_LEFT);
wait(randomRange(350,445));

Timing is off here


TypeSend('=',False);
wait(randomRange(800,800));
tabBackPack.mouseSlot(#, MOUSE_LEFT);

Having this for each inventory slot also doesn't seem to work

Both seem to change, for instance it will perform the special move on slot 1 then 2 but then at maybe slot 3 it won't perform it, I've changed the wait time to 2000 and it all seems to work then, but any faster and it doesn't and I can't seem to get my head round it, I'm very new to this though haha so I'm probably missing something obvious or doing something wrong


Simba tags in this post don't seem to be working

3Garrett3

2015-02-24 10:37:17

From: kladinko
I'm currently trying to perform the special move from a familiar on each item in the backpack (up until slot 26), however the time it takes to move from slot to slot, performing the special move seems to change despite there currently being no reason to,

TypeSend('=',False);
wait(randomRange(350,445));
tabBackpack.mouseSlot(i, MOUSE_LEFT);
wait(randomRange(350,445));

Timing is off here


TypeSend('=',False);
wait(randomRange(800,800));
tabBackPack.mouseSlot(#, MOUSE_LEFT);

Having this for each inventory slot also doesn't seem to work

Both seem to change, for instance it will perform the special move on slot 1 then 2 but then at maybe slot 3 it won't perform it, I've changed the wait time to 2000 and it all seems to work then, but any faster and it doesn't and I can't seem to get my head round it, I'm very new to this though haha so I'm probably missing something obvious or doing something wrong


Simba tags in this post don't seem to be working


Can you post the entire loop? Use
 and 
without the space before the / for the tags, it should work.

Also if you're doing "Wait(randomRange(800,800))" you could just "wait(800)" instead. I assume you just put 800, 800 so that you knew it wasn't the random that was breaking stuff though. I'm assuming that there is something else in your loop that might be adding random failure to it.

It could also be that the animation time in RS is larger than 800ms, so it's sometimes not working with the button because RS is still doing the animation. You should figure out the exact time that you can actually press the button if you're going through each slot. The other option is if it's like the superheat command, you can click the last item every time and it changes the first then second etc, so you could do it that way and just click like mad if it works.

kladinko

2015-02-24 10:56:26

From: 3Garrett3
Can you post the entire loop? Use
 and 
without the space before the / for the tags, it should work.

Also if you're doing "Wait(randomRange(800,800))" you could just "wait(800)" instead. I assume you just put 800, 800 so that you knew it wasn't the random that was breaking stuff though. I'm assuming that there is something else in your loop that might be adding random failure to it.

It could also be that the animation time in RS is larger than 800ms, so it's sometimes not working with the button because RS is still doing the animation. You should figure out the exact time that you can actually press the button if you're going through each slot. The other option is if it's like the superheat command, you can click the last item every time and it changes the first then second etc, so you could do it that way and just click like mad if it works.


Yea I had it the same to make sure it wasn't that, I was thinking it could have been the animation but it stops working on random slots, sometimes it may work correctly on 24 of the 26 slots and others only 10, and it has to be done on all individually, the special move changes the egg you click you see

The script is found here https://villavu.com/forum/showthread.php?t=112073 , Made by Neva Banned, didn't want to post it here as he hasn't posted it out of Junior Members

3Garrett3

2015-02-24 11:41:15

From: kladinko
Yea I had it the same to make sure it wasn't that, I was thinking it could have been the animation but it stops working on random slots, sometimes it may work correctly on 24 of the 26 slots and others only 10, and it has to be done on all individually, the special move changes the egg you click you see

The script is found here https://villavu.com/forum/showthread.php?t=112073 , Made by Neva Banned, didn't want to post it here as he hasn't posted it out of Junior Members


In my experience, if the timing on something is "random" then it's probably a RS thing. I would simply increase the wait time to find the minimum time that it will actually work 100% of the time. Then you can do wait(randomRange(minT, minT + 500)) with whatever you find the minT to be. Or time yourself doing it manually and see what time you normally wait when you do it, then write the loop to have exactly that timing + a random amount.

kladinko

2015-02-24 11:58:15

From: 3Garrett3
In my experience, if the timing on something is "random" then it's probably a RS thing. I would simply increase the wait time to find the minimum time that it will actually work 100% of the time. Then you can do wait(randomRange(minT, minT + 500)) with whatever you find the minT to be. Or time yourself doing it manually and see what time you normally wait when you do it, then write the loop to have exactly that timing + a random amount.


Using minT works much better,thank you for the help,although what is the difference though between (1000,1000 + 500) and (1000,1500)? Shouldn't it be exactly the same?

3Garrett3

2015-02-24 12:18:19

From: kladinko
Using minT works much better,thank you for the help,although what is the difference though between (1000,1000 + 500) and (1000,1500)? Shouldn't it be exactly the same?


It is the exact same. You can use 1500, I just didn't have any better way to try explaining it. If your minT you find is about 1000, then the range can be (1000,1500) or whatever maximum you want as long as the low end of the range is the min time that is successful every time.

Trollcrank

2015-02-24 13:11:49

Seems like you have this figured out but sometimes a second, different, explanation can help.

Basically the random range of waited time is not long enough to succeed every time. So increase the minimum range and adjust accordingly until you can get it to work properly OR time the action/google the timing and adjust the wait time to the numbers you find and test it.
Example: if the code works sometimes then that means that the minimum range is to short

wait(randomRange(350,445));
wait(randomRange(Minimum Wait Time,Maximum Wait Time));
Try increasing the minimum wait time and the maximum time a little bit(you adjust the max time so that there is still randomness)

wait(randomRange(425,550));