A plugin to automatically generate a nav mesh from a Phaser Tilemap.

Article by Richard Davey. Posted on 29th Sep 2017.   @phaser_


Pixelburp has released a new Phaser Plugin that will generate a nav mesh from a Tilemap: "This all started with a larger project I'm working on: it's going to (hopefully!) involve large tilemaps, a large number of sprites and procedural generation. A messy combination. As a result, I've been looking into ways I could perform pathfinding around Tilemaps in Phaser, and the most popular choice seems to be the grid-based a*star plugins; while in the main it probably does the job for smaller tilemaps, I don't think they scale very well.

One standard method of pathfinding used by other engines is something called Navigation (Nav) Meshes: basically, you calculate all the passable areas on your map and reduce it all to a small array of connected polygons, then figure out how to travel across those polygons"

There are videos, demos and the plugin is open source. So please give it a go and leave some feedback in the forum thread!

Read More