Search Unity

ProBuilder & NavMesh Generation

Discussion in 'Navigation' started by GIitch, Mar 5, 2018.

  1. GIitch

    GIitch

    Joined:
    Aug 1, 2013
    Posts:
    24
    I've been experimenting with ProBuilder as an alternative to traditional whiteboxing, and I've run into a problem with Unity generating NavMeshes around ProBuilder objects that are unusually shaped. The Navmesh Generation doesn't align correctly with the edge of these objects and Agents can't reach their intended target because of it. Is there anything I can do to fix this? I really like this tool, but I don't think I can use it if this problem persists.



    (I'm sure there are threads similar to this, but the forum's search function doesn't seem to be working)

    I'd appreciate any help offered, thanks!
     

    Attached Files:

  2. GIitch

    GIitch

    Joined:
    Aug 1, 2013
    Posts:
    24
    Fixed it! Turning off the 'Carve' option in Nav Mesh Obstacle enabled the NavMesh to get closer to those objects.
     
    tkshredder likes this.
  3. Harinezumi

    Harinezumi

    Joined:
    Jan 7, 2013
    Posts:
    54
    I think the actual problem is that the shape of your NavMeshObstacles is "Box", so even though you have a circular object or an L-shaped wall, the obstacle will fit to the bounding box of your object.
    Turning off carving will work, but it is less efficient, and you might get agents trying to pass through the obstacles.

    An optional solution is to download Unity's NavMeshComponents, and use a NavMeshSurface whose Use Geometry parameter is set to Render Meshes.