Hi all,
I need to implement AI for vehicles moving on terrain with static and dynamic obstacles.
I am thinking of using the built int NavMesh and NavMeshAgent.
My Idea is to translate NavMeshAgent computed position, velocity and orientation into input commands for the vehicle to which NavMeshAgent is attached (I do not want NavMeshAgent to update the vehicle’s state [position, velocity, rotation, angular velocity]) in order for the vehicle to move basically like the NavMeshAgent would move (I will try and compute NavMeshAgent max speed, angular speed depending on the vehicle locomotion model).
The vehicles move in the Physics FixedUpdate.
The problem is that a vehicle has strong physics and locomotion model constraints, so the NavMeshAgent position and orientation will be (hopefully slightly) different from the vehicle’s ones.
Can I simply once in a while warp the NavMeshAgent to the vehicle’s position and rotation? Would this affect the obstacle avoidance computation making it not accurate for at least one frame?
Hash anybody tried this approach?
Thanks