Merge pull request #50905 from fabriceci/fix-multiple-direction-collision

Allow multiple collision direction at the same time
This commit is contained in:
Rémi Verschelde 2021-07-27 19:10:47 +02:00 committed by GitHub
commit 78f0d2d1d6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1187,9 +1187,6 @@ void CharacterBody2D::move_and_slide() {
}
void CharacterBody2D::_set_collision_direction(const PhysicsServer2D::MotionResult &p_result) {
on_floor = false;
on_ceiling = false;
on_wall = false;
if (up_direction == Vector2()) {
//all is a wall
on_wall = true;