Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

NavMesh creates navigatable terrain under obstacles

Discussion in 'Navigation' started by FeastSC2, Nov 16, 2019.

  1. FeastSC2

    FeastSC2

    Joined:
    Sep 30, 2016
    Posts:
    978
    My NavMesh is baking some areas that it should not, the obstacles I place on my the terrain are not completely removing the navmesh underneath them.


    The room is this. The units should not go underneath the path.
    upload_2019-11-16_20-27-45.png


    Here it is again with the NavMesh. The NavMesh is creating areas to walk on underneath the obstacles I'm placing on top of the terrain.

    upload_2019-11-16_20-28-46.png


    How to remove the baking of the areas beneaths the paths that are intersecting with the ground?
     

    Attached Files:

  2. DwinTeimlon

    DwinTeimlon

    Joined:
    Feb 25, 2016
    Posts:
    300
    Did you try and add a
    NavmeshModifier
    to your obstacles you want to block and set the correct layer settings?
     
    FeastSC2 likes this.
  3. FeastSC2

    FeastSC2

    Joined:
    Sep 30, 2016
    Posts:
    978
    In that case I'd have to use the extended package of NavMesh. From what I understood, that means adding the NavMeshSurface component everywhere, that's fine and I might go down that path eventually. But I'm starting to wonder if Unity's NavMesh system is the way for my game.
    Mhh... I'll hold off on fixing that detail and figure if NavMesh is really what I want to use. Thanks for the suggestion though.