Update character.gd for base_speed fix

base_speed is assigned to speed before the default is updated to what is set in the export variable causing it to be the incorrect value. Calling enter_normal_state() on ready sets speed to the correct value before the player gains control. From my testing, this has no side effects.
This commit is contained in:
Austin Dennis
2024-09-21 17:31:43 -04:00
committed by GitHub
parent b57da3669c
commit b59bbb3673

View File

@ -117,6 +117,7 @@ func _ready():
CROUCH_ANIMATION.play("RESET") CROUCH_ANIMATION.play("RESET")
check_controls() check_controls()
enter_normal_state()
func check_controls(): # If you add a control, you might want to add a check for it here. func check_controls(): # If you add a control, you might want to add a check for it here.
# The actions are being disabled so the engine doesn't halt the entire project in debug mode # The actions are being disabled so the engine doesn't halt the entire project in debug mode