1
Fork 0
mirror of https://github.com/Steffo99/swear-jar.git synced 2024-11-24 08:34:19 +00:00
swear-jar/game/action_timer.gd

13 lines
262 B
GDScript3
Raw Normal View History

extends Timer
class_name ActionTimer
## A timer which keeps repeating as long as an action is held.
## The name of the action to check.
@export var action: String
func _physics_process(_delta):
if is_stopped() and Input.is_action_pressed(action):
start()