SRL Archive - First Scripts

My First AutoTalker


Dusk412

2007-12-23 00:09:26

I know its pretty bad but its my first script :D. Anyways any helpful tips would be appreciated.
***UPDATES***
1.1 - Added Procedure Bored for AntiBan Feature
1.2 - Fixed Procedure Bored
—— Added Hotkey, Random Cycle, and Regular Cycle Options
—— Added Multiple Message Options
1.3 - Added AntiRandom


{
[=========================================================================]
[ AutoTyper 1.3 ]
[=========================================================================]
[ ]
[ NAME : AutoTyper 1.3 ]
[ WRITER : Dusk412 ]
[ CATEGORY : Auto Typer ]
[ DESCRIPTION : Types Messages Automatically ]
[ CONTACT : [email]dusk412@hotmail.com[/email] ]
[ CREDITS : Dusk412 - Creator ]
[ ]
[=========================================================================]
[ Notes ]
[=========================================================================]
[ ]
[ My First Script ^_^ ]
[ Please Copy and Paste the Progress Report onto my thread ]
[ I haven't the automated way to do progress reports yet sorry ]
[ ]
[=========================================================================]
[ ]
[ Updates ]
[ 1.1 Added Procedure Bored for AntiBan Feature ]
[ 1.2 Fixed Procedure Bored ]
[ Added Hotkey, Random Cycle, and Regular Cycle Options ]
[ Added Multiple Message Options ]
[ 1.3 Added AntiRandom ]
[ ]
[=========================================================================]
[=========================================================================]
[ Instructions ]
[=========================================================================]
[ ]
[ 1. Fill out the eight things (they are commented) ]
[ 2. Log in to runescape ]
[ 3. Drag the crosshairs to the runescape screen ]
[ 4. Run the script ]
[ 5. Hit F12 to stop the script ]
[ ]
[=========================================================================]
[ Words of Wisdom ]
[=========================================================================]
[ ]
[ - KNOWLEDGE is knowing a tomato is a fruit; not putting it into your ]
[ fruit salad is WISDOM ]
[ - A ship in the harbor is safe, but that's not what ships are built for.]
[ - A peacock who sits on his tail is just another turkey. ]
[ - If you are willing to admit faults, you have one less fault to admit. ]
[ ]
[=========================================================================] }
program AutoTyper;
{.include SRL/SRL.scar}

const // *** FILL OUT THESE *** //
Name='Dusk412'; // Please Enter Your Name Here (For Progress Report)
Waittime=500; // How Long Between Each Message (Not Applicable if Using Hotkeys)
RunDirection='N'; // What Direction You Will Run If Attacked (Choose N, S, E, or W)
Message1='Your'; // What Message One Says
Message2='Message'; // What Message Two Says
Message3='Here'; // What Message Three Says
NumSaid=0; // How Many Times The Message Will Be Said (Leave as 0 for Infinity, Such as for Hotkeys)
SendMessageType=1; // Pick a Number 1-3.
// (1) Use Hotkeys to send Numbers (Hotkeys are F4, F5, and F6 Respectively)
// (2) Automatically Randomly Choose Messages
// (3) Automatically Cycles Through the Messages In Order (Not Recommended)

var
i : Integer;
BoredMouse : Integer;
BoredTime : Integer;
RandomCycleMessage : Integer;

procedure ProgressReport;
begin
writeln('----------------------------------------')
writeln('AutoTyper 1.3 Progress Report')
writeln('----------------------------------------')
writeln('SRL-Forums Username: ' +Name)
writeln('Send Message Type: ' +IntToStr(SendMessageType))
writeln('Message Sent ' +IntToStr(i) +' Times')
writeln('----------------------------------------')
end;

procedure AntiRandom;
begin
FindTalk;
FindNormalRandoms;
if (FindFight = true) then
begin
RunAwayDirection(RunDirection);
Wait(10000 + random(2000));
RunBack;
end;
if(not(LoggedIn))then
Exit;
end;

procedure Bored;
begin
BoredMouse:=RandomRange(1,3)
BoredTime:=500+random(150)
if(BoredMouse=1) then
begin
IdleTime(BoredTime,250,0.75)
end;
end;

procedure TypeMessageHotKey;
begin
repeat
if(IsFKeyDown(4)) then
begin
TypeSend(Message1)
i:=i+1
AntiRandom
end;
if(IsFKeyDown(5)) then
begin
TypeSend(Message2)
i:=i+1
AntiRandom
end;
if(IsFKeyDown(6)) then
begin
TypeSend(Message3)
i:=i+1
AntiRandom
end;
until(IsFKeyDown(4)) or (IsFKeyDown(5)) or (IsFKeyDown(6)) or (IsFKeyDown(12))
end;

procedure TypeMessageRandom;
begin
RandomCycleMessage:=RandomRange(1,4)
if(RandomCycleMessage=1)then
begin
TypeSend(Message1)
i:=i+1
AntiRandom
Wait(Waittime+random(50))
end;
if(RandomCycleMessage=2)then
begin
TypeSend(Message2)
i:=i+1
AntiRandom
Wait(Waittime+random(50))
end;
if(RandomCycleMessage=3)then
begin
TypeSend(Message3)
i:=i+1
AntiRandom
Wait(Waittime+random(50))
end;
end;

procedure TypeMessageCycle;
begin
if(i<NumSaid)then
begin
TypeSend(Message1)
i:=i+1
AntiRandom
Wait(Waittime+random(50))
Bored
end;
if(i<NumSaid)then
begin
TypeSend(Message2)
i:=i+1
AntiRandom
Wait(Waittime+random(50))
Bored
end;
if(i<NumSaid)then
begin
TypeSend(Message3)
i:=i+1
AntiRandom
Wait(Waittime+random(50))
Bored
end;
end;

procedure Setup;
begin
setupSRL
ClearDebug
activateclient;
writeln('Hello, Welcome to AutoTyper 1.3')
i:=0
BoredTime:=0
if(not(LoggedIn))then
Exit;
end;

begin
Setup
if(SendMessageType=1) then
begin
repeat
TypeMessageHotKey
until(IsFKeyDown(12));
end;
if(SendMessageType=2) then
begin
repeat
TypeMessageRandom
Wait(Waittime+random(50))
Bored
until(i>=NumSaid);
end;
if(SendMessageType=3) then
begin
repeat
TypeMessageCycle
until(i>=NumSaid);
end;
ProgressReport
end.

Dusk412

2007-12-23 10:05:37

Updated to 1.1 and it works nicely.

osmm

2007-12-23 10:18:45

Its prety nice for a first scipt auto talker. I'd think about adding some anti bans and most importantly try and make a function that adds spelling misstakes.

Dusk412

2007-12-23 18:37:45

How for example would you go about adding spelling mistakes. Make an array and put the different messages some with mistakes or something? Or is there a random way to make it type mistakes with a tolerance or some such thing? Thanks for suggestions osmm.
BTW where do you get those things like you have in your sig?

L3ss Than 33

2007-12-23 18:46:37

I'm new to this, but I would have many variations of spelling mistakes for the same line and just have it alternate between them.

Dusk412

2007-12-23 22:48:03

Updated to 1.2
Updated to 1.3
AntiRandoms and kind of AntiBan Work Smoothly

Dusk412

2007-12-25 17:08:17

Please everyone look at this script and tell me how I can improve it. I really need to work on my scripting. I have also created a second script (non-functional) so if anyone wants to help me with that here is the link: http://www.villavu.com/forum/showthread.php?t=23256