Jump to content
Sign in to follow this  
CarlGustaffa

Next Waypoint

Recommended Posts

Hi

In order to test my mission (quite large distances), I need to activate next waypoint. Is this possible to do via scripting? I can't find a specific command that does this.

Share this post


Link to post
Share on other sites

Use setCurrentWaypoint to activate the next waypoint manually before reaching it.

This works fine if you know the next waypoint to use.

Unfortunately, there is no command available to tell you what your current waypoint is (eg: we need a command like getCurrentWaypoint). So, you need to track all of this manually.

Because of this massive oversight, I use a set of scripts to track all waypoint related functions. (eg: setWP, setCurrentWP, getCurrentWP, delWP, WPTriggered, etc)

Share this post


Link to post
Share on other sites

I'm having issues with WP commands in general it seems confused_o.gif

Why doesn't this work, within a trigger?

gMyGroup addWaypoint [[getMarkerPos "mPos" select 0, getMarkerPos "mPos" select 1, 0], 10]

or simpler, this:

gMyGroup addWaypoint [getMarkerPos "mPos", 10]

All I'm getting is "type array, expected nothing". And the biki states:

_wp = grp addWaypoint [ position player, 0]

The group has one waypoint, which takes it into the trigger area.

When I'm using doMove, I get AI squads to move there, but no waypoint is visible to player if leader.

Arrg, all these syntax'es seem impossible to learn banghead.gif

Edit: Sort of figured it out, I needed that g= or whatever and it worked. But, ehh, why?

Share this post


Link to post
Share on other sites

It sounds like you've got it sorted now, based on your edit.

Move commands and waypoints are unrelated. Executing a move command will not show a waypoint or a HUD waypoint indicator.

However you can add a waypoint of type "MOVE" (using setWaypointType) and this is what appears as the HUD waypoint, once that waypoint become the current waypoint. You can also change this using setWaypointDescription.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×