SRL Archive - SRL Archives

PickUpMouse;


Dark_Sniper

2006-05-10 19:55:26

[PHP]procedure PickUpMouse;
var
cx, cy, XX, YY:integer;
begin
GetMousePos(cx, cy);
XX:= cx;
YY:= cy;
case Random(2) of
0: MMouse(cx- 3- random(5), cy- 8- random(17), 0, 0);
1: MMouse(cx+ 3+ random(5), cy- 8- random(17), 0, 0);
end;
Wait(1131+ random(358));
case Random(2) of
0: MMouse(XX+ 3+ random(5), YY+ 8+ random(9), 0, 0);
1: MMouse(XX- 3- random(5), YY+ 8+ random(9), 0, 0);
end;
end;[/PHP]

it acts just like you picked your mouse off the pad… then sets it back down.
simple but somthing i do pretty often in runescape.

WhiteShadow

2006-05-10 21:48:10

Tested it. Yea it really does look like you picked up the Mouse.

133t0rz. ;)

phantombmx

2006-05-11 02:07:55

use locals as much as possible ;) changed it to this.. (made it all local)

procedure PickUpMouse;
var cx, cy, XX, YY:integer;
begin
GetMousePos(X, Y);
XX:= cx;
YY:= cy;
case Random(2) of
0: MMouse(cx-3-random(5), cy-8-random(17), 0, 0);
1: MMouse(cx+3+random(5), cy-8-random(17), 0, 0);
end;
Wait(1131+random(358));
case Random(2) of
0: MMouse(XX+3+random(5), YY+8+random(9), 0, 0);
1: MMouse(XX-3-random(5), YY+8+random(9), 0, 0);
end;
end;

WT-Fakawi

2006-05-11 03:25:16

SRL Librarians: Add this to SRL AntiBan.scar please. Good idea.

Dark_Sniper

2006-05-11 06:51:42

From: phantombmx
use locals as much as possible ;) changed it to this.. (made it all local)

procedure PickUpMouse;
var cx, cy, XX, YY:integer;
begin
GetMousePos(X, Y);
XX:= cx;
YY:= cy;
case Random(2) of
0: MMouse(cx-3-random(5), cy-8-random(17), 0, 0);
1: MMouse(cx+3+random(5), cy-8-random(17), 0, 0);
end;
Wait(1131+random(358));
case Random(2) of
0: MMouse(XX+3+random(5), YY+8+random(9), 0, 0);
1: MMouse(XX-3-random(5), YY+8+random(9), 0, 0);
end;
end;


that would work… you forgot to change the getmousepos to cx.cy… otherwise it doesent have the mousae position.. and it just moves the mouse to near 0,0

so simple change but ya i forgot about locals.
[PHP]
procedure PickUpMouse;
var cx, cy, XX, YY:integer;
begin
GetMousePos(cx, cy);
XX:= cx;
YY:= cy;
case Random(2) of
0: MMouse(cx-3-random(5), cy-8-random(17), 0, 0);
1: MMouse(cx+3+random(5), cy-8-random(17), 0, 0);
end;
Wait(1131+random(358));
case Random(2) of
0: MMouse(XX+3+random(5), YY+8+random(9), 0, 0);
1: MMouse(XX-3-random(5), YY+8+random(9), 0, 0);
end;
end;[/PHP]

phantombmx

2006-05-11 12:13:22

woops :o but yeah nice procedure ;)

Dark_Sniper

2006-05-11 17:35:12

ya thanks and thanks for the local var thing i forgot about it.

Bebe

2006-05-11 19:01:30

Added :)

Nice idea Dark ;)

whitevans1

2006-05-11 21:31:41

Your 1337.. haha