diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2019-02-18 15:24:09 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-02-18 15:24:09 +0100 |
commit | 049bb75f9e9472fc5a46424412bc193e689ddf63 (patch) | |
tree | 7a23e4ece5babb29bedb6ed91594a2e1fa5c1dcd | |
parent | 7c8fbd892c827abae464fad2c427ca2bd17ff3f8 (diff) | |
parent | 66420aea9cd6bd4ea393594551c543e688e27673 (diff) |
Merge pull request #26014 from AndreaCatania/bugfix
Fixed area collision report with concave
-rw-r--r-- | modules/bullet/space_bullet.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/modules/bullet/space_bullet.cpp b/modules/bullet/space_bullet.cpp index f657a5e4fd..c93220fc17 100644 --- a/modules/bullet/space_bullet.cpp +++ b/modules/bullet/space_bullet.cpp @@ -686,7 +686,7 @@ void SpaceBullet::check_ghost_overlaps() { btVector3 other_body_scale(otherObject->get_bt_body_scale()); if (!area->is_transform_changed() && !otherObject->is_transform_changed()) { - hasOverlap = true; + hasOverlap = -1 != area->find_overlapping_object(otherObject); goto collision_found; } @@ -715,6 +715,9 @@ void SpaceBullet::check_ghost_overlaps() { other_body_shape = static_cast<btCollisionShape *>(otherObject->get_bt_shape(z)); + if (other_body_shape->isConcave()) + continue; + btTransform other_shape_transform(otherObject->get_bt_shape_transform(z)); other_shape_transform.getOrigin() *= other_body_scale; |