Minor refactor in player code
This commit is contained in:
parent
d9dae634ef
commit
2a346363eb
1 changed files with 3 additions and 3 deletions
|
|
@ -83,14 +83,14 @@ func _physics_process(delta: float) -> void:
|
|||
manage_velocity(delta)
|
||||
move_and_slide()
|
||||
|
||||
func _process(delta: float) -> void:
|
||||
func _process(_delta: float) -> void:
|
||||
# All non-velocity management can run without FPS cap
|
||||
update_vine_statuses()
|
||||
manage_movement_options()
|
||||
manage_interaction()
|
||||
manage_animation()
|
||||
if handle_input:
|
||||
manage_active(delta)
|
||||
manage_active()
|
||||
manage_attack()
|
||||
|
||||
func manage_attack():
|
||||
|
|
@ -104,7 +104,7 @@ func manage_attack():
|
|||
$SwordSwingAudio.play()
|
||||
$AttackCooldown.start()
|
||||
|
||||
func manage_active(_delta : float):
|
||||
func manage_active():
|
||||
# Activate or remove items. Cooldown + use management is handled by the item.
|
||||
if(active_item != null and Input.is_action_just_pressed("item") and $ActiveItemCooldown.is_stopped()):
|
||||
active_item.trigger_activation()
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue