Page 1 of 1

Force script to start at first WP not closest?

Posted: Mon Jan 07, 2013 11:45 am
by Buster99
When I am running a script and then load another path there are times when the bot takes me to "closest" WP instead of starting with my frist WP written in script.

Is there way to prevent this? I simply want script to always start at WP #1.

Thanks

Re: Force script to start at first WP not closest?

Posted: Mon Jan 07, 2013 11:55 am
by rock5
When loading a waypoint file it starts at the closest waypoint. This is as intended. If you want to make sure it starts at waypoint one then add this to the waypoint onload

Code: Select all

<onload>
__WPL:setWaypointIndex(1)
</onload>

Re: Force script to start at first WP not closest?

Posted: Mon Jan 07, 2013 12:05 pm
by Buster99
Perfect.

Thanks Rock!