diff --git a/princesse.gd b/princesse.gd index 5ae324d..1c83a4e 100644 --- a/princesse.gd +++ b/princesse.gd @@ -461,7 +461,6 @@ func read_input() -> void: (pressing_wall_right and direction == 1) ) ) - else: grab_wall = false @@ -526,12 +525,16 @@ func compute_state() -> void: coyote_grab.remove_at(0) # gestion de l'état de la pression au mur - pressing_wall_left = (not is_on_floor() and not collide_ground_far_detect) and ( + pressing_wall_left = ( + not is_on_floor() and not collide_ground_far_detect and not is_on_ceiling_only() + ) and ( wall_detect_left.is_colliding() or wall_detect_left2.is_colliding() or wall_detect_left3.is_colliding() ) - pressing_wall_right = (not is_on_floor() and not collide_ground_far_detect) and ( + pressing_wall_right = ( + not is_on_floor() and not collide_ground_far_detect and not is_on_ceiling_only() + ) and ( wall_detect_right.is_colliding() or wall_detect_right2.is_colliding() or wall_detect_right3.is_colliding()