Roflme
2012-05-15 20:58:04
EDIT: And sorry if this is the wrong section.
So I was following YoHoJo's tutorial for making my first script.
I understand there's a thread for it Here but I posted there and had no luck so I'm hoping I can get an answer here.
So this is the script so far:
I stopped scripting up to the point in the video where YoHoJo begins to test the script by having it cut down a few trees one at a time.
When I hit play, the mouse will go to a tree, kind of does a "twitch" (stays on the tree color, but kind of shakes a bit), and then I get this error:
Can anyone help me out? :( :( :( :( :( :( :(
So I was following YoHoJo's tutorial for making my first script.
I understand there's a thread for it Here but I posted there and had no luck so I'm hoping I can get an answer here.
So this is the script so far:
Program PowerChopper;
//{$DEFINE SMART}
{$i SRL\SRL.simba}
Const
SRLStats_Username = '';// Your SRL Stats Username
SRLStats_Password = '';// Your SRL Stats Password
BreakEvery = 120; //How Many Minutes To Break After
BreakFor = 20; //How Long To Break For
Version = '1.0';
procedure DeclarePlayer;
begin
HowManyPlayers := 1;
NumberOfPlayers(HowManyPlayers);
CurrentPlayer := 0;
Players[0].Name := ''; //Your Runescape username
Players[0].Pass := ''; //Your Runescape password
Players[0].Active := True;
end;
Procedure StatsGuise(wat:String);
Begin
Status(wat);
Disguise(wat);
End;
Function CheckAndClick(Uptext, Option:String; X,Y:Integer; RClick:Boolean):Boolean;
Begin
MMouse(x, y, 5, 5)
If WaitUptext(UpText, 1500+Random(500)) Then
Begin
Result:=True;
GetMousePos(x, y);
If RClick Then
Begin
Mouse(x, y, 0, 0, False);
Result:= WaitOption(Option, 5000);
If Result Then FFlag(0);
End Else
Begin
Mouse(x, y, 0, 0, True);
Wait(100+Random(100));
FFlag(0);
End;
End;
End;
Procedure Antiban;
Begin
Case Random(250) Of
0: Begin StatsGuise('AntiBan') GameTab(tab_Inv) ExamineInv; GameTab(28); End;
1: Begin StatsGuise('AntiBan') RandomAngle(1); End;
2: Begin StatsGuise('AntiBan') GameTab(tab_Stats) HoverSkill('Woodcutting', False); GameTab(tab_Inv); End;
3: Begin StatsGuise('AntiBan') GameTab(tab_Stats); Wait(3000+Random(500)); GameTab(tab_Inv); End;
End;
End;
Procedure FailSafe(Reason:String);
Begin
Players[CurrentPlayer].Loc:=Reason;
Logout;
Stats_Commit;
TerminateScript;
End;
Function ChopDown:Boolean;
Var
seX, seY: Integer;
Begin
if FindObjCustom(seX, seY, ['Chop', 'Down'], [1056282, 1582114], 5) Then
begin
StatsGuise('Hooray, we found a tree');
GetMousePos(seX, seY);
Case Random(2) Of
0: Mouse(seX, seY, 5, 5, True);
1: Begin
Mouse(seX, seY, 5, 5, False);
WaitOption('Chop', 500);
End;
End;
End;
End;
begin
SetupSRL;
DeclarePlayer;
//repeat
ChopDown;
//until(false);
end. I stopped scripting up to the point in the video where YoHoJo begins to test the script by having it cut down a few trees one at a time.
When I hit play, the mouse will go to a tree, kind of does a "twitch" (stays on the tree color, but kind of shakes a bit), and then I get this error:
New window: 14288022
[Hint] (71:10): Variable 'Result' never used at line 70
Compiled successfully in 578 ms.
SRL Compiled in 0 msec
Exception: Range check error at line 840
The following DTMs were not freed: [SRL - Lamp bitmap, 1]
The following bitmaps were not freed: [SRL - Mod bitmap, SRL - Admin bitmap, SRL - Flag bitmap]
Can anyone help me out? :( :( :( :( :( :( :(