SRL Archive - First Scripts

First Script Willow Banker


x13om13e12x

2007-06-27 13:19:48

this is my first script that i posted here. It chops and banks willows.
program WillowBanker;
{.include SRL\SRL.scar}
//---------------------------------------------------------------------
// X13om13e12x's Willow Cutter and Banker
//1. Start at Draynor Bank
//2. Start With an axe Equipped or Wielded.
//4. Fill Out Setup from lines 16 to 66
//5. Features AntiRandoms, AntiBan, And for
//low lvls that get attacked by Dark Mages, it runs away from them
//and cuts the willows farther away.
//---------------------------------------------------------------------
var
Tries: Integer;
Const
WillowColor = 3119232;
BankScreenColor = 7761780;
TimePerHit = 5; //in seconds
TimePerLoad = 5; //in minutes

//-------------------------Declare Players-----------------------------

Procedure DeclarePlayers;
begin
HowManyPlayers :=6; // Leave at 6
NumberOfPlayers(HowManyPlayers); // Sets the Players
CurrentPlayer:=0; // Starting Player

Players[0].Name :='xx13om13e12x';
Players[0].Pass :='';
Players[0].Nick :='om';
Players[0].Active:=True;
Players[0].Boolean1:=True; //True if axe is equiped

Players[1].Name :='';
Players[1].Pass :='';
Players[1].Nick :='';
Players[1].Active:=False;
Players[1].Boolean1:=True; //True if axe is equiped

Players[2].Name :='';
Players[2].Pass :='';
Players[2].Nick :='';
Players[2].Active:=False;
Players[2].Boolean1:=True; //True if axe is equiped

Players[3].Name :='';
Players[3].Pass :='';
Players[3].Nick :='';
Players[3].Active:=False;
Players[3].Boolean1:=True; //True if axe is equiped

Players[4].Name :='';
Players[4].Pass :='';
Players[4].Nick :='';
Players[4].Active:=False;
Players[4].Boolean1:=True; //True if axe is equiped

Players[5].Name :='';
Players[5].Pass :='';
Players[5].Nick :='';
Players[5].Active:=False;
Players[5].Boolean1:=True; //True if axe is equiped
writeln(inttostr(HowManyPlayers)+' Players');
NickNameBMP := CreateBitmapMaskFromText(Players[CurrentPlayer].Nick, UpChars);
end;

//--------------------------Dont Change Below--------------------------


//----------------------------Progress Report--------------------------
procedure ProgressReport;

var Active: string;
var i: Integer;
begin
WriteLn(' ');
WriteLn('<----------------> Version 1 - Progress Report <------------>');
SRLRandomsReport;
Writeln(' ');
writeln('-----------------------------------------------');
writeln('Name : '+ Players[CurrentPlayer].Name);
writeln('Number : '+ inttostr(CurrentPlayer));
writeln('Woodcutting : '+ Players[CurrentPlayer].Skill);
writeln('Worked for : '+ inttostr(Players[CurrentPlayer].Worked)+' minutes.');
writeln('Banked : '+ inttostr(Players[CurrentPlayer].Banked) + ' times.');
if Players[CurrentPlayer].Active=True then Active:='True' else Active:='False';
writeln('Active : '+ Active);
writeln('-----------------------------------------------');
end;
//---------------------------Anti-Randoms------------------------------

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 FindRandoms;
begin
FindFastRandoms;
FindNormalRandoms;
end;

//----------------------------Anti-Ban---------------------------------

Procedure AntiBanning;
begin
if(not(LoggedIn)) then
exit;
case random(7) of
0: PickUpMouse;
1: begin
HoverSkill('Strength',false)
wait(354 + random(823))
GameTab(4);
end;
2: SleepAndMoveMouse(2000+random(2000))
3: Typesend('WC lvls?')
4: begin
MakeCompass('E')
MakeCompass('N')
end;
5: Typesend('I like cutting, because you dont have to constantly click')
6: begin
case random(3) of
0: MakeCompass('W')
1: MakeCompass('E')
2: MakeCompass('S')
end;
MakeCompass('N')
end;
end;
end;


//-------------------------Walk to willows------------------------

Procedure GoToWillows;
begin
MakeCompass('N')
RadialWalk(FindWaterColor, 242, 211, 65, 0, 0);
Flag;
Wait(400+random(300));
if(not(FindSymbol(x,y,'fish'))) then
begin
Tries:=0
repeat
Wait(345+random(634));
if(Tries=25) then break;
Tries:=Tries+1
until FindSymbol(x,y,'fish');
end;
MMouse(x,y,2,2);
Mouse(x,y,2,2,true);
end;

//---------------------------Cut willows--------------------------

Procedure WillowCutter;
begin
if(not(LoggedIn)) then Exit;
MarkTime(Mark);
repeat
if(not(FindObj(x,y,'illow',WillowColor,30))) then
begin
Tries:=0
repeat
Wait(345+random(634));
if(Tries=25) then
begin
Writeln('Couldnt find trees')
NextPlayer(false)
end;
Tries:=Tries+1
until FindSymbol(x,y,'fish');
end;
Mouse(x,y,2,2,true)
FindFastRandoms;
Wait(TimePerHit*1000-500+random(1000));
until(InvFull or (TimeFromMark(Mark)>TimeperLoad*60000));
end;

//--------------------------Bank Willows---------------------------

Procedure BankWillows;
begin
if(not(FindSymbol(x,y,'bank'))) then
begin
Tries:=0
repeat
Wait(345+random(634));
if(Tries=25) then
begin
Writeln('Couldnt find bank')
NextPlayer(false)
end;
Tries:=Tries+1
until FindSymbol(x,y,'bank');
end;
MMouse(x,y,2,2);
Mouse(x,y,2,2,true);
AntiBanning;
Flag;
wait(100+random(300));
MakeCompass('W');
if(not(FindObj(x,y,'booth',BankScreenColor,30))) then
begin
Tries:=0
repeat
Wait(345+random(634));
if(Tries=25) then
begin
Writeln('Couldnt find bank')
NextPlayer(false)
end;
Tries:=Tries+1
until FindObj(x,y,'booth',BankScreenColor,30);
end;
Mouse(x,y,2,2,false)
flag;
Wait(200+random(500));
ChooseOption(x,y,'quickly')
if(Players[CurrentPlayer].Boolean1=true) then
begin
DepositAll;
end else Deposit(2,28,2);
CloseBank;
end;

//---------------------------------------------------------------------

Procedure SetUp;
begin
SetupSRL;
DeclarePlayers;
LoginPlayer;
ActivateClient;
end;

//---------------------------------------------------------------------
// Main EventLoop
//---------------------------------------------------------------------
begin
Setup;
repeat
if(not(LoggedIn)) then exit;
HighestAngle;
MakeCompass('N')
GoToWillows;
WillowCutter;
BankWillows;
ProgressReport;
until(false);
end.

pdog

2007-06-27 16:18:26

aaaa dummy u put up ur pass

pdog

2007-06-27 16:19:47

From: pdog
aaaa dummy u put up ur pass


aaa ur pass is up there so change it right away befor some one dose and nice script ill check out now:f: :spongebob:

pdog

2007-06-27 16:23:40

plz remove ur pass some ones gona grab it:eek:

pdog

2007-06-27 16:48:19

yo it wont start when it loggs in it takes forever to move and it logs out wtf?

x13om13e12x

2007-06-27 17:20:51

thanks for telling me my pass was up there, but
do you have my gold and runes? cause my pass was changed, and when i changed it back, all my money and runes were taken, and your name is on my freinds list. And the only reason it would b there is cause you took the money and was going to give it back when i changed the pass? And i dont think you would of stole it, because you wouldnt have warned me about the pass and you wouldnt have added me on the friends list.
And About the script im not sure, it should radialwalk at the start, its my first script so im not so sure about how well it works.

killerb935

2007-09-07 23:11:52

lolz

Method

2007-09-07 23:21:44

Did you check to see if the script compiled before you submitted it here? I received numerous errors, and have fixed them up for you. Here's the updated script:

program WillowBanker;
{.include SRL\SRL.scar}
//---------------------------------------------------------------------
// X13om13e12x's Willow Cutter and Banker
//1. Start at Draynor Bank
//2. Start With an axe Equipped or Wielded.
//4. Fill Out Setup from lines 16 to 66
//5. Features AntiRandoms, AntiBan, And for
//low lvls that get attacked by Dark Mages, it runs away from them
//and cuts the willows farther away.
//---------------------------------------------------------------------
var
Tries, Mark, x, y: Integer;
Const
WillowColor = 3119232;
BankScreenColor = 7761780;
TimePerHit = 5; //in seconds
TimePerLoad = 5; //in minutes

//-------------------------Declare Players-----------------------------

Procedure DeclarePlayers;
begin
HowManyPlayers :=6; // Leave at 6
NumberOfPlayers(HowManyPlayers); // Sets the Players
CurrentPlayer:=0; // Starting Player

Players[0].Name :='xx13om13e12x';
Players[0].Pass :='';
Players[0].Nick :='om';
Players[0].Active:=True;
Players[0].Booleans[1]:=True; //True if axe is equiped

Players[1].Name :='';
Players[1].Pass :='';
Players[1].Nick :='';
Players[1].Active:=False;
Players[1].Booleans[1]:=True; //True if axe is equiped

Players[2].Name :='';
Players[2].Pass :='';
Players[2].Nick :='';
Players[2].Active:=False;
Players[2].Booleans[1]:=True; //True if axe is equiped

Players[3].Name :='';
Players[3].Pass :='';
Players[3].Nick :='';
Players[3].Active:=False;
Players[3].Booleans[1]:=True; //True if axe is equiped

Players[4].Name :='';
Players[4].Pass :='';
Players[4].Nick :='';
Players[4].Active:=False;
Players[4].Booleans[1]:=True; //True if axe is equiped

Players[5].Name :='';
Players[5].Pass :='';
Players[5].Nick :='';
Players[5].Active:=False;
Players[5].Booleans[1]:=True; //True if axe is equiped
writeln(inttostr(HowManyPlayers)+' Players');
NickNameBMP := CreateBitmapMaskFromText(Players[CurrentPlayer].Nick, UpChars);
end;

//--------------------------Dont Change Below--------------------------


//----------------------------Progress Report--------------------------
procedure ProgressReport;

var Active: string;
begin
WriteLn(' ');
WriteLn('<----------------> Version 1 - Progress Report <------------>');
SRLRandomsReport;
Writeln(' ');
writeln('-----------------------------------------------');
writeln('Name : '+ Players[CurrentPlayer].Name);
writeln('Number : '+ inttostr(CurrentPlayer));
writeln('Woodcutting : '+ Players[CurrentPlayer].Skill);
writeln('Worked for : '+ inttostr(Players[CurrentPlayer].Worked)+' minutes.');
writeln('Banked : '+ inttostr(Players[CurrentPlayer].Banked) + ' times.');
if Players[CurrentPlayer].Active=True then Active:='True' else Active:='False';
writeln('Active : '+ Active);
writeln('-----------------------------------------------');
end;
//---------------------------Anti-Randoms------------------------------

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 FindRandoms;
begin
FindFastRandoms;
FindNormalRandoms;
end;

//----------------------------Anti-Ban---------------------------------

Procedure AntiBanning;
begin
if(not(LoggedIn)) then
exit;
case random(7) of
0: PickUpMouse;
1: begin
HoverSkill('Strength',false)
wait(354 + random(823))
GameTab(4);
end;
2: SleepAndMoveMouse(2000+random(2000))
3: Typesend('WC lvls?')
4: begin
MakeCompass('E')
MakeCompass('N')
end;
5: Typesend('I like cutting, because you dont have to constantly click')
6: begin
case random(3) of
0: MakeCompass('W')
1: MakeCompass('E')
2: MakeCompass('S')
end;
MakeCompass('N')
end;
end;
end;


//-------------------------Walk to willows------------------------

Procedure GoToWillows;
begin
MakeCompass('N')
RadialWalk(FindWaterColor, 242, 211, 65, 0, 0);
Flag;
Wait(400+random(300));
if(not(FindSymbol(x,y,'fish'))) then
begin
Tries:=0
repeat
Wait(345+random(634));
if(Tries=25) then break;
Tries:=Tries+1
until FindSymbol(x,y,'fish');
end;
MMouse(x,y,2,2);
Mouse(x,y,2,2,true);
end;

//---------------------------Cut willows--------------------------

Procedure WillowCutter;
begin
if(not(LoggedIn)) then Exit;
MarkTime(Mark);
repeat
if(not(FindObj(x,y,'illow',WillowColor,30))) then
begin
Tries:=0
repeat
Wait(345+random(634));
if(Tries=25) then
begin
Writeln('Couldnt find trees')
NextPlayer(false)
end;
Tries:=Tries+1
until FindSymbol(x,y,'fish');
end;
Mouse(x,y,2,2,true)
FindFastRandoms;
Wait(TimePerHit*1000-500+random(1000));
until(InvFull or (TimeFromMark(Mark)>TimeperLoad*60000));
end;

//--------------------------Bank Willows---------------------------

Procedure BankWillows;
begin
if(not(FindSymbol(x,y,'bank'))) then
begin
Tries:=0
repeat
Wait(345+random(634));
if(Tries=25) then
begin
Writeln('Couldnt find bank')
NextPlayer(false)
end;
Tries:=Tries+1
until FindSymbol(x,y,'bank');
end;
MMouse(x,y,2,2);
Mouse(x,y,2,2,true);
AntiBanning;
Flag;
wait(100+random(300));
MakeCompass('W');
if(not(FindObj(x,y,'booth',BankScreenColor,30))) then
begin
Tries:=0
repeat
Wait(345+random(634));
if(Tries=25) then
begin
Writeln('Couldnt find bank')
NextPlayer(false)
end;
Tries:=Tries+1
until FindObj(x,y,'booth',BankScreenColor,30);
end;
Mouse(x,y,2,2,false)
flag;
Wait(200+random(500));
ChooseOption('quickly')
if(Players[CurrentPlayer].Booleans[1] = true) then
begin
DepositAll;
end else Deposit(2,28,2);
CloseBank;
end;

//---------------------------------------------------------------------

Procedure SetUp;
begin
SetupSRL;
DeclarePlayers;
LoginPlayer;
ActivateClient;
end;

//---------------------------------------------------------------------
// Main EventLoop
//---------------------------------------------------------------------
begin
Setup;
repeat
if(not(LoggedIn)) then exit;
HighestAngle;
MakeCompass('N')
GoToWillows;
WillowCutter;
BankWillows;
ProgressReport;
until(false);
end.

picklemansus

2007-09-09 13:44:32

Unkown identifyer HowManyPlayers in script???????? what do i do

tom143637

2007-09-09 14:37:33

hey i was wondering how do i change my lines?

Skayte

2007-09-10 07:08:58

From: picklemansus
Unkown identifyer HowManyPlayers in script???????? what do i do

i think you need srl if not im not sure

EDIT: im testing this out :D

xFeaR

2007-09-10 15:37:16

this didn't bank for me

deathmas

2007-09-11 12:58:14

Well its a nice piece of work I fixed the delay in the banking a bit more for myslef and it works :)

The only prob is the ENT and attacks :( I lost some stuff when I died and broke 3 axes :(

but it does its job cuts and banks the willows :)

Thanks for the script

XtremeXcript

2007-09-11 23:49:25

Line 13: [Error] (14462:8): Duplicate identifier 'Mark' in script

it keeps telling me this… what can i do PLZ!…

cwin

2007-09-12 01:02:00

nice, good script, well good FIRST Script

deathmas

2007-09-12 02:13:21

From: XtremeXcript
Line 13: [Error] (14462:8): Duplicate identifier 'Mark' in script

it keeps telling me this… what can i do PLZ!…



this is i believe to be an error at your end I used Scar Divi 3.11 with SRL 4.0 and the was no errors at all I just extended the bank wait time for it to work from the original script post but the second post was already fixed so there are no problems with the script just update your SRL

cwin

2007-09-12 02:22:56

Well When i run it, it goes in the bank screen, but DOES NOT depost any williows? tell me how to fix? or do it please?

shimon

2007-09-17 19:23:55

where can I get the SRL\SRL.scar file?

whiebris

2008-01-07 19:48:44

this dosent bank properly

clookid

2008-01-07 20:52:53

This script logs me in, that's about it. :D

Krim0407

2008-02-07 09:41:00

Failed when compiling
Line 432: [Hint] (10376:1): Variable 'OLDMS' never used in script C:\Programfiler\SCAR 3.14\includes\SRL/SRL/Core/AntiRandoms/AntiRandoms.scar
Line 64: [Error] (12331:1): Unknown identifier 'NickNameBMP' in script

Hmm, it is not working with srl 411 and scar 3.14

Jakob S.

2008-02-11 10:52:10

nice, i think, if this is your first script! it's nice, good that you build in a banker! keep up the good work!

JAkob.

kingoscorm

2008-02-11 17:59:58

i ran it but it didnt work i dont no why.

Sjaakie37

2008-02-20 10:58:13

What version of Scar are u all using?
i'm using scar 3.14, With latest SRl/ and that SVN. (I always forget the name;))

and it doesnt work for me.. like every script i try to run.
Yes, i am a noob at this, but in the weekends, when i am with my dad, every script just works fine (even with Smart;)) now it says:

Line 65: [Error] (12462:1): Unknown identifier 'NickNameBMP' in script C:\Program Files\SCAR 3.14\Scripts\Autofighter.scar

Davis_223

2008-02-20 11:08:55

From: Sjaakie37
What version of Scar are u all using?
i'm using scar 3.14, With latest SRl/ and that SVN. (I always forget the name;))

and it doesnt work for me.. like every script i try to run.
Yes, i am a noob at this, but in the weekends, when i am with my dad, every script just works fine (even with Smart;)) now it says:

Line 65: [Error] (12462:1): Unknown identifier 'NickNameBMP' in script C:\Program Files\SCAR 3.14\Scripts\Autofighter.scar


are you sure you have the latest includes and stuff?
:stirthepot:

Sjaakie37

2008-02-20 11:12:40

From: Davis_223
are you sure you have the latest includes and stuff?
:stirthepot:


Yes, I just pressed the 'Download Includes' button, and I only had a few options;) : Overwrite, Cancel, Select all, Select none:)

Raskolnikov

2008-02-20 11:23:56

Reported this thread, this is old. It is used for scar 3.11! Of course it's not going to work with scar 3.14! If you don't know what srl is, I suggest you leave before you leech anymore scripts.

Cazax

2008-02-20 11:26:09

Stop spamming, read This before posting. Im reporting you guys (not you cut em 2 it).

Sjaakie37

2008-02-20 11:26:26

From: Cut em2 it
Reported this thread, this is old. It is used for scar 3.11! Of course it's not going to work with scar 3.14! If you don't know what srl is, I suggest you leave before you leech anymore scripts.



oh:) didnt know it was using 3.11.. first, I know what SRL is, and second, I am trying to make a script.. so i'm not going to leave;)

Wizzup?

2008-02-20 11:51:04

Closed. Do not grave dig please.