Changes to Pathfinding

Version: 4.22

So I have started learning pathfinding in Godot, and one of the recent changes involves having an area be manually setup beforehand then deliberately baked. From what I have seen from tutorials this is a rather recent change.

This is rather confusing however as there are built in navigation layers in the tilemap that let you set tiles as being navigable. This seems immensely more preferable than manually setting up and moving the pathfinding and re-baking by hand every time.

Would it really have been harder to focus on the tiles themselves telling the AI what is or isnt path-able and even detect when a solid object is blocking access to a tiles route?

I am fairly new to Godot so maybe I am misunderstanding some things, I liked the simplistic idea of being able to paint a tile and that being all the instruction the game needed to say “AI can walk here”.

It is not so much about it being harder but that the TileMap build-in navigation has a lot of performance and quality problems that are all caused by the inflated cell count and inefficient cell layout of a TileMap.

Baking a TileMap with a NavigationRegion2D removes many of those TileMap issues. You can still use the TileMap to “design” your level, then disable the navigation layer of the TileMap, bake and use the NavigationRegion2D instead.

1 Like