Using multiple nav locs

Xiggie

New member
Joined
May 7, 2010
Messages
13
Reaction score
6
Points
3
When using mq2nav in a mac it just skips to the last nav location. I tried fixing it in various different ways but I probably just don't know how the language works. Idealy I would like have my toon nav to one particular location and then from there to the next. I tried guessing at the language but so far no luck. Below is what I have so far but it still just goes to the last nav loc and bypasses the first one. The sub nav is what I had from my sub move stuff. Any help would be appreciated.

/call nav -1756 1234
/call nav -1698 1245

Sub Nav(int y, int x)
/squelch /nav locyx ${y} ${x}
:wait
/call Zonetest
/doevents
/if (${Me.Moving}) {
/delay .5s
/goto :Wait
}
/return
 
It might be skipping your condition if your character hasn't started moving yet.
I can't test it right now but perhaps try using ${Navigation.Active} instead of ${Me.Moving}
I would also change "/goto :Wait" to "/goto :wait" in case it's case sensitive. If so, that would also cause it to skip ahead.
 
Last edited:
  • Like
Reactions: Xiggie
Alternatively you could check your location has reached point a before calling nav to location b
 
  • Like
Reactions: Xiggie
Alternatively you could check your location has reached point a before calling nav to location b

I don't know that command. Can you give an example of how you would check to see if you have reached a location that would work in that sub? And again, thank you.
 
It might be skipping your condition if your character hasn't started moving yet.
I can't test it right now but perhaps try using ${Navigation.Active} instead of ${Me.Moving}
I would also change "/goto :Wait" to "/goto :wait" in case it's case sensitive. If so, that would also cause it to skip ahead.


The Navigation.Active is exactly the language I was looking for. Thank you!
 
  • Like
Reactions: addington89
For example rather than just
/call nav -1756 1234
/call nav -1698 1245

use
/call nav -1756 1234
/if (${Math.Distance[-1756 1234]}<20) /call nav -1698 1245

that way you check your distance from point a before moving to point b.
 
Sub Nav(int y, int x)
/if (${Math.Distance[${y},${x}]}>5 && ${Navigation.PathExists[${y} ${x}) {
/squelch /nav locyx ${y} ${x}
}
:wait
/call Zonetest
/doevents
/if (!${Navigation.Active} && ${Math.Distance[${y},${x}]}>5 && ${Navigation.PathExists[${y} ${x}) {
/squelch /nav locyx ${y} ${x}
}
/if (${Navigation.Active}) {
/delay .5s
/goto :Wait
}
/return



HAHA, maximoh posted while I was going thru everything. So first check will only make you nav to the loc if it is more than 5 distance away (can change that to whatever distance you want) and only do it if nav can get a path. Then do your zonetest, then events, then check to make sure you are naving and not reached the destination, then if you are still moving will go to wait.