Non-physical collision problem



I’m making a tower defense demo,I encountered a collision problem. I did not use physical collision. I used mesh.intersectsMesh, which is not very accurate for the collision of circular objects.
The circular area is left in the picture3, but the collision continues

Do intersectsMesh and moveWithCollisions detect bound box?

You may try to increase the precision of the bounding box by setting the second parameter to true.

mesh.intersectsMesh(mesh2, true)

Docs - Mesh Intersections | Babylon.js Documentation

2 Likes

perfect solution

1 Like