SRL Archive - OSR Help

Help In The Final Stages :)


GREEN GIANT

2013-07-30 15:30:44

Hi Everyone,

After many hours, and over 800 lines of script i finally have a working BOT that completes its runs 90% of the time :) Im just in the stages of letting it run and watching for potential areas that require fail-safes.

Anyway, when i started this script i had no intention of finishing and so used procedures such as Mouse and MMouse for my mouse movement and clicking selections.

What should i use instead of Mouse and MMouse, and are there any other "No No" procedures or functions that i should have avoided?

I now fully intend on using my script and so obviously dont want to get banned :) So any suggestions as to Proceduress and functions to avoid is greatly appreciated.

Thanks.

Rich

2013-07-30 16:09:09

Mouse and MMouse are perfectly fine to use; it's MouseMouse and ClickMouse you want to stay away from, and SendKeys :)

GREEN GIANT

2013-07-30 17:39:21

From: Rich
Mouse and MMouse are perfectly fine to use; it's MouseMouse and ClickMouse you want to stay away from, and SendKeys :)


Oh Right, its just that i see people using something similar to SRL_LeftClick, or something.

I do notice that sometimes the mouse quite clearly comes from 0,0 and crosses the screen, this looks very Botty to me :(

Rich

2013-07-30 17:45:36

ClickMouse2? I should've said that's fine to use as well. All it does it click where the mouse is when it gets called.
You've probably seen mouse_Left and mouse_Right being used. These are simply constants to be used when using something like ClickMouse2.
Eg: ClickMouse2(mouse_Left) will left click the mouse at it's current position.

The mouse shouldn't come from 0,0 no matter what mouse moving procedure you use; they move it from the current position.
Is it someone else's script you're using, or your own?

GREEN GIANT

2013-07-30 18:50:36

From: Rich
ClickMouse2? I should've said that's fine to use as well. All it does it click where the mouse is when it gets called.
You've probably seen mouse_Left and mouse_Right being used. These are simply constants to be used when using something like ClickMouse2.
Eg: ClickMouse2(mouse_Left) will left click the mouse at it's current position.

The mouse shouldn't come from 0,0 no matter what mouse moving procedure you use; they move it from the current position.
Is it someone else's script you're using, or your own?


My own script, i think the Mouse Moving from 0,0 is done when finding a DTM, it moves to position 0,0 before moving across the screen to click the MiniMap, its rather odd.

Rich

2013-07-30 19:21:35

Could you show us the code, so hopefully we can figure out why it's doing that?

Sjoe

2013-07-30 19:26:19

From: GREEN GIANT
My own script, i think the Mouse Moving from 0,0 is done when finding a DTM, it moves to position 0,0 before moving across the screen to click the MiniMap, its rather odd.


Probably cause it doesn't find the dtm. does your code look like:


FindDTM(x,y, ....);
Mouse(x, y, 1, 1, true);
//x,y = 0,0 by default. If it can't find the dtm it will move to 0,0

Instead go for this:

if FindDTM(x, y,...) then
begin
Writeln('Found the dtm');
Mouse(x, y, 1, 1, True);
end else Writeln('Did not find the dtm');

// now it won't move/click the mouse if the dtm isn't found