Working with Unity Navmesh System for Smart AI

Before getting to the actual moving, we need to bake the area the character will be moving around in. In our case, we have a floor collider to select, then go into Navigation, and select bake.

We need to make sure the objects are set to static as well

We can actually include them in the baking by changing them to ‘static’ and then rebaking the navmesh.

Your player now picks the best path to where you’re pointing as well as avoids whatever cabinet or element that’s in the way to the point clicked



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store