13 Replies

If you create a NavMeshAgent and set its position via transform.position=... and then try to SetDestination, it fails because the NavMeshAgent did not recognize the position change and does not know that it already is on the NavMesh. Use NavMeshAgent.Warp instead of transform.position to initialize the position before calling SetDestination.

I had the same issue... In your scene click on a mesh or train and then in Window tabs select navigation... Now u can see navigation layout beside the inspector... Just in bake tab of navigation click the bottom button that says Bake... And you're done