A* Pathfinding Project

Overlapping areas


I have a little island in my game and am trying to have animals walk in specific areas. Some may only roam the middle of the island, some may roam the north and some may even walk on the whole island. This is a little sketch to show the areas I am trying to create:

After setting everything up it looks like this:

Monsters in the lower right (green) area can only walk on those little edges of the map, while other monsters (middle, between red/yellow/cyan) can not walk at all. Is there any way for me to get this kind of pathfinding possible? Any help would be appreciated :slight_smile:



What you have to do is to divide your map into non-overlapping regions, and then on each unit you specify which of the regions it can traverse. You have to do it this way because a node can only have a single tag.


Thank you, will try to set everything up like that.