SRL Archive - RS Scripts

My first Script


killyou100

2007-04-07 07:32:01

I just made my first script, it logs you in and logs you out. Pretty basic and useless, but tell me if im on the right track.

————————————————————————–

program LoginLogout;

var
x,y: Integer;

procedure Login;
begin
MoveMouseSmooth(445,288);
ClickMouse(445,288,true);
MoveMouseSmooth(372,261);
ClickMouse(372,261,true);
Wait(500);
SendKeys(+chr(13));//Username
SendKeys();//Password
Wait(500);
if(FindColor(x,y,1677215,234,303,371,337))then
MoveMouseSmooth(308,323);
ClickMouse(308,323,true);
Wait(500);
MoveMouseSmooth(397,331);
Wait(2000+random(500))
ClickMouse(397,331,true);
end;

procedure Logout;
begin
if(FindColor(x,y,3691124,634,471,663,495))then;
MoveMouseSmooth(648,483);
ClickMouse(648,483,true);
if(FindColor(x,y,14676215,583,364,712,388))then;
MoveMouseSmooth(645,376);
ClickMouse(645,376,true);
end;

begin
Login;
Wait(500+random(5000))
Logout;
end.

Ashur2Good

2007-04-07 07:39:46

lol or you could just use this…:

program LoggingPlayer;
{.include SRL/SRL.scar}

procedure DeclarePlayers;
begin
HowManyPlayers := 1; //Number of players
NumberOfPlayers(HowManyPlayers);
CurrentPlayer:= 0;

Players[0].Name :='User Name';//Name Goes Here
Players[0].Pass :='Password';//PassWord Goes Here
Players[0].Nick :='er Nam';//3-4 LowerCase Letters Of Your Name
Players[0].Active:=True;//True If Using, False If Not

End;


begin
SetUpSRL;
DeclarePlayers;
LoginPlayer;
end.



other then that nice try :D




-ashur:stirthepot:

Ashur2Good

2007-04-07 07:59:36

Also use MMouse for moving the mouse, and use const for colours,also add random to ure script, also add more space when searching for the colour the cords always change on runescape and u dont have to write the cords again when ure u already used it for searcing :S… this would be a better version of you're script:


Just use the one i showed..(tryed to fix ures…no point, srl already made one lol)


:S

-ashur:stirthepot:

3Garrett3

2007-04-07 16:21:55


program New;
{.include SRL/SRL.scar}

begin
ActivateClient;
MMouse(445,288,0,0);
Mouse(445,288,0,0,true);
MMouse(372,261,0,0);
Mouse(372,261,0,0,true);
Wait(500);
TypeSend('usernamehere');//Username
TypeSend('passwordhere');//Password
Wait(500);
MMouse(308,323,1,1);
Mouse(308,323,0,0,true);
Wait(500);
MMouse(397,331,0,0);
Wait(10000-random(5000))
Mouse(397,331,0,0,true);
end.

Thats it in SRL in case you were wondering how to use Mouse and MMouse.

brent8900

2008-01-04 17:51:02

my scripts are doing that to if u can answer that to

goider

2008-01-12 13:35:54

also when posting a script wrap it in SCAR tags they look like [SCAR*] minus the * and a [/SCAR*] at the end of the code, again no * (astrix i think)

P1nky

2008-01-27 12:33:07

LIKE THIS:

program LoginLogout;

var
x,y: Integer;

procedure Login;
begin
MoveMouseSmooth(445,288);
ClickMouse(445,288,true);
MoveMouseSmooth(372,261);
ClickMouse(372,261,true);
Wait(500);
SendKeys(+chr(13));//Username
SendKeys();//Password
Wait(500);
if(FindColor(x,y,1677215,234,303,371,337))then
MoveMouseSmooth(308,323);
ClickMouse(308,323,true);
Wait(500);
MoveMouseSmooth(397,331);
Wait(2000+random(500))
ClickMouse(397,331,true);
end;

procedure Logout;
begin
if(FindColor(x,y,3691124,634,471,663,495))then;
MoveMouseSmooth(648,483);
ClickMouse(648,483,true);
if(FindColor(x,y,14676215,583,364,712,388))then;
MoveMouseSmooth(645,376);
ClickMouse(645,376,true);
end;

begin
Login;
Wait(500+random(5000))
Logout;
end.
\

btw like ashur said you could use that :D