Specifically, it seems to me that the NavigateTo function doesn’t complete, when the target of this navigation is the location of the npc that’s trying to navigate, or within it’s reach distance if used anyway. It can be fairly easily replicated by having an npc do a NavigateTo to the player on a loop. When the npc reaches the player, the loop hangs.
Something changed in the Verse core code? I got a compilation error when I loaded my project up centered around scope and the NavigateTo function. Load up your project if you haven’t yet to see if its related to that.
+1 verification, my map’s NavigateTo() function started failing 100% of the time after last update. I tried replacing game mechanics to no avail: I grabbed new NPC spawner devices and filled them out with new parameters and also tried to create a character definition from scratch and neither worked. Also tried adjusting all kinds of settings related to my navigation i.e. reach radius, navigation mesh generation, etc., anything I could find before I realized this was a bug I didn’t cause Hoping for a hotfix as well as my game completely relies on my NPC navigation script in order to be playable
Have you tried reach radius 0? Kinda works for me.
edit:
i found a fix and im just gonna hint that dont wait for Your npc to reach navigation target, instead spawn the navigateto in a loop and inside if(distance < x.x) add Your behavior(attack or w/e), if that makes any sense to You
I think it might be best to wait for the official fix. In one of my maps I have changed the destination coordinates that can be generated to ensure destination is reachable and I use race so if navigation does not return result, it completes based on short Sleep() instead. In my other map, I only fixed npc following player part, but not the normal behavior loop, so I will be able to test the fix when it is rolled out.
I tried something similar. Basically I’ll race a navigateto and a sleep call (very small like .3 seconds) and the navigation is so bad that prior navigation that would take it up or down staircases just utter fail.
Yes the error needs to be fixed in your verse file. One way to fix it is to temporarily add a new npc behavior example and locate the corresponding section in this new file and see how variable is now created in that example. Then you can use the same way in your behavior file.
If this still doesn’t fix your npc issues, you would need to address as well or wait for the official fix.
oh glad i found this, think I’m having the same issue. Mine spawn and nav as normal at first but as soon as an attack animation is initiated or called they just hang about and stop moving.
I’m having this issue if you cancel NavigateTo such as with a loop that breaks on some flag and returns navigation_result.Interrupted after which the NPC will not move again.