SRL Archive - OSR Help

Need helps with SPS.


NexPB

2012-01-11 11:37:10

How could I check if the Map I'm using aka the IMAGE is on the minimap?

Shuttleu

2012-01-11 11:41:44

do you mean check if the map you have loaded is the correct one for your current location?

~shut

putonajonny

2012-01-11 11:42:03

You could use the SPS_GetMyPos function with the SPS_PosToTile function, read descriptions at Includes/SPS/SPS.simba

Edit:
Actually I think this is wrong

NexPB

2012-01-11 11:44:14

From: Shuttleu
do you mean check if the map you have loaded is the correct one for your current location?

~shut

I'm making a Air rune crafter to practise. I want something to check if he is at the top of the altar mountain (where he can craft the runes) to do this I want to load the Map from in the sps folder (wich I know how to) but now I want to check if the map is one the minimap.

Shuttleu

2012-01-11 13:32:24

well all i can suggest is get that pos then to check if it is the correct map do a SPS_GetMyPos and check its output with what you think it should be

if its too far off then i guess you can assume its the wrong map

oh and sorry for the delay

~shut

NexPB

2012-01-11 13:42:04

From: Shuttleu
well all i can suggest is get that pos then to check if it is the correct map do a SPS_GetMyPos and check its output with what you think it should be

if its too far off then i guess you can assume its the wrong map

oh and sorry for the delay

~shut

Gonna test this.

EDIT: Doesn't seem to work :s

NexPB

2012-01-11 17:04:44

I recive this error now Error: Exception: Type Mismatch at line 100

The line:

SPS_Setup(RUNECRAFTING_ALTARS, [0, 0]);

'Toxin

2012-01-11 17:17:27

From: NexPB
I recive this error now Error: Exception: Type Mismatch at line 100

The line:

SPS_Setup(RUNECRAFTING_ALTARS, [0, 0]);


Create a string and compare the resultant with your location. Also, take out SPS_Debug = true; from your code (I had this happen to me when I was debugging with SPS, for some reason you have to create a string and then toss the resultant into it, then you can do a comparison.)

Shuttleu

2012-01-11 19:03:00

From: NexPB
I recive this error now Error: Exception: Type Mismatch at line 100

The line:

SPS_Setup(RUNECRAFTING_ALTARS, [0, 0]);

0, 0 should be a string
so you want this

SPS_Setup(RUNECRAFTING_ALTARS, ['0, 0']);

~shut

NexPB

2012-01-12 10:45:23

From: Shuttleu
0, 0 should be a string
so you want this

SPS_Setup(RUNECRAFTING_ALTARS, ['0, 0']);

~shut


Ty didn't know this.

edit: fixed it but SPS-GetMyPos didn't seem to work .. Anything else i can try?

Mat

2012-01-12 12:52:36

Hey man When I was Making a Fire Runner gave up :P Might re try again the SPS altar walking I had to use RadialWalk as Its the only one that worked. :)
Mat

NexPB

2012-01-12 13:26:15

From: Aligndude
Hey man When I was Making a Fire Runner gave up :P Might re try again the SPS altar walking I had to use RadialWalk as Its the only one that worked. :)
Mat

Im using radial walk and dtms to get to altar but I want something to know when im at the altar area