test_game/scripts/game_manager.gd
2025-03-03 02:21:17 +01:00

12 lines
224 B
GDScript

extends Node
@onready var score_label: Label = $ScoreLabel
@onready var ui: UI = %UI
var score: int = 0
func add_score_point():
score += 1
score_label.text = "You collected " + str(score) + " coins."
ui.coins = score