- Home /
NavMesh - Different NavMeshAgent radius for gaps vs platforms
My NavMeshAgent has a radius of 1, (i.e, Diameter of 2).
That means it cannot pass through gaps smaller than 2. When I bake, the NavMeshSurface determines this correctly.
But there is not problem with a NavMeshAgent walking on top of a narrow platform, walkway, or ramp with a radius of 1. Or even smaller.
Is it possible to set different radius thresholds for when navigation is blocked by positive terrain (walls and obstacles that stop the NavMeshAgent getting close to the obstacle) vs negative terrain (pits and cliffs that the NavMeshAgent cannot walk directly on top of, but can get very close to without falling).
My AI controls an Character with the same properties as the player. The player quickly realises they cannot pass through small gaps, but nothing physically stops them walking along bridges.
So far, the next workarounds I'm considering are:
1. Add 'helper' quads to walkable surfaces that are less than 2 units wide. These quads will make a surface of width 1 appear to be width 2 to the agent.
2. Do the opposite to 1. Reduce the radius of the nav mesh agent to 0.5, and add obstacles to any gaps of smaller than 2, and also add obstackles protruding from walls the agent cannot get close to. This approach seems like a lot more work.
3. Abandon the build in NavMesh framework. My levels are generated from 3d tile data (think minecraft) which means I can generate a network to apply A* too without too much work.
How have other people solved this? Or how would you solve it?
Your answer
Follow this Question
Related Questions
NavMeshAgent doesn't face to it's destination in close distance! 1 Answer
How can i modify the navMesh path? 0 Answers
NavMesh Agent not updating (Setting) new path 1 Answer
Connecting two navmeshes without "Speedboost" 0 Answers
is it possible to use navmesh on flying character and target ? 0 Answers