Saturday, November 16, 2013

Navigation Meshes



Nav Mesh
            Video games are generally funnier when entities have the ability to move around. I’m talking about entities that are NPCs or characters that the player does not have direct control of their movement. Getting back to my point games need some way of giving entities the ability to move around to achieve some goal. An example of a goal would be telling a friendly entity to go to a specific location. To achieve this some games are implementing a pathing technique that uses “Navigation Meshes” as the entities treasure map of where it’s allowed to traverse.

            Navigation Meshes are a 3d mesh that maps out the walkable areas within a game world. Generally the centers of the triangles in the navigation mesh act as wav points or the edges of the triangles. The act of finding the path to move along usually is done with A* which is a path finding algorithm. Together the Navigation mesh holds the valid paths or what triangles connect and A* finds the path to the goal then it’s up to the entity to walk the path given. Below is a little example of what a navigation mesh looks like.



No comments:

Post a Comment