SCAR Code:
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.