diff options
author | Marcel Admiraal <madmiraal@users.noreply.github.com> | 2020-10-08 12:45:03 +0100 |
---|---|---|
committer | Marcel Admiraal <madmiraal@users.noreply.github.com> | 2021-07-19 17:03:43 +0100 |
commit | b8fe5763551c897c5ecd3e4210bfcd2eea64c93a (patch) | |
tree | 96123b332f9aa192766c16fd71ee87d8137ababe /servers/physics_2d/body_pair_2d_sw.cpp | |
parent | dfc1ec7fb97f38c5e785433cb0fb497dfa8c7e36 (diff) |
Ensure KinematicBodies only interact with other Bodies with matching mask.
Diffstat (limited to 'servers/physics_2d/body_pair_2d_sw.cpp')
-rw-r--r-- | servers/physics_2d/body_pair_2d_sw.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/servers/physics_2d/body_pair_2d_sw.cpp b/servers/physics_2d/body_pair_2d_sw.cpp index e5eb374fa3..71d985a6c5 100644 --- a/servers/physics_2d/body_pair_2d_sw.cpp +++ b/servers/physics_2d/body_pair_2d_sw.cpp @@ -229,7 +229,7 @@ bool BodyPair2DSW::setup(real_t p_step) { dynamic_A = (A->get_mode() > PhysicsServer2D::BODY_MODE_KINEMATIC); dynamic_B = (B->get_mode() > PhysicsServer2D::BODY_MODE_KINEMATIC); - if (!A->test_collision_mask(B) || A->has_exception(B->get_self()) || B->has_exception(A->get_self())) { + if (!A->interacts_with(B) || A->has_exception(B->get_self()) || B->has_exception(A->get_self())) { collided = false; return false; } |