Merge pull request #44726 from madmiraal/fix-44644

Ignore Bullet collision contact points with distance = 0
This commit is contained in:
Camille Mohr-Daurat 2021-11-18 11:16:15 -07:00 committed by GitHub
commit b7260e04cc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -835,7 +835,7 @@ void SpaceBullet::check_body_collision() {
btManifoldPoint &pt = contactManifold->getContactPoint(0);
#endif
if (
pt.getDistance() <= 0.0 ||
pt.getDistance() < 0.0 ||
bodyA->was_colliding(bodyB) ||
bodyB->was_colliding(bodyA)) {
Vector3 collisionWorldPosition;