SRL Archive - First Scripts

My first script (Autotalker)


kooldude

2007-04-15 05:16:17

I know Theres alot of Auto talkers, but just wanted to post it :)

//         SETUP!!
// 1. Maximize Rune Scape, And minimize Scar, Hit Ctrl, Alt, r
// 2.. MAke Sure Your Loged In!



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

begin;
ClearDebug;
Writeln(' /``````````\')
Writeln(' /( o ) ( o )\')
Writeln('/ \')
Writeln('\ (_ _) /')
Writeln(' \ ______ /')
Writeln(' \ /______\ /')
sleep(3000)
Writeln(' rayz AutoTalker 3000 is now running..')

repeat
Typesend ('Hey') // Type In What You Wanna Say!
Wait(5000 + random(500))
Typesend ('Hey') // Type In What You Wanna Say!
Wait(5000 + random(500))
Typesend ('Hey') // Type In What You Wanna Say!
Wait(5000 + random(500))
Typesend ('Hey') // Type In What You Wanna Say!
Wait(5000 + random(500))
Typesend ('Hey') // Type In What You Wanna Say!
Wait(5000 + random(500))
Typesend ('Hey') // Type In What You Wanna Say!
Wait(5000 + random(500))
Typesend ('Hey') // Type In What You Wanna Say!
Wait(5000 + random(500))
Typesend ('Hey') // Type In What You Wanna Say!
Wait(5000 + random(500))
Typesend ('Hey') // Type In What You Wanna Say!
Wait(5000 + random(500))
until(false)
end.

ZephyrsFury

2007-04-26 09:03:01

lol i think you spent more time on your intro pic than your actually script. if you wanted to improve it, you could add a constant line to talk instead of retyping it 20 times. also using 'repeat' and 'until' is easier than retyping the same thing over and over again.

also, in your setup up, i think you should log in before you press ctrl, alt, r

Ashur2Good

2007-04-27 04:02:19

Ok, now lets see. First of all there was no main loop…second of all there were no procedures(If you know what i mean)…Third of all…How about if people only wanted to say 1 thing? There could of been way more improvement…so here is my edited version: :)
//         SETUP!!
// 1. Maximize Rune Scape, And minimize Scar, Hit Ctrl, Alt, r
// 2.. MAke Sure Your Loged In!
// 3... Edited by ashur2good :) if you didnt want me to sorry :(

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


var
i: integer;


const
WhatToSay1='Thanks for using my script, made by kooldude :D';//Type in what you want to say
WhatToSay2='';//if you need more to say...
WhatToSay3='';//...
WhatToSay4='';//...
HowManyTimes=10;//How many times do you want it to repeat
WaitTime=10;//How long to wait before talking again(In micro seconds)
Time=2;//How many things you want to say
W='White';//AutoColour for White
G='Green';//AutoColour for Green
R='Red';//AutoColour for Red


procedure DeclarePlayers;
begin
HowManyPlayers := 6; //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 :='ser nam';//nothing now :/
Players[0].Active:=True;//True If Using, False If Not

Players[1].Name :='';
Players[1].Pass :='';
Players[1].Nick :='';
Players[1].Active:=True;

Players[2].Name :='';
Players[2].Pass :='';
Players[2].Nick :='';
Players[2].Active:=True;

Players[3].Name :='';
Players[3].Pass :='';
Players[3].Nick :='';
Players[3].Active:=True;

Players[4].Name :='';
Players[4].Pass :='';
Players[4].Nick :='';
Players[4].Active:=True;

Players[5].Name :='';
Players[5].Pass :='';
Players[5].Nick :='';
Players[5].Active:=True;


End;




procedure LoggingIn;

begin
SetUpSRL;
DeclarePlayers;
LoginPlayer;
end;




procedure Sig;
begin;
Writeln(' /``````````\')
Writeln(' /( o ) ( o )\')
Writeln('/ \')
Writeln('\ (_ _) /')
Writeln(' \ ______ /')
Writeln(' \ /______\ /')
sleep(3000)
Writeln(' rayz AutoTalker 3000 is now running..')
Wait(3000)
Writeln('Edited by ashur2good :)..')
end;




function FindFastRandoms: Boolean; //By WT-Fakawi.
var
i: Integer;
begin
for i := 1 to 8 do
begin
case I of
1: if FindDead then
Result := True;
2: if FindMod then
Result := True;
3: if FindMime then
Result := True;
4: if FindMaze then
Result := True;
5: if FindQuiz then
Result := True;
6: if FindDemon then
Result := True;
7: begin
if NoGameTab then
begin
Result := True;
Players[CurrentPlayer].loc := 'No GameTab';
Logout;
Exit;
end;
end;
7: begin
if InBlack then
begin
Result := True;
Players[CurrentPlayer].loc := 'InBlack';
Logout;
Exit;
end;
end;
8: RC;
end;
wait(1);
end;
end;




procedure DoAntiRandoms;
begin
FindTalk;
FindFastRandoms;
FindNormalRandoms;
PopUp('ontinue')
if (FindFight = true) then
begin
RunAwayDirection('N');
Wait(10000 + random(2000));
RunBack;
end;
end;




procedure Talk;
begin
repeat
i := i + 1;
Typesend (WhatToSay1+chr(13));
Wait(WaitTime);
DoAntiRandoms;
if (Talk=2) then
begin
Typesend (WhatToSay2+chr(13));
Wait(WaitTime);
DoAntiRandoms;
if (Talk=3) then
begin
Typesend (WhatToSay3+chr(13));
Wait(WaitTime);
DoAntiRandoms;
if (Talk=4) then
begin
Typesend (WhatToSay4+chr(13));
Wait(WaitTime);
DoAntiRandoms;
until(HowManyTimes<i)
end;




begin
repeat
ClearDebug;
Sig;
NickNameBMP := CreateBitmapMaskFromText(Players[CurrentPlayer].Nick, UpChars);
SetupSRL;
DeclarePlayers;
LoginPlayer;
ActivateClient;
Talk;
if (not(Loggedin)) then NextPlayer(false);
until(False);
end.




If you didn't want me to edit it, then just say and i will edit this post

If you liked it, remember to credit me and thanks :D



-Ashur:spot: