Kleinbart Posted December 25, 2022 Posted December 25, 2022 Hello all When I run the following function, DCS crashes. function gotoWP() local goToWaypoint= { id = 'goToWaypoint', params = { fromWaypointIndex = 1, goToWaypointIndex = 10, } } Group.getByName('Air-1'):getController():pushTask(goToWaypoint) end With this alternative function nothing happens at all. function gotoWP() local SwitchWaypoint = { id = 'SwitchWaypoint', params = { fromWaypointIndex = 1, goToWaypointIndex = 10, } } Group.getByName('Air-1'):getController():setCommand(SwitchWaypoint) end Am I missing something or is this a bug? Thanks for your help
Grimes Posted December 26, 2022 Posted December 26, 2022 goToWaypoint is the task for ground and ship groups. Switch waypoint is for aircraft. I need to report the crash issue because it is easy to get them mixed up and it should be handled. Out of curiosity is waypoint 10 the landing waypoint? If it is then try setting it to 9 or add a waypoint over the base. AI ignore the task if told to go to a landing waypoint. The right man in the wrong place makes all the difference in the world. Current Projects: Grayflag Server, Scripting Wiki Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread) SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum
Kleinbart Posted December 26, 2022 Author Posted December 26, 2022 That's it, thanks for your help Gimres. To a happy new yearl
TEMPEST.114 Posted February 18, 2023 Posted February 18, 2023 On 12/26/2022 at 6:08 AM, Grimes said: AI ignore the task if told to go to a landing waypoint. Could that be mentioned somewhere in the 'documentation' as well as all the other 'gotchas' that no one would otherwise know. I've spent months wondering why this wasn't working and trying to fix it. What a waste of damn time...
Recommended Posts