If your scene is a 2D environment primarily composed of SpriteRenderers and viewed from a GodView (top-down perspective), and you want to avoid using traditional grid A* (which can result in a grid-like path), then SpriteRendererNAV is an excellent solution.
SpriteRendererNAV is an asset designed to create a NAVMesh for SpriteRenderers. It is characterized by its simplicity and ease of use, providing several related pathfinding examples, including Find and NAVMeshObstacle (dynamic obstacles). Simply place the relevant SpriteRenderers, set the X angle of the Transform’s Rotation to 90 degrees, and create a SpriteRendererNAVScene to generate your NAVMesh.
Feature List
-
Provides a Rebuild button to easily rebuild the NAVMesh.Simple and easy to use.
-
Just add the relevant PolygonCollider2D, no other mesh data is needed.No additional mesh data required.
-
Adjust the AgentRadius to set the edge width of the NAVMesh.NAVMesh edge width setting.
-
Provides a toggle to display Block lines generated during the creation process, making it easier to debug.Debug display.
-
Includes examples of pathfinding and dynamic obstacles (NAVMeshObstacle) usage.Pathfinding examples.