Log in

View Full Version : Trouble with sps-(



CynicRus
06-18-2012, 12:25 PM
Hi. So, i have a problem with a script.
I initialize sps:

procedure SetupSps;
begin
SPS_Setup(RUNESCAPE_SURFACE, ['6_8']);
end;
after - generate waypoint path with Wolygon's Path Creator,
and use this path:


procedure GoToBank;
var
GoBank: TPointArray;
begin
ClickNorth(SRL_ANGLE_None);
Writeln('Walking to Bank...');
GoBank := [Point(2508, 3412), Point(2482, 3417), Point(2472, 3444), Point(2451, 3475), Point(2430, 3489), Point(2412, 3496), Point(2410, 3526), Point(2454, 3526)];
if SPS_WalkPath(GoBank) then
Writeln('At the Bank..');
while(IsMoving) do
Wait(Random(5000));

end;

This code is compile without any error, but after run it I infinitely see

formWriteln: Walking At Bank and doesn't nothing. How i can fix to this problem?

Mat
06-18-2012, 12:42 PM
The World Map might need updating where is '6_8' that location as some location are bad on world Map.

putonajonny
06-18-2012, 12:48 PM
if it isn't coming up with "At the Bank.." then that means it is failing to walk.. is everything else in the script working ok?

put this in your script just after SPS_Setup

SPS_Debug := True;Then run the script and It will give you more of an idea of what is going wrong...

CynicRus
06-18-2012, 01:20 PM
After - SPS_Debug:= true - script is working. Mystic.

But after second start,

SPS_GetMyPos: Finished in 281 ms. Result = (-1, -1)
SPS_GetMyPos: Finished in 297 ms. Result = (-1, -1)
SPS_GetMyPos: Finished in 280 ms. Result = (-1, -1) i see that in debug window.
After first run with debug :


formWriteln: Walking to Bank...
formWriteln: SPS_GetMyPos: Finished in 296 ms. Result = (2503, 3407)
formWriteln: SPS_GetMyPos: Finished in 296 ms. Result = (2479, 3431)
formWriteln: SPS_GetMyPos: Finished in 296 ms. Result = (2475, 3463)
formWriteln: At the Bank..
formWriteln: Successfully executed.