metrop021
2006-06-26 18:52:34
I made this quite a while ago and I've been using it for quite a few months now… Might as well release it. The script checks the mouse position every 25+random(4) seconds, and if no change is detected it moves the mouse just enough to keep you logged in…
{antilogout by Metrop021
Based partially off of Bumis's antilogout tool
works the same way... checks mouse position every 30 seconds or so
and if it doesnt detect a change it will move the mouse for you
Also moves the mouse back onto the client if it is not on it}
program AntiLogout;
{.include SRL/SRL.scar}
var x1,x2,y1,y2,timesmoved,mousevar : integer;
const
setbenmouse = true; //use benland100's ownage mouse procedure
setmousespeed = 15; // i recommend 15 if using benmouse, 25 if not
procedure antilog1;
begin
if (x1 >= 763) or (x1 <= 0) or (y1 >= 502) or (y1 <= 0)
then
begin
mousevar := mousevar + 1
timesmoved := timesmoved + 1
writeln('Mouse is off of client, moving back to client; Mouse moved ' + inttostr(timesmoved) + ' time[s].')
MMouse(5,5,300,200)
end;
if (mousevar = 0)
then
begin
timesmoved := timesmoved + 1
writeln('Mouse moved ' + inttostr(timesmoved) + ' time[s].')
MMouse(x1-20,y1-20,20,20)
end;
if (mousevar = 1)
then
mousevar := mousevar - 1
end;
procedure antilog2;
begin
if (x2 >= 763) or (x2 <= 0) or (y2 >= 502) or (y2 <= 0)
then
begin
mousevar := mousevar + 1
timesmoved := timesmoved + 1
writeln('Mouse is off of client; Mouse moved ' + inttostr(timesmoved) + ' time[s].')
MMouse(5,5,300,200)
end;
if (mousevar = 0)
then
begin
timesmoved := timesmoved + 1
writeln('Mouse moved ' + inttostr(timesmoved) + ' time[s].')
MMouse(x2-20,y2-20,20,20)
end;
if (mousevar = 1)
then
mousevar := mousevar - 1
end;
procedure Checkmouse1;
begin
if (x1 = x2) and (y1 = y2)
then antilog1;
end;
procedure Checkmouse2;
begin
if (x1 = x2) and (y1 = y2)
then antilog2;
end;
procedure checkstatus;
begin
wait(25000+random(4000))
getmousepos(x1,y1)
checkmouse1;
status('M1: ' + inttostr(x1) + ':' + IntToStr(y1) + '')
wait(25000+random(4000))
getmousepos(x2,y2)
status('M2: ' + inttostr(x2) + ':' + IntToStr(y2) + '')
checkmouse2;
end;
begin
benmouse := setbenmouse
mousespeed := setmousespeed
activateclient;
timesmoved := 0
mousevar := 0
repeat
checkstatus;
until(false)
end.Bleh, I had an older version as the attachment but the most recently updated one was in the code there… I just fixed that, so if you used the attachment, redownload that. (the older version there still works, but it doesnt have the constant for benmouse and mousespeed)