18 lines
260 B
GDScript
18 lines
260 B
GDScript
extends Control
|
|
|
|
onready var label := $MarginContainer/Label
|
|
|
|
var game_mode
|
|
|
|
func update_score(score: int):
|
|
label.text = String(score)
|
|
|
|
|
|
func start(initial_score: int):
|
|
update_score(initial_score)
|
|
show()
|
|
|
|
|
|
func init(mode: String):
|
|
game_mode = mode
|
|
hide()
|