Some tweaks in the falling states

This commit is contained in:
2026-02-06 01:40:53 +03:00
parent c3522f5417
commit 230f39cf54
6 changed files with 48 additions and 9 deletions
@@ -1,12 +1,20 @@
extends CultistState
@export var fall_state: CultistState
func enter() -> void:
cultist.sprite.play(CultistSprite.LOOK_AROUND_ANIMATIONS.pick_random())
_set_ray_cast_enable(cultist.left_player_close_ray, true)
_set_ray_cast_enable(cultist.right_player_close_ray, true)
func physics_process(_delta: float) -> void:
if not cultist.is_on_floor():
switch_state.emit(fall_state)
func exit() -> void:
_set_ray_cast_enable(cultist.left_player_close_ray, false)
_set_ray_cast_enable(cultist.right_player_close_ray, false)