How do I generate a good navmesh for uneven procedurally generated terrain?
I am new to this thing. I used the NavMeshComponents's NavMeshSurface to generate the navigation mesh, however, the mesh generated doesn't seem to fit the terrain since the player gets stuck on the parts that are not covered in blue. Also, I am confused about why the navmesh in the game and scene views are different.
Answer by tormentoarmagedoom · Mar 08, 2020 at 11:36 AM
Hello there.
You should watch some advanced tutorials about navmesh generations.
For your imgae, it seems the slope is too high to generate the navemesh (with your current configuration) there (You can configure the maxslope in the namesh tab in inspector).
The blue areas is the surfaces that can be navigated, this area is generated following some values of Agent size, agent heigh, max slope, etc.
There are so many properties, you should take your time, investigate and try all of them.
Dont try to go fast, go step by step, make some tests in a small area to explore and try try try!
Good luck!
Answer by Newdevlper · Mar 08, 2020 at 05:35 PM
Thanks for the info. I played with the values for voxel size and slope height which ended up fixing the problem.