summaryrefslogtreecommitdiff
path: root/hud.gd
blob: 72d5b965614e27d2d001ca918ac5b9fde93911ba (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
extends CanvasLayer


func _ready() -> void:
	%Score.text = str(Game.score)
	
	Game.score_changed.connect(func():
		%Score.text = str(Game.score)
	)
	
	Game.boss_initialized.connect(func(hp):
		%BossHPBar.visible = true
		%BossHPBar.initialize(hp)
		
		$PanelContainer/VBoxContainer/Top/Left/Score.visible = false
		$PanelContainer/VBoxContainer/Top/Left/Boss.visible = true
	)