Cutting "holes" into a Navigation Mesh

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By CCX

Hi, I’m working on a project that has an in-game editor that places structures (walls etc).
I want it so that if I place down (for example) a wall, the navmesh will update and remove the part occupied by the wall.
Currently, I have a function that will calculate the vertices around the area that I want the navmesh to exclude out and append it to an new_navmesh_vertex_list array (An array containing the vertices of the original navmesh).
However, when I do:

var navmesh = $Navigation/NavigationMeshInstance.navmesh

// Calcuations

navmeshinstance.navmesh = navmesh

The navmesh looks unchanged. Then I used Immediate Geometry node to create some lines connecting the vertices in the navmesh to confirm that the navmesh does indeed have the new vertices.
Now my question is how does one remove part of a navmesh and update it correctly? Is there something I did wrong? Is there a specific order for the new_navmesh_vertex_list for the navmesh to remove the specified part?
Also I’m new here :slight_smile:

:bust_in_silhouette: Reply From: Favkis

You need to turn in off and on to make it see changes in navmesh lmao