brackeys-12/ui/counters.gd

12 lines
160 B
GDScript3
Raw Normal View History

2024-09-14 01:16:14 +00:00
extends Label
2024-09-14 01:31:14 +00:00
@export var key: String
2024-09-14 01:16:14 +00:00
2024-09-14 01:31:14 +00:00
func _ready() -> void:
Triggerer.listen(key, _on_value_change)
func _on_value_change(data):
2024-09-15 03:23:38 +00:00
text = str(data.value)