Start with resources

This commit is contained in:
Ategon 2024-09-14 23:23:38 -04:00
parent ea2cf5787e
commit 6162455a71
2 changed files with 4 additions and 1 deletions

3
ui.gd
View file

@ -2,6 +2,9 @@ extends CanvasLayer
@onready var animation_player: AnimationPlayer = $AnimationPlayer @onready var animation_player: AnimationPlayer = $AnimationPlayer
func _ready() -> void:
Persister.persist_data("wood", 5)
Persister.persist_data("stone", 5)
func _process(delta: float) -> void: func _process(delta: float) -> void:
if Input.is_action_just_pressed("lclick") and not Persister.get_value("game_started"): if Input.is_action_just_pressed("lclick") and not Persister.get_value("game_started"):

View file

@ -8,4 +8,4 @@ func _ready() -> void:
func _on_value_change(data): func _on_value_change(data):
text = data.value text = str(data.value)