findEntities() find objects outside search sphere


Testing the findEntities() function. it works. But after some puzzle. I come to the conclusion that findEntities() is finding more then you expect. some entities are outside the search area. 0.5 meters. Also 0.0 meters still did show more then expected.

The objects it also find are the skybox, and my test terrain that is 1023x153,1023 meters in size. Not a big pain , because you add some filter. But it still outside the radius sphere.

New findEntitiesExample

This is due to the fact that findEntities will return all the entities that “touch” the sphere, not only the one fully contained.


And this is good! Necessary for many pathfinding, collision avoidance scenarios.


Good to know, but good to have in documentation too ! if it’s not already there.