Hello!
My current map includes a plane which is the main navigation surface. I also have road tiles which are meant to change that particular navmesh area to have a lower cost (it’s a road after all).
This works when I bake the mesh before pressing play. Road tiles turn the navmesh purple and my characters are able to navigate the map while preferring the road.
However, I am making a city-builder thus the player is the one in charge of building the roads.
How do I achieve this navmesh baking on runtime?
I’ve looked around and got very confused by different namespaces (UnityEditor.AI/UnityEngine.AI) comprising similar static methods which claim to rebuild the mesh on runtime. However, trying to call that function turns my whole mesh purple (road area).
Any help would be much appreciated!