SRL Archive - OSR Help

script wont run


bmxgt187

2013-02-07 10:28:33

hello i have been tryin to run this script and it starts running fine for a little while my guess would be 10-20 minutes then it comes up with this.

Error: Out Of Range at line 107
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, SRL - NavBar Bitmap

The script is here. i have put this also on the thread of this script and no one has answered it. it will also fight then like 3 seconds later say in debug box that the monster is dead when it isnt and start clicking other mosters. any help would be great thanx.

 program Auto_Soulsplit_Fighter;
{$i srl/srl.simba}

//This Script Does Not Seem To Work On The SoulSplit Downloadable Client!


//It Does Work On The Web Client But You Need To Resize The Web Page To Fit The Client!


//If That Does Not Work You Can Use SwiftKit For Runescape And Open SoulSplit.
//There Are Details Online On How To Do That. (This Is What I Use)



//SETUP

// Please Login To SoulSplit Then Go To The Monster You Want To Kill,
// Use "Pick A Colour" And Get A Unique Monster Colour And Set A Colour Tolerance.
// When Ready To Run The Script Press "PAGE DOWN" To Fully Zoom Out And Keep
// The Camera Angle As Standard Or PixelShift Will NOT Work Properly.

// PixelShift May Need To Be Adjusted A Bit To Get It Working Perfect For You.

const
COLOR = 10922181; // Monster Colour
TOL = 15; // Colour Tolerance

///////////////////////////////////////////////////////
//PLEASE DO NOT TOUCH UNLESS YOU KNOW WHAT YOUR DOING//


function Click(): boolean;
var
x, y, w, h: integer;
B: TBox;
begin
GetMousePos(x, y);
w := 525;
h := 338;
GetClientDimensions(w, h);
B := IntToBox(x - 15, y - 15, x + 15, y + 15);
if B.x1 < 0 then B.x1 := 0;
if B.y1 < 0 then B.y1 := 0;
if B.x2 > w then B.x2 := w;
if B.y2 > h then B.y2 := h;
begin
if findColorTolerance(x, y, 62713, B.x1, B.y1, B.x2, B.y2, 20) then
begin
Result := True
Exit;
end;
end;
end;


Function YellowClick: Boolean;
begin
Result := Click;
end;


Function RedClick: Boolean;
begin
Result := Not Click;
end;


Function Moving: Boolean;
var
MovingBox: Tbox;
begin
MovingBox := IntToBox(259, 133, 272, 151);
Result := (AveragePixelShift(MovingBox, 500, 300) > 80);
//Writeln(IntToStr(AveragePixelShift(MovingBox, 500, 300))); //Shows PixelShift in debug

end;


Function InFight: Boolean;
var
InFightBox: Tbox;
begin
InFightBox := IntToBox(260, 137, 277, 185);
Result := (AveragePixelShift(InFightBox, 500, 300) > 100);
//Writeln(IntToStr(AveragePixelShift(InFightBox, 500, 300))); //Shows PixelShift in debug

end;


procedure FindMonster;
var
I, Kill : Integer;
Corners, TPA: TPointArray;

begin
Corners := [Point(266, 174), Point(0, 0), Point(520, 0), Point(0, 340), Point(520, 340)];// Corners of the client and center point
I := 0

begin
repeat
if I = 4 then
Exit;

if FindColorsSpiralTolerance(Corners[i].X, Corners[i].Y, TPA, COLOR, MSX1, MSY1, MSX2, MSY2, TOL) then
begin
MarkTime(Kill);
Mouse(TPA[i].X, TPA[i].Y, 0, 0, true);
Writeln('Attempting To Attack!');

if YellowClick then
begin
Writeln('');
Writeln('Missed!');
Writeln('Searching Again!');
Writeln('');
Continue;
end;

if RedClick then
begin
Wait(1500);

if (TimeFromMark(Kill) > 2000) and not Moving then
begin
Writeln('');
Writeln('Monster Already Infight');
i := i + 1;
Writeln('Searching Again!');
Writeln('');
Continue;
end else

if InFight then
begin
Writeln('Attacking!');
begin
repeat
Wait(200);
until not InFight and not Moving or (TimeFromMark(Kill) > 12000);
end;
Writeln('Monster Dead!');
Writeln('');
Wait(1500);
end;
end;
end;
until (false);
end;
end;



begin
SetupSRL;
ClearDebug;
begin
repeat
FindMonster;
until (false);
end;
end.

Kevin

2013-02-07 10:35:40

Please put your script in [simba[ tags for readability reasons. Is this a script you got from Villavu or from a different website?

bmxgt187

2013-02-07 10:45:52

its from villavu.. sorry i am at work i couldnt do it.. i try to get all this done at work so when i get home its all play

Kevin

2013-02-07 11:30:45

From: bmxgt187
its from villavu.. sorry i am at work i couldn't do it.. i try to get all this done at work so when i get home its all play


If you found the script here, you should respond to where the script is actually located so the author can help you. And as far as using Simba tags, I've never had any problem adding them while at work, or even from my phone for that matter.

bmxgt187

2013-02-07 11:39:21

From: nivek1989
If you found the script here, you should respond to where the script is actually located so the author can help you. And as far as using Simba tags, I've never had any problem adding them while at work, or even from my phone for that matter.


as stated above i have posted it there and no response like 4 days now.. so im trying to find answers else where. i dont know how to use simba tags or i would have

Kevin

2013-02-07 11:55:57

To use Simba tags, you put [simba[ before the code and [/simba[ after the code. The issue is, the second '[' should be a ']'.

Have you tried messaging the author? I would offer my help, but I noticed that's a rsps script and I'm not as familiar with those.

bmxgt187

2013-02-07 13:37:41

anyone got any tips on this for me? and i tried to do the
 and [simba] after the code but i guess im not getting it

Kevin

2013-02-07 13:43:22

From: bmxgt187
anyone got any tips on this for me? and i tried to do the
 and [simba] after the code but i guess im not getting it


The second simba is [/simba[

bmxgt187

2013-02-07 13:46:18

From: nivek1989
The second simba is [/simba[


lol nice!! got it to work wow your right that looks so much better thank you!!

rj

2013-02-07 18:03:36

The author posted the script in August he won't be getting a response from the author.

bmxgt187

2013-02-08 12:30:31

From: rjj95
The author posted the script in August he won't be getting a response from the author.


ya im not sure what to do lolz i would like to just get one that clicks on the color selected and waits like 5 seconds then clicks next color how hard would that be to make on a rsps? and why would it be different for rsps?

rj

2013-02-08 19:35:49

From: bmxgt187
ya im not sure what to do lolz i would like to just get one that clicks on the color selected and waits like 5 seconds then clicks next color how hard would that be to make on a rsps? and why would it be different for rsps?


Easy. Look in script tutorials