From 44cb5c28b21b3ae01b9730b9a09a79e775ca2618 Mon Sep 17 00:00:00 2001 From: pbentes Date: Sun, 1 Sep 2024 23:18:05 +0100 Subject: [PATCH] Updated the way of fetching the height --- modules/actors/player/scripts/states/ducking.gd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/actors/player/scripts/states/ducking.gd b/modules/actors/player/scripts/states/ducking.gd index 67442e9..552e232 100644 --- a/modules/actors/player/scripts/states/ducking.gd +++ b/modules/actors/player/scripts/states/ducking.gd @@ -20,5 +20,5 @@ func physics_update(delta: float) -> void: player.locomotion.move_and_slide() player.locomotion.update_collider_height(delta) - if not (Input.is_action_pressed("duck") or player.locomotion.has_collision_above($".".settings.HEIGHT)): + if not (Input.is_action_pressed("duck") or player.locomotion.has_collision_above(player.state_machine.get_state("Running").settings.HEIGHT)): transition.emit("Running")