Search Unity

Question Nav Mesh Surface Includes Non-Static Items?

Discussion in 'XR Interaction Toolkit and Input' started by Widanon, Nov 21, 2021.

  1. Widanon

    Widanon

    Joined:
    Jan 31, 2021
    Posts:
    36
    Hi

    I was baking my navmesh by just going to the Navigation tab and baking. This was working well - only objects I marked as navigation static were being included in the nav mesh.

    But I just changed to use two nav mesh surfaces so I could have seperate meshes for enemies and player. Now, whenever I bake, all items in the specified layers are included, even though they are not marked as navigation static.


    Am I missing something? Does nav mesh surface baking include all objects in the layers your specify regardless of whether you mark them navigation static?

    The documentation has no help, and I can't find anything on Google. Could anyone shed some light?....

    Thanks
     
    Last edited: Nov 22, 2021
    Liderangel likes this.
  2. Widanon

    Widanon

    Joined:
    Jan 31, 2021
    Posts:
    36
    So it turned out I was confused because it works differently for a navmesh surface. It will include everything, regardless of whether you mark it navigation static. You control what is included by specifying layers, and you can optionally include only items which are marked as static. However, this means ANY type of static, including batching, GI, occluder etc - not just navigation static.