I’m using Unity to do operational analysis…so I need the game to play out the same for given input every time it runs.
I’ve managed to do this by having one script that listens for MonoBehaviour.FixedUpdate, and calls my own game loop…so I can control which order the GameObjects do their updating (instead of the MonoBehaviour everything-at-once not-repeatable randomisation). All repeatable now.
I can’t easily escape MonoBehaviour if I use the built-in NavMeshAgent stuff. If I try to control it so it only navigates during my game loop…it never moves. And letting it do its own thing is not repeatable. I need the characters to move to the same places at the same time (everything else being equal) everytime the game runs, so that I can seed the randomisation properly and have repeatable results.
So my question is: how repeatable is the A* Pathfinding behaviour ? Will an agent take the same time to find a path and move every time ? And/or is there a way can I take control of its game loop, or is the only way to use it relying on FixedUpdate?
Thanks in advance