Remove needless check in motion test

Since now one-way collision is at shapes, the removed if was unneeded.
This commit is contained in:
Pedro J. Estébanez 2017-08-16 12:36:26 +02:00
parent 603b262d9b
commit e1bdf81008

View File

@ -678,9 +678,6 @@ bool Space2DSW::test_body_motion(Body2DSW *p_body, const Transform2D &p_from, co
}
}
if (col_obj->get_type() == CollisionObject2DSW::TYPE_BODY) {
const Body2DSW *body = static_cast<const Body2DSW *>(col_obj);
if (col_obj->is_shape_set_as_one_way_collision(j)) {
Vector2 cd[2];
@ -698,7 +695,6 @@ bool Space2DSW::test_body_motion(Body2DSW *p_body, const Transform2D &p_from, co
continue;
}
}
}
if (low < best_safe) {
best_safe = low;