FPS Controller
This commit is contained in:
10
demo/assets/scripts/player/states/walking_state.gd
Normal file
10
demo/assets/scripts/player/states/walking_state.gd
Normal file
@@ -0,0 +1,10 @@
|
||||
extends PlayerState
|
||||
|
||||
|
||||
func _on_walking_state_processing(delta: float) -> void:
|
||||
if Input.is_action_pressed("sprint"):
|
||||
player_controller.state_chart.send_event("onSprinting")
|
||||
|
||||
|
||||
func _on_walking_state_entered() -> void:
|
||||
player_controller.walk()
|
||||
Reference in New Issue
Block a user