SRL Archive - OSR Help

damn again.


imaloser

2011-12-28 23:41:26

No matter what Tree I do my mouse from start up of this script goes to my inventory icon and just chills there, little movement around as if it were seeking out the color from the inventory icons color.

No Statsguise, no nothing.

Run > Mouse moves to inventory icon > Stays on the Icon > Gf my first script.

Any ideas?


program imalosersPCHOPPA;

//{$DEFINE SMART}
{$i SRL\SRL.scar}
{$i SRL\SRL\Misc\stats.simba}

Const
//SRL Stats
SRLStats_Username = '';
SRLStats_Password = '';
BreakEvery = 120;
Breakfor = 5;
NumbofPlayers= 1;
StartPlayer= 0;



Procedure DeclarePlayers;
var I:Integer;
Begin
NumberOfPlayers(NumbOfPlayers);
CurrentPlayer := StartPlayer;
for i := 0 to NumbOfPlayers-1 do
Players[i].BoxRewards := ['XP', 'Gem', 'ostume', 'ithril', 'oal', 'une'];

with Players[0] do
Begin
Name := ''; //Player Username.
Pass := ''; //Player password.
Active := True;
Integers[1] := 4; //1=BrightCopper,2=DarkCopper,3=Tin,4=Iron.
Integers[2] := 4; //Seconds to try mining rock before clicking another.
end;

end;

Procedure StatsGuise(wat:String);
begin
Status(wat);
Disguise(wat);
end;


Procedure Antiban;
Begin
Case Random(300) Of
0: Begin StatsGuise('AntiBan') GameTab(tab_Stats) HoverSkill('Woodcutting', False) GameTab(28) End;
1: Begin StatsGuise('AntiBan') SleepAndMoveMouse(7000 + Random(500)); End;
2: Begin StatsGuise('AntiBan') GameTab(tab_Inv) ExamineInv; GameTab(28); End;
3: Begin StatsGuise('AntiBan') RandomAngle(1); End;
4: Begin StatsGuise('AntiBan') GameTab(Tab_Stats); Wait(3000 + Random(500)); GameTab(28); End;
5: Begin StatsGuise('AntiBan') GameTab(tab_Stats) HoverSkill('random', False); GameTab(28); End;
End;
End;

Procedure Failsafe(reason:string);
Begin
Players[CurrentPlayer].Loc:=Reason;
Logout;
Stats_Commit;
TerminateScript;
End;


function Chopdown:Boolean;
Var
SeX, SeY, Baggedit, TreeCounter: Integer;
Begin
Baggedit:= InvCount + 1;
//If FindObjCustom(SeX , SeY, ['Chop', 'down', 'Maple', 'tree', 'p d'], [837635, 1187643, 330048, 1319487], 6) Then
SeX:=MSCX;
SeY:=MSCY;
If FindObjTPA(SeX, SeY, 1714726, 3, 1, 15, 60, 450, ['Cho']) Then
Begin
StatsGuise('Fk Yea, We found them Capitan!!');
GetMousePos(SeX, SeY);

Case Random(2) of
0: Mouse(SeX, SeY, 5, 5, True);
1: Begin
Mouse(SeX, SeY, 5, 5, False);
WaitOption('Chop Down', 600);
End;
End;


Repeat
MarkTime(TreeCounter);
Antiban;
Wait(800);
If InvCount=Baggedit then
WriteLn('We got one');
Until (InvCount=Baggedit) Or (TimeFromMark(TreeCounter) > 4000)

End;
End;


Procedure Droplogs;
Var
SeX, SeY, LogDTM, I:Integer;
SlotBox:Tbox;
LogPattern:TIntegerarray;

Begin


LogDTM := DTMFromString('mbQAAAHicY2VgYHBiYmAwBWI7IHYHYi8gfgIUfwPE74H4NRDfBOJAU26G0iAVhihrHoYYG14GazUOhv8MmIARCwYDAL98Cgg=');
LogPattern:=[18,9,12,3,14,2,16,1,13,27,11,19,4,15,20,6,24,28,5,22,23,7,25,17,8,26,10,21];

For I:=0 to 27 Do
Begin
SlotBox:=InvBox(LogPattern[I]);
If FindDTm(LogDTM,SeX,SeY,SlotBox.X1,SlotBox.Y1, SlotBox.X2, SlotBox.Y2) Then
Begin
MouseItem(LogPattern[I],False);
ChooseOption('Dro');
End;
End;

End;





Begin

SetupSRL;
DeclarePlayers;
Repeat
Chopdown;
If InvFull Then
DropLogs;
Until(False);

End.

PatDuffy

2011-12-28 23:51:25

Well for one you decalred ChopDown as a function when you used it like a procedure.

imaloser

2011-12-28 23:55:00

From: PatDuffy
Well for one you decalred ChopDown as a function when you used it like a procedure.


Explain?

Tryna learn mannn! Lemme know whats good

Yanhua

2011-12-28 23:57:59

From: imaloser
Explain?

Tryna learn mannn! Lemme know whats good


In your Function, there is no line saying when the Result := True.

If you want to use it like that, call it as a procedure :)

imaloser

2011-12-29 00:06:15

From: Yanhua
In your Function, there is no line saying when the Result := True.

If you want to use it like that, call it as a procedure :)


"Procedures ChopDown;"

Check!

But the same problem? Cursor goes straight for the inventory icon as soon as I hit start :[

weequ

2011-12-29 05:19:08

Are you using Safe mode? SRL include only works with safe mode. Safe mode can be loaded by pressing 'S' while runescape is loading.

If you are running safe mode then there might be something wrong with your chopdown procedure.

Try messing with this:
If FindObjTPA(SeX, SeY, 1714726, 3, 1, 15, 60, 450, ['Cho']) Then

and change your second last line in the chopdown procedure to this:
End else WriteLn('NOT FOUND :_(');