Grid density recommendation

My game is viewed from the top down and the player moves from room to room (much like binding of issac). Right now I have a grid of 68x38 nodes for each room and a node size of 0.5. You can see the density in the screenshot. The highlighted entity is one of the bigger enemies in the game. But I’ve chosen this density of grid completely arbitrarily.

My question is what sort of grid density would you recommend? Is there any documentation that gives guidance on this subject? I’m guessing that if I go higher density, then I would get some more consistency in how close an enemy gets to a wall, but I assume there is some impact on performance. Is there any kind of guidance on max limit for number of nodes before performance starts to be become an issue (the min spec target platform is Nintendo Switch)?


Yeah, a higher grid density will give you a higher resolution and therefore make things a bit more consistent if your game is not already tied to a grid.

There is an impact on performance and memory usage, but games can easily have 100x100, 200x200 graphs, and can go up to 500x500 or even 1000x1000 in some cases (though that uses a lot of memory, and I would recommend a recast graph instead of going that high).

For your use case, 100x100 or 200x200 should be totally fine, I think.

Brilliant, thanks for the info, super helpful!