rotflmfwao
2007-08-31 19:59:39
<!– BEGIN TEMPLATE: formanswers –>
rotflmfwao - SRL Member Application Form
rotflmfwao
What is the meaning to life?
Nothing and everything at the same time.
Where you Referred to SRL? If yes, by whom?
no
Programming Knowledge
AutoIt V3.0 and SCAR
Other Communitys
None, sorry.
How Long have You Played Runescape
I don't.
Are you affilated in anyway with Jagex LTD?
No
—————————————————–
Please write down a paragraph about Yourself.
Well, I've been programing and hacking (macroing as well) games for about 4 years, seeing as I started when I was 10. I played MapleStory and hacked it with hex editors and some basic core programing. That occupied me for about 2 years, and then I got into Flyff. I hacked that by replacing some .dat files in the program file, making me go super fast (got banned super fast too lmao).
This lasted for another year, and then I played Runescape for like a day. It got boring really fast and I just kinda quit on computers for a couple months, but my friend asked me to hack (auto) RS for him, and I did. I found SRL and I got interested in the coding, as it is a fun intellectual challenge.
Well, that about sums it up for my experience in coding. If you read all of that, congrats to you.
——————————————————
Please Post a Sample of your Work. Only SCAR Scripts Accepted
Omg lotta code!:eek: :eek:
If you vote no, please tell me why. Thanks.
——————————————————
<!– END TEMPLATE: formanswers –>
rotflmfwao - SRL Member Application Form
rotflmfwao
What is the meaning to life?
Nothing and everything at the same time.
Where you Referred to SRL? If yes, by whom?
no
Programming Knowledge
AutoIt V3.0 and SCAR
Other Communitys
None, sorry.
How Long have You Played Runescape
I don't.
Are you affilated in anyway with Jagex LTD?
No
—————————————————–
Please write down a paragraph about Yourself.
Well, I've been programing and hacking (macroing as well) games for about 4 years, seeing as I started when I was 10. I played MapleStory and hacked it with hex editors and some basic core programing. That occupied me for about 2 years, and then I got into Flyff. I hacked that by replacing some .dat files in the program file, making me go super fast (got banned super fast too lmao).
This lasted for another year, and then I played Runescape for like a day. It got boring really fast and I just kinda quit on computers for a couple months, but my friend asked me to hack (auto) RS for him, and I did. I found SRL and I got interested in the coding, as it is a fun intellectual challenge.
Well, that about sums it up for my experience in coding. If you read all of that, congrats to you.
——————————————————
Please Post a Sample of your Work. Only SCAR Scripts Accepted
{.Script Info:
# ScriptName = Bananas
# Author = Rotflmfwao
# Description = Does Luthas's banana picking quest.
# Version = 6.3
# Date = August 19, 2007
# Comments = Autocoloring isn't perfected yet so
it won't be used, sorry.
/Script Info}
{Just hit run. Thats it.
Don't screw with the script at all!
Your settings won't be deleted unless you run a
clean registry app.}
program Bananas;
{.Include SRL/SRL.scar}
{.Include SRL/SRL/core/Users.scar}
//--------------------Global vars and consts
Var
LuthasColors, CrateColors, BananaColors: Array of Integer;
RunTime, illl, Baranara, BFeild, LuthasMM, OutHouse, ddtmarea, ddtmtol:Integer;
B:TPoint;
VersionNumber:String;
//------------------Form Stuff----------------------------------------
Var
SearchTime, HowManyQuests, HowLongToRun:Integer;//Form Stuff
KillUIDs, ProggieAtEnd, LogoutFast, UseEffQuest:Boolean;//Form Stuff
var
frmDesign : TForm;//Form
Updates,SS,LS,Letsgo,ShowInst,ShowCred: TButton;//Buttons
GroupBox1 : TGroupBox;//Group box
UEQ,LF,PAE,KUID : TCheckBox;//Check Box
HMQ, HLTR, ST, SID, SP : TEdit;//Edit
//------------------------------Above is main form stuff
Procedure Signature;
Begin
ClearDebug;
Writeln('Auto Banana Quester By:');
Writeln('Rotflmfwao of http://www.srl-forums.com');
Writeln(' __ __ ____ __ ___ ___ _____ ');
Writeln('||\\ || |__ \|| // \\// \\ |__ \ __ ___ ');
Writeln('||// ____==||==|| |_||| || |||| || || |_| || / _ \ ____ ');
Writeln('||\\ / \ || ==== || || \\// ||====|| ||( (_)| / \ ');
Writeln('|| \\( () )|| || ||___|| \/ || || \\/\// \__ \( () )');
Writeln('|| \\\____/ || || |____|| || || \__/ \_\\____/ ');
End;
Procedure SetupStuff;
Begin
SetupSRL;
ScriptID := '252';
VersionNumber:='6.3';
Signature;
Wait(1000+Random(1000));
End;
procedure WriteUpdates;
Begin
ShowMessage('Version 1.0: First one' +Chr(13) +
'Version 1.1: Some minor bugfixes, looks better' +Chr(13) +
'Version 2.0: Proggie, more efficient' +Chr(13) +
'Version 2.1: Optional EfficientQuesting' +Chr(13) +
'Version 3.0: SRL Stats!!! Yay! But they don''t work...' +Chr(13) +
'Version 3.5: Fixed SRL Stats, big update, so it went up .5 instead of .1' +Chr(13) +
' Some minor bugfixes and other minor updates' +Chr(13) +
'Version 3.7: More SRL Stats!' +Chr(13) +
'Version 4.0: Updated for SRL 4.0 Beta!!! Yay!' +Chr(13) +
'Version 4.3: Forms!!!!!!!!!!' +Chr(13) +
'Version 5.0: Cleaner Code! DTMs!' +Chr(13) +
'Version 5.5: AutoColoring! Easier than it seems!' +Chr(13) +
'Version 6.0: Fixed AutoColoring and DDTMs. More in the form.' +Chr(13) +
'Version 6.3: Credits, and some bugfixes.' +Chr(13) +
'Coming in later versions:' +Chr(13) +
' Running');
End;
Procedure WriteInstructions;
Begin
ShowMessage('Put all of your players in' +Chr(13) +
'Luthas''s house, preferably in the middle.' +Chr(13) +
'Have your settings VB and LowDetail.' +Chr(13) +
'Then logout, and just hit run. No need' +Chr(13) +
'to even target RS, my script does that!');
End;
Procedure Credits;
Begin
ShowMessage('Credits:' +Chr(13) +
'Me; I wrote the script XD' +Chr(13) +
'Yakman; His walking aid = Pwnage.' +Chr(13) +
'YoHoJo; His tut on DDTMs helped a LOT' +Chr(13) +
'Jason2gs; He gave me all of the Luthas Colors' +Chr(13) +
'The SRL Community; Thank you all soooo much!!' +Chr(13) +
' I wouldn''t have this script' +Chr(13) +
' without you guys!' +Chr(13) +
'Everyone else that I forgot; Thanks! PM me and I''ll' +Chr(13) +
' get you in here!' +Chr(13));
End;
Procedure SaveSet;
Begin
SearchTime:=StrToInt(ST.Text);
HowManyQuests:=StrToInt(HMQ.Text);
HowLongToRun:=StrToInt(HLTR.Text);
KillUIDs:=KUID.Checked;
ProggieAtEnd:=PAE.Checked;
LogoutFast:=LF.Checked;
UseEffQuest:=UEQ.Checked;
SRLID:=SID.Text;
SRLPassword:=SP.Text;
SaveSetting('BananaSettings','SID',SRLID);
SaveSetting('BananaSettings','SP',SRLPassword);
SaveSetting('BananaSettings','ST',IntToStr(SearchTime));
SaveSetting('BananaSettings','HMQ',IntToStr(HowManyQuests));
SaveSetting('BananaSettings','HLTR',IntToStr(HowLongToRun));
SaveSetting('BananaSettings','KUID',BoolToStr(KillUIDs));
SaveSetting('BananaSettings','PAE',BoolToStr(ProggieAtEnd));
SaveSetting('BananaSettings','LF',BoolToStr(LogoutFast));
SaveSetting('BananaSettings','UEQ',BoolToStr(UseEffQuest));
End;
Procedure LoadSet;
Begin
SearchTime:=StrToInt(LoadSetting('BananaSettings','ST'));
HowManyQuests:=StrToInt(LoadSetting('BananaSettings','HMQ'));
HowLongToRun:=StrToInt(LoadSetting('BananaSettings','HLTR'));
KillUIDs:=StrToBool(LoadSetting('BananaSettings','KUID'));
ProggieAtEnd:=StrToBool(LoadSetting('BananaSettings','PAE'));
LogoutFast:=StrToBool(LoadSetting('BananaSettings','LF'));
UseEffQuest:=StrToBool(LoadSetting('BananaSettings','UEQ'));
SRLID:=LoadSetting('BananaSettings','SID');
SRLPassword:=LoadSetting('BananaSettings','SP');
SID.Text := SRLID;
SP.Text := SRLPassword;
ST.Text := IntToStr(SearchTime);
HMQ.Text := IntToStr(HowManyQuests);
HLTR.Text := IntToStr(HowLongToRun);
KUID.Checked := KillUIDs;
PAE.Checked := ProggieAtEnd;
LF.Checked := LogoutFast;
UEQ.Checked := UseEffQuest;
End;
//--------------Above is Settings Procs, below is Players Procs------\\
//----------------------------HandleButtons below for main form
Procedure HandleButtons(Sender:TObject);
Begin
Case Sender Of
Updates:WriteUpdates;
SS:SaveSet;
LS:LoadSet;
Letsgo:Begin
Writeln('Time to setup your players!');
frmDesign.ModalResult := mrOk;
End;
ShowInst:WriteInstructions;
ShowCred:Credits;
End;
End;
//-------------Form Creator Below-------------------------------\\
Procedure InitForm;
Begin
frmDesign := CreateForm;
frmDesign.Left := 335;
frmDesign.Top := 168;
frmDesign.Width := 435;
frmDesign.Height := 300;
frmDesign.Caption := 'Bananas Version ' +VersionNumber;
frmDesign.Color := clYellow;
frmDesign.Font.Color := clWindowText;
frmDesign.Font.Height := -11;
frmDesign.Font.Name := 'MS Sans Serif';
frmDesign.Font.Style := [];
frmDesign.Visible := False;
frmDesign.PixelsPerInch := 96;
Updates := TButton.Create(frmDesign);//Write the updates
Updates.OnClick := @HandleButtons;
Updates.Parent := frmDesign;
Updates.Left := 1;
Updates.Top := 1;
Updates.Width := 415;
Updates.Height := 25;
Updates.Cursor := crHandPoint;
Updates.Hint := 'Writes the updates to the debug';
Updates.Caption := 'See Updates';
Updates.DragCursor := crDefault;
Updates.Font.Color := clWindowText;
Updates.Font.Height := -11;
Updates.Font.Name := 'Fixedsys';
Updates.Font.Style := [];
Updates.ParentFont := False;
Updates.TabOrder := 0;
GroupBox1 := TGroupBox.Create(frmDesign);
GroupBox1.Parent := frmDesign;
GroupBox1.Left := 4;
GroupBox1.Top := 32;
GroupBox1.Width := 243;
GroupBox1.Height := 94;
GroupBox1.Caption := 'Options';
GroupBox1.TabOrder := 1;
KUID := TCheckBox.Create(GroupBox1);//Kill UIDs
KUID.Parent := GroupBox1;
KUID.Left := 6;
KUID.Top := 13;
KUID.Width := 97;
KUID.Height := 17;
KUID.Cursor := crHandPoint;
KUID.Hint := 'Do you want my script to destroy the UIDs?';
KUID.Caption := 'KillUIDs?';
KUID.Checked := True;
KUID.Font.Color := clBlack;
KUID.Font.Height := -11;
KUID.Font.Name := 'Microsoft Sans Serif';
KUID.Font.Style := [];
KUID.ParentFont := False;
KUID.ParentShowHint := False;
KUID.ShowHint := True;
KUID.State := cbChecked;
KUID.TabOrder := 0;
PAE := TCheckBox.Create(GroupBox1);//ProggieAtEnd
PAE.Parent := GroupBox1;
PAE.Left := 6;
PAE.Top := 33;
PAE.Width := 97;
PAE.Height := 17;
PAE.Cursor := crHandPoint;
PAE.Hint := 'Do you want a Proggie at the end?';
PAE.Caption := 'Full Proggie?';
PAE.Checked := True;
PAE.ParentShowHint := False;
PAE.ShowHint := True;
PAE.State := cbChecked;
PAE.TabOrder := 1;
LF := TCheckBox.Create(GroupBox1); //LogoutFast
LF.Parent := GroupBox1;
LF.Left := 6;
LF.Top := 53;
LF.Width := 97;
LF.Height := 17;
LF.Cursor := crHandPoint;
LF.Hint := 'Do you want to logout fast?';
LF.Caption := 'Logout Fast?';
LF.Checked := True;
LF.ParentShowHint := True;
LF.ShowHint := True;
LF.State := cbChecked;
LF.TabOrder := 2;
UEQ := TCheckBox.Create(GroupBox1);//UseEffQuest
UEQ.Parent := GroupBox1;
UEQ.Left := 6;
UEQ.Top := 73;
UEQ.Width := 97;
UEQ.Height := 17;
UEQ.Cursor := crHandPoint;
UEQ.Hint := 'Do you want to use Efficient Quest?';
UEQ.Caption := 'Efficient Quest';
UEQ.Checked := True;
UEQ.ParentShowHint := False;
UEQ.ShowHint := True;
UEQ.State := cbChecked;
UEQ.TabOrder := 3;
ST := TEdit.Create(GroupBox1);//SearchTime
ST.Parent := GroupBox1;
ST.Left := 110;
ST.Top := 13;
ST.Width := 121;
ST.Height := 21;
ST.Hint := 'How long do you want to look for luthas (in ms) Rec:60000';
ST.MaxLength := 5;
ST.ParentShowHint := False;
ST.ShowHint := True;
ST.TabOrder := 4;
ST.Text := '60000';
HMQ := TEdit.Create(GroupBox1);//HowManyQuests
HMQ.Parent := GroupBox1;
HMQ.Left := 110;
HMQ.Top := 38;
HMQ.Width := 121;
HMQ.Height := 21;
HMQ.Hint := 'How hamy times do you want each player to do the quest?';
HMQ.MaxLength := 1;
HMQ.ParentShowHint := False;
HMQ.ShowHint := True;
HMQ.TabOrder := 5;
HMQ.Text := '3';
HLTR := TEdit.Create(GroupBox1);//HowLongToRun
HLTR.Parent := GroupBox1;
HLTR.Left := 110;
HLTR.Top := 64;
HLTR.Width := 121;
HLTR.Height := 21;
HLTR.Hint := 'How long do you want the script to run, in minutes.';
HLTR.ParentShowHint := False;
HLTR.ShowHint := True;
HLTR.TabOrder := 6;
HLTR.Text := '600';
//Above is settings---------------- no onclick controlls needed
//Below is savesettings and loadsettings
SS := TButton.Create(frmDesign);//SaveSettings
SS.OnClick := @HandleButtons;
SS.Parent := frmDesign;
SS.Left := 1;
SS.Top := 130;
SS.Width := 194;
SS.Height := 25;
SS.Cursor := crHandPoint;
SS.Hint := 'Click this to save your settings';
SS.Caption := 'Save Settings';
SS.Font.Color := clWindowText;
SS.Font.Height := -11;
SS.Font.Name := 'Impact';
SS.Font.Style := [];
SS.ParentFont := False;
SS.ParentShowHint := False;
SS.ShowHint := True;
SS.TabOrder := 2;
LS := TButton.Create(frmDesign);//Load Settings
LS.OnClick := @HandleButtons;
LS.Parent := frmDesign;
LS.Left := 218;
LS.Top := 131;
LS.Width := 194;
LS.Height := 25;
LS.Cursor := crHandPoint;
LS.Hint := 'Click this to load your settings';
LS.Caption := 'Load Settings';
LS.Font.Color := clWindowText;
LS.Font.Height := -11;
LS.Font.Name := 'Impact';
LS.Font.Style := [];
LS.ParentFont := False;
LS.ParentShowHint := False;
LS.ShowHint := True;
LS.TabOrder := 4;
SID :=TEdit.Create(frmDesign);//srl id
SID.Parent := frmDesign;
SID.Left := 40;
SID.Top := 160;
SID.Width := 121;
SID.Height := 21;
SID.Hint := 'Your SRL Stats ID, EX: 1344';
SID.ParentShowHint := False;
SID.ShowHint := True;
SID.Text := 'Your SRLID';
SP :=TEdit.Create(frmDesign); //Srl password
SP.PasswordChar := '*';
SP.Parent := frmDesign;
SP.Left := 250;
SP.Top := 160;
SP.Width := 121;
SP.Height := 21;
SP.Hint := 'Your SRL Stats Password';
SP.ParentShowHint := False;
SP.ShowHint := True;
SP.Text := 'Your SRLPass';
Letsgo := TButton.Create(frmDesign);
Letsgo.OnClick := @HandleButtons;
Letsgo.Parent := frmDesign;
Letsgo.Left := 254;
Letsgo.Top := 34;
Letsgo.Width := 156;
Letsgo.Height := 93;
Letsgo.Cursor := crHandPoint;
Letsgo.Hint := 'Start The Script!!!! Make sure that runescape is the client and you have all the info filled in.';
Letsgo.Caption := 'GO!!!';
Letsgo.Font.Color := clYellow;
Letsgo.Font.Height := -48;
Letsgo.Font.Name := 'Roman';
Letsgo.Font.Style := [];
Letsgo.ParentFont := False;
Letsgo.ParentShowHint := False;
Letsgo.ShowHint := True;
Letsgo.TabOrder := 13;
ShowInst := TButton.Create(frmDesign);//show instructions
ShowInst.OnClick := @HandleButtons;
ShowInst.Parent := frmDesign;
ShowInst.Left := 1;
ShowInst.Top := 190;
ShowInst.Width := 420;
ShowInst.Height := 25;
ShowInst.Cursor := crHandPoint;
ShowInst.Hint := 'Click this to show instructions';
ShowInst.Caption := 'Show Instructions';
ShowInst.Font.Color := clWindowText;
ShowInst.Font.Height := -14;
ShowInst.Font.Name := 'Roman';
ShowInst.Font.Style := [];
ShowInst.ParentFont := False;
ShowInst.ParentShowHint := False;
ShowInst.ShowHint := True;
ShowCred := TButton.Create(frmDesign);//show credits
ShowCred.OnClick := @HandleButtons;
ShowCred.Parent := frmDesign;
ShowCred.Left := 1;
ShowCred.Top := 230;
ShowCred.Width := 420;
ShowCred.Height := 25;
ShowCred.Cursor := crHandPoint;
ShowCred.Hint := 'Click this to show credits';
ShowCred.Caption := 'Credits';
ShowCred.Font.Color := clWindowText;
ShowCred.Font.Height := -14;
ShowCred.Font.Name := 'Roman';
ShowCred.Font.Style := [];
ShowCred.ParentFont := False;
ShowCred.ParentShowHint := False;
ShowCred.ShowHint := True;
End;
procedure SafeInitForm;
var
v: TVariantArray;
begin
setarraylength(V, 0);
ThreadSafeCall('InitForm', v);
end;
procedure ShowFormModal;
begin
frmDesign.ShowModal;
end;
procedure SafeShowFormModal;
var
v: TVariantArray;
begin
setarraylength(V, 0);
ThreadSafeCall('ShowFormModal', v);
end;
Procedure SetIntegers;
Var i:integer;
Begin
For i:=0 to GetArrayLength(players)-1 do
Begin
Players[i].Integers[0]:=0;
Players[i].Integers[1]:=0;
Players[i].Integers[5]:=0;
Players[i].Loc := 'Luthas''s House';
Players[i].Rand :='None';
End;
End;
Procedure StartTheShow;
Begin
Safeinitform;
SafeShowFormModal;
FreeForm(frmDesign);
SRLPlayerForm(True,[],[],[],[]);
SetIntegers;
End;
//-----------------End Form Stuff------------------------------------
//------------------------Non-mainloop related procs and funcs
Var
BFMP,LMMP,OHMP: TDTMPointDef;
BFSP,OHSP: Array[0..3]of TDTMPointDef;
BFSkel,LMSkel,OHSkel: TDTM;
LMSP: Array[0..1]of TDTMPointDef;
Procedure LoadDTMs;
Begin
BFMP.x:=622;//Bananafeild
BFMP.y:=433;
BFMP.areasize:=1;
BFMP.areashape:=0;
BFMP.color:= 346978;
BFMP.tolerance:= ddtmtol;
BFSP[0].x:= 632;
BFSP[0].y:= 433;
BFSP[0].areasize:=ddtmarea;
BFSP[0].areashape:=0;
BFSP[0].color:= 933217;
BFSP[0].tolerance:= ddtmtol;
BFSP[1].x:= 617;
BFSP[1].y:= 449;
BFSP[1].areasize:=ddtmarea;
BFSP[1].areashape:=0;
BFSP[1].color:= 3630145;
BFSP[1].tolerance:= ddtmtol;
BFSP[2].x:= 634;
BFSP[2].y:= 431;
BFSP[2].areasize:=ddtmarea;
BFSP[2].areashape:=0;
BFSP[2].color:= 15462116;
BFSP[2].tolerance:= ddtmtol;
BFSP[3].x:= 634;
BFSP[3].y:= 439;
BFSP[3].areasize:=ddtmarea;
BFSP[3].areashape:=0;
BFSP[3].color:= 15462116;
BFSP[3].tolerance:= ddtmtol;
BFSkel.MainPoint:=BFMP;
BFSkel.SubPoints:=BFSP;
//end defining bananafeild
LMMP.x:=537;//LuthasMM
LMMP.y:=365;
LMMP.areasize:=1;
LMMP.areashape:=0;
LMMP.color:= 60909;
LMMP.tolerance:= ddtmtol;
LMSP[0].x:= 535;
LMSP[0].y:= 365;
LMSP[0].areasize:=ddtmarea;
LMSP[0].areashape:=0;
LMSP[0].color:= 195836;
LMSP[0].tolerance:= ddtmtol;
LMSP[1].x:= 617;
LMSP[1].y:= 449;
LMSP[1].areasize:=ddtmarea;
LMSP[1].areashape:=0;
LMSP[1].color:= 3630145;
LMSP[1].tolerance:= ddtmtol;
LMSkel.MainPoint:=LMMP;
LMSkel.SubPoints:=LMSP;
//end defining LuthasMM
OHMP.x:=529;//OutHouse
OHMP.y:=382;
OHMP.areasize:=ddtmarea;
OHMP.areashape:=0;
OHMP.color:= 344686;
OHMP.tolerance:= ddtmtol;
OHSP[0].x:= 522;
OHSP[0].y:= 380;
OHSP[0].areasize:=ddtmarea;
OHSP[0].areashape:=0;
OHSP[0].color:= 15462116;
OHSP[0].tolerance:= ddtmtol;
OHSP[1].x:= 536;
OHSP[1].y:= 380;
OHSP[1].areasize:=ddtmarea;
OHSP[1].areashape:=0;
OHSP[1].color:= 15462116;
OHSP[1].tolerance:= ddtmtol;
OHSP[2].x:= 548;
OHSP[2].y:= 379;
OHSP[2].areasize:=ddtmarea;
OHSP[2].areashape:=0;
OHSP[2].color:= 15462116;
OHSP[2].tolerance:= ddtmtol;
OHSP[3].x:= 510;
OHSP[3].y:= 380;
OHSP[3].areasize:=ddtmarea;
OHSP[3].areashape:=0;
OHSP[3].color:= 15462116;
OHSP[3].tolerance:= ddtmtol;
OHSkel.MainPoint:=OHMP;
OHSkel.SubPoints:=OHSP;
//end defining OutHouse
Baranara:=DTMFromString('78DA6314616060E06140013BB73B329C00D28' +
'C40FC1F0818F9800C3E0634C0884402690E4C7330D4B002094E02' +
'6A8481043B013552408297801A69202142408D38909026A006648' +
'618013582404280801A50D8B0E15703006F6207F3');
BFeild:=AddDTM(BFSkel);
LuthasMM:= AddDTM(LMSkel);
OutHouse:= AddDTM(OHSkel);
End;
Procedure FreeDTMs;
Begin
FreeDTM(Baranara);
FreeDTM(BFeild);
FreeDTM(LuthasMM);
FreeDTM(OutHouse);
End;
Function Sum(i,q:Integer):Integer;
Begin
Result:=i+q;
End;
Procedure LoginCheck;
Begin
If(Not(LoggedIn) or Players[CurrentPlayer].Active=False)Then
Begin
Players[CurrentPlayer].Active:=False;
Exit;
End;
End;
Function AllPlayersInactive:Boolean;
Var i,q:Integer;
Begin
LoginCheck;
Result:=False;
q:=0
For i:=0 to HowManyPlayers-1 do
Begin
If(Players[i].Active=False)Then
Inc(q);
End;
If(q=HowManyPlayers)Then
Result:=True;
End;
Procedure EraseUIDs(i:String);
Begin
If(KillUIDs)Then
ReWriteFile('C:\\Windows\.jagex_cache_32\' +i +'.dat',false);
Inc(ReportVars[6]);
End;
Procedure RunAway(Dir:String);//Lowercase or upper, doesn't matter
Begin
LoginCheck;
Case Capitalize(Dir) of
'N':Begin
RunTo('n',False)
FTWait(4+Random(6))
RunTo('s',False)
End;
'S':Begin
RunTo('s',False)
FTWait(4+Random(6))
RunTo('n',False)
End;
'E':Begin
RunTo('e',False)
FTWait(4+Random(6))
RunTo('w',False)
End;
'W':Begin
RunTo('w',False)
FTWait(4+Random(6))
RunTo('e',False)
End;
End;
End;
function FindFastRandoms: Boolean; //By WT-Fakawi.
var
i: Integer;
begin
LoginCheck;
for i := 1 to 9 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;
8: begin
if InBlack then
begin
Result := True;
Players[CurrentPlayer].loc := 'InBlack';
Logout;
Exit;
end;
end;
9: RC;
end;
wait(1);
end;
end;
Procedure ChangePlayer;
Label
Fast;
Var
i:Boolean;
Begin
If(Not(LoggedIn))Then
Exit;
i:=True;
Begin
If(AllPlayersInactive)Then
TerminateScript;
If(Not(LogoutFast))Then
Begin
Repeat
FindFastRandoms;
If(FindFight)Then
RunAway('ran');
If(KillUIDs)Then
If(i)Then
EraseUIDs('uid');
i:=False;
Until(Not(LoggedIn));
End;
If(LogoutFast)Then
Begin
Fast:
FindFastRandoms;
If(FindFight)Then
RunAway('ran');
If(KillUIDs)Then
EraseUIDs('uid');
Logout;
If(LoggedIn)Then
Goto Fast;
End;
If(KillUIDs)Then
EraseUIDs('random');
NextPlayer(Players[CurrentPlayer].Active);
Exit;
End;
End;
procedure DeclareColors;
begin
SetArrayLength(LuthasColors, 14);
LuthasColors[0] := 8238;
LuthasColors[1] := 6517117;
LuthasColors[2] := 603985;
LuthasColors[3] := 5727343;
LuthasColors[4] := 4950944;
LuthasColors[5] := 1790057;
LuthasColors[6] := 7241098;
LuthasColors[7] := 2380392;
LuthasColors[8] := 1140875;
LuthasColors[9] := 942980;
LuthasColors[10] := 7043462;
LuthasColors[11] := 1591648;
LuthasColors[12] := 4950944;
LuthasColors[13] := 6941;
SetArrayLength(BananaColors,5);
BananaColors[0] := 2484987;
BananaColors[1] := 1893878;
BananaColors[2] := 1890279;
BananaColors[3] := 1688786;
BananaColors[4] := 3402747;
SetArrayLength(CrateColors,7);
CrateColors[0] := 2973826;
CrateColors[1] := 4486038;
CrateColors[2] := 5140105;
CrateColors[3] := 5602200;
CrateColors[4] := 3892098;
CrateColors[5] := 2055041;
CrateColors[6] := 2906747;
end;
Function RandomDir: String;
Begin
Case (random(4)) of
0: Result:='n';
1: Result:='s';
2: Result:='e';
3: Result:='w';
End;
End;
Procedure Randoms;
Begin
LoginCheck;
FindFastRandoms;
FindNormalRandoms;
If(FindFight)Then
RunAway(RandomDir);
End;
Procedure ScrewyCompass(arrowkey:String; moveback:Boolean);//up, down, left, right, or ran
Var HoldingTime, WaitTime, RanDir, OppRanDir:Integer;
Begin
LoginCheck;
HoldingTime:= 500+random(1000);
WaitTime:= 2+random(2);
RanDir:= random(4);
Case (RanDir) of
0: OppRanDir:=2
1: OppRanDir:=3
2: OppRanDir:=0
3: OppRanDir:=1
End;
Case (arrowkey) of
'up': SendArrowWait(0,HoldingTime);
'down': SendArrowWait(2,HoldingTime);
'left': SendArrowWait(3,HoldingTime);
'right': SendArrowWait(1,HoldingTime);
'ran': SendArrowWait(RanDir,HoldingTime);
End;
If (moveback) Then
Begin
FTWait(WaitTime);
Case (arrowkey) of
'up': SendArrowWait(2,HoldingTime);
'down': SendArrowWait(0,HoldingTime);
'left': SendArrowWait(1,HoldingTime);
'right': SendArrowWait(3,HoldingTime);
'ran': SendArrowWait(OppRanDir,HoldingTime);
End;
End;
End;
Procedure NevaBanMe;
Begin
LoginCheck;
Case (random(11)) of
0: RandomRClick;
1: begin
HoverSkill('Fishing', false);
FTWait(4+random(8));
GameTab(4);
end;
2: ScrewyCompass('ran',True);
3: Exit;
4: PickUpMouse;
5: Exit;
6: begin
HoverSkill('Mining', false);
wait(4+random(8));
GameTab(4);
end;
7: begin
GameTab(1 + Random(12));
wait(4+random(4));
GameTab(4);
end;
8: begin
case random(11) of
0: TypeSend('Ugh, Prayer takes 4 eva 2 lvl!!!');
1: TypeSend('Bananas are yummy in my tummy!');
2: TypeSend('Hey all, wats ur fishing lvls?');
3: TypeSend('Bananas Pwn!');
4: TypeSend('Money money money!!!');
5: TypeSend('W00t! Bananas are fuuuuun!');
6: TypeSend('I wonder how long each quest takes.... Hm...');
7: TypeSend('I like the number 7, I don''t know why :p');
8: TypeSend('Wave2:Banananananananana!!!!');
9: TypeSend('Omg itz me!');
10: TypeSend('Wow, I am really hungry!');
end;
end;
9: begin
GameTab(1 + Random(12));
wait(4+random(4));
GameTab(4);
end;
10: SleepAndMoveMouse(2000+random(3000));
End;
End;
Procedure HumanStuff;
Begin
LoginCheck;
Case Random(2) of
1:NevaBanMe;
End;
End;
Procedure DoRandoms;
Begin
LoginCheck;
Randoms;
End;
//---------------------------------MainLoop Procs and Funcs
Function FindLuthas: boolean;//Thanks to Jason2gs and DevilCheater for the help
Var
Lx, Ly, i,TimeMarker: integer;
Begin
LoginCheck;
FindTalk;
MarkTime (TimeMarker);
HighestAngle;
FindTalk;
Players[CurrentPlayer].Loc:='Finding luthas';
Repeat
For i := 0 To (GetArrayLength(LuthasColors) - 2) do
Begin
If FindObjCustom(Lx, Ly, ['Luthas', 'Lu', 'tha','Talk'], [LuthasColors[i],LuthasColors[i+1]], 3) then
Begin
FindTalk;
Mouse (Lx, Ly, 0, 0, False);
If ChooseOption ('Talk') then
Begin
Result := True;
FindTalk;
ReportVars[5]:=1;
SRLRandomsReport;
exit;
end;
FindTalk;
end;
end;
Writeln ('Didn''t find, changing compass angle...');
ScrewyCompass('ran',False);
FindTalk;
FTWait(1);
DoRandoms;
FindTalk;
Until (not(LoggedIn)) or (TimeFromMark (TimeMarker) > SearchTime);
Writeln ('Didn''t find Luthas in ' +IntToStr(SearchTime) +' seconds, switching player...');
Players[CurrentPlayer].Active:=False;
Exit;//Exits and changes player to false
end;
Procedure Qwait;
Var
i:integer;
Begin
LoginCheck;
For i:= 0 to 4 do
Begin
If(FindNpcChatText('wait') or FindNpcChatText('Please'))Then
Wait(250+random(1000));
If(Not(FindNpcChatText('wait') or FindNpcChatText('Please')))Then
Begin
Wait(500+random(1000));
Exit;
End;
End;
Writeln('Waited for "please wait" to go away for la while...');
Writeln('Switching players...');
Players[CurrentPlayer].Active:=False;
Exit;//Exits and changes player to false
End;
Function GetQuest: Boolean;
Var
i:integer;
Begin
LoginCheck;
Result:=False;
Wait(4+random(2))
Players[CurrentPlayer].Loc:='Getting quest';
For i:= 0 to 2 do
Begin
If(FindNpcChatText('run')) then//If not started yet
Begin
Qwait;
ClickNpcChatText('lick here',True);//1-6
Qwait;
ClickNpcChatText('employment',True);//2-6
Qwait;
ClickNpcChatText('lick here',True);//3-6
Qwait;
ClickNpcChatText('lick here',True);//4-6
Qwait;
ClickNpcChatText('lick here',True);//5-6
Qwait;
ClickNpcChatText('lick here',True);//6-6
Qwait;
Writeln('Quest started');
Result:=True;
Exit;
End;
If (FindNpcChatText('you completed')) then //In in the middle
Begin
ClickNpcChatText('lick here',True);
Qwait;
ClickNpcChatText('the crate isn',True);
Qwait;
ClickNpcChatText('lick here',True);
Qwait;
ClickNpcChatText('lick here',True);
Qwait;
Writeln('You are in the middle of the quest, lets get bananas!');
Result:=True;
Exit;
End;
If (FindNpcChatText('ve filled the')) then//If done
Begin
ClickNpcChatText('lick here',True);
Qwait;
ClickNpcChatText('lick here',True);
Qwait;
ClickNpcChatText('ill you pay me',True);
Qwait;
ClickNpcChatText('lick here',True);
Qwait;
ClickNpcChatText('lick here',True);
Qwait;
ClickNpcChatText('lick here',True);
Qwait;
Inc(Players[CurrentPlayer].Integers[1]);
Inc(Players[CurrentPlayer].Integers[5]);
Writeln('finished quest and started another one');
ReportVars[1]:=1;
ReportVars[2]:=30;
SRLRandomsReport;
Result:=True;
Exit;
End;
End;
Writeln('Something screwed up so...');
Writeln('Switching players...');
Players[CurrentPlayer].Active:=False;
Exit; //switch player to false and exit
End;
Function GetFeildColor:Integer;
Var q:TPoint;
i:Integer;
Begin
LoginCheck;
MakeCompass('n');
Result:=2596502;
Exit; //until this is fixed.
ddtmarea:=1;
ddtmtol:=20;
LoadDTMs;
For i:=0 to 5 do
Begin
IF (FindDTM(BFeild,q.x,q.y,MMX1,MMY1,MMX2,MMY2)) Then
Begin
MMouse(q.x+30,q.y+30,2,2);
Result:=GetColor(q.x,q.y);
FreeDTMs;
Exit;
End;
Inc(ddtmarea);
ddtmtol:=ddtmtol+5;
End;
Writeln('Trouble autocoloring the feild...');
FreeDTMs;
End;
Function GetLuthasMMColor:Integer; //Finish fixing autocoloring!!!
Var q:TPoint;
i:Integer;
Begin
LoginCheck;
MakeCompass('n');
Result:=195836;
Exit; //until this is fixed.
ddtmarea:=1;
ddtmtol:=20;
LoadDTMs;
For i:=0 to 5 do
Begin
IF (FindDTM(LuthasMM,q.x,q.y,MMX1,MMY1,MMX2,MMY2)) Then
Begin
MMouse(q.x+30,q.y+30,2,2);
Result:=GetColor(q.x,q.y);
FreeDTMs;
Exit;
End;
Inc(ddtmarea);
ddtmtol:=ddtmtol+5;
End;
Writeln('Trouble autocoloring luthas on the minimap...');
FreeDTMs;
End;
Function GetOutsideHouseColor:Integer;
Var q:TPoint;
i:Integer;
Begin
LoginCheck;
MakeCompass('n');
Result:=FindRoadColor;
Exit; //until this is fixed.
ddtmarea:=1;
ddtmtol:=20;
LoadDTMs;
For i:=0 to 5 do
Begin
IF (FindDTM(OutHouse,q.x,q.y,MMX1,MMY1,MMX2,MMY2)) Then
Begin
MMouse(q.x+30,q.y+30,2,2);
Result:=GetColor(q.x,q.y);
FreeDTMs;
Exit;
End;
Inc(ddtmarea);
ddtmtol:=ddtmtol+5;
End;
Writeln('Trouble autocoloring the outside of the house...');
FreeDTMs;
End;
Procedure WalkToBananas;
Begin
LoginCheck;
Players[CurrentPlayer].Loc:='Walking to bananas';
FindTalk;
MakeCompass('n');
FindTalk;
RadialWalk( GetFeildColor , 307, 267, 62, 0, 0);
FindTalk;
DoRandoms;
Flag;
ReportVars[3]:=1;
SRLRandomsReport;
FindTalk;
End;
function CountItemDTM(DTM: Integer): Integer;//Based off of the
var //one in srl for bmps
i, x, y: Integer;
TB: Tbox;
begin
GameTab(4);
for i := 1 to 28 do
begin
TB := InvBox(i);
if ExistsItem(i) then
if FindDTM(DTM, x, y, TB.x1, TB.y1, TB.x2, TB.y2) then
Inc(Result);
end;
end;
Function CountBananas:Integer;
Begin
Result:=0;
LoadDTMs;
Result:=CountItemDTM(Baranara);
FreeDTMs;
End;
Function FindABanana:Boolean;
Var i:Integer;
Begin
LoginCheck;
Result:=False;
LowestAngle;
Players[CurrentPlayer].Loc:='Finding a banana';
For i:=0 to GetArrayLength(BananaColors)-2 do
Begin
If FindObjCustom(B.x,B.y,['Pick','Banana','ick','anana','ick Ban'],[BananaColors[i],BananaColors[i+1]],10) Then
Result:=True;
End;
End;
Procedure PickBananas;
Var TimeMarker,i,Limit:Integer;
Begin
LoginCheck;
FindTalk;
MarkTime(TimeMarker);
Limit:=10
If(UseEffQuest)Then
Limit:=20
Repeat
Begin
LoginCheck;
FindTalk;
DoRandoms;
Players[CurrentPlayer].Loc:='Picking bananas';
If(FindABanana)Then
Begin
i:=CountBananas;
Mouse(B.x,B.y,1,1,true);
FindTalk;
ChooseOption('ick');
FindTalk;
If(CountBananas>i)Then
Writeln('Got a banana! YAY!');
Inc(Players[CurrentPlayer].Integers[0]);
ReportVars[0]:=1;
SRLRandomsReport;
FindTalk;
If(CountBananas>=Limit)Then
Exit;
End;
End;
Until(Not(LoggedIn));
End;
Procedure WalkBack;
Begin
LoginCheck;
FindTalk;
Players[CurrentPlayer].Loc:='Walking back';
MakeCompass('n');
FindTalk;
RadialWalk( FindRoadColor , 119, 161, 63, 0, 0);
DoRandoms;
MakeCompass('n');
flag;
FindTalk;
RadialWalk( GetLuthasMMColor , 350, 430, 70, 0, 0); //walks to Luthas
DoRandoms;
MakeCompass('n');
flag;
FindTalk;
RadialWalk( GetOutsideHouseColor , 158, 235, 25, 0, 0);
ReportVars[4]:=1;
SRLRandomsReport;
End;
Function FillUpCrate:Boolean;
Var
i:Integer;
c:TPoint;
Begin
LoginCheck;
LowestAngle;
FindTalk;
Players[CurrentPlayer].Loc:='Filling up the crate';
DoRandoms;
FindTalk;
For i:=0 to GetArrayLength(CrateColors)-2 do
Begin
If(FindObjCustom(c.x,c.y,['Crate','rate','Crat'],[CrateColors[i],CrateColors[i+1]],2))Then
Begin
Mouse(c.x,c.y,2,2,False);
FindTalk;
If(ChooseOption('Fill'))Then
Begin
Result:=True;
Exit;
End;
End;
ScrewyCompass('ran',False);
LowestAngle;
End;
End;
Procedure EfficientQuest;
Begin
If(UseEffQuest)Then
If(CountBananas>=10)Then
Begin
FindLuthas;
FindTalk;
GetQuest;
FindTalk;
FIllUpCrate;
FindTalk;
End;
End;
Procedure PlayerReport(Which:Boolean);
Var i,w,q:Integer;
Begin
ClearDebug;
Signature;
i:=0;
For q:=0 to HowManyPlayers-1 do
Begin
i:=Sum(i,Players[q].Integers[0]);
w:=Sum(w,Players[q].Integers[1]);
End;
If(Which)Then
Begin
Writeln('--------------------Version '+VersionNumber +'-----------------------------------');
Writeln('You have been picking bananas for ' +IntToStr(RunTime*60000) +' minutes.');
Writeln('You have picked a total of ' +IntToStr(i) +' bananas');
Writeln('You have done the quest a total of ' +IntToStr(w) +' times');
Writeln('You should have about ' +IntToStr(w*30) +' coins');
For q:=0 to HowManyPlayers-1 do
Begin
Writeln(' Player' +IntToStr(q));
Writeln(' Loc:' +Players[q].Loc);
Writeln(' Active:' +BoolToStr(Players[q].Active));
Writeln(' Random:' +Players[q].Rand);
End;
Writeln('Thank you for using Rotflmfwao''s AutoBananaQuester');
Writeln('------------------------------------------------------------------');
End;
If(Not(Which))Then
Begin
Writeln('------------------------------------------------------------------');
Writeln('Player:' +IntToStr(CurrentPlayer));
Writeln('Picked:' +IntToStr(Players[CurrentPlayer].Integers[0]) +' bananas');
Writeln('Completed the quest:' +IntToStr(Players[CurrentPlayer].Integers[1]) +' times');
Writeln('Location:' +Players[CurrentPlayer].Loc);
Writeln('You should have about ' +IntToStr(Players[CurrentPlayer].Integers[1]*30) +' coins');
Writeln('Thank you for using Rotflmfwao''s AutoBananaQuester');
Writeln('------------------------------------------------------------------');
End;
End;
Procedure SettingsOff;
Begin
End;
Procedure DoStuff;
Var i:Boolean;
Begin
i:=False;
MoveToTray;
FindWindowBySize(766, 504);
ActivateClient;
LoginPlayer;
DeclareColors;
MarkTime(RunTime);
LoginCheck;
If(UseEffQuest)Then
illl:=(HowManyQuests/2);
Repeat
Begin
For Players[CurrentPlayer].Integers[1]:=0 to illl do
Begin
If(AllPlayersInactive)Then
TerminateScript;
FindLuthas;
HumanStuff;
GetQuest;
WalkToBananas;
HumanStuff;
PickBananas;
HumanStuff;
WalkBack;
FillUpCrate;
HumanStuff;
EfficientQuest;
PlayerReport(False);
If(Players[CurrentPlayer].Active=False)Then
Break;
If(Players[CurrentPlayer].Integers[5]=HowManyQuests)Then
Begin
Players[CurrentPlayer].Integers[5]:=0;
i:=True;
End;
If(i)Then
Break;
End;
ChangePlayer;
i:=False;
End;
Until(RunTime>HowLongToRun*60000);
PlayerReport(True);
Writeln('Done!');
ReportVars[7]:=1;
SendSRLReport;
SRLRandomsReport;
End;
begin;///My little tiny main loop XD I <3 Procs and funcs!
SetupStuff;
StartTheShow;
If(KillUIDs)Then EraseUIDs('uid');
//DoStuff;
TerminateScript;
end.
Omg lotta code!:eek: :eek:
If you vote no, please tell me why. Thanks.
——————————————————
<!– END TEMPLATE: formanswers –>