- Move elevator panel logic out of HUD; HUD now listens for signals to update floor, saved, people, and score labels - Add scaling rescue threshold that grows as you descend, with bonus points for exceeding it - Add per-floor timer that triggers a losing when expired - Add show_loss state on the screen for too-few-people and timeout failures
19 lines
623 B
GDScript
19 lines
623 B
GDScript
extends MarginContainer
|
|
|
|
func _ready():
|
|
$StatsColumn/FloorLabel.text = "FLOOR: 10"
|
|
$StatsColumn/SavedLabel.text = "SAVED: 0"
|
|
$StatsColumn/PeopleLabel.text = "PEOPLE: 0/2"
|
|
$StatsColumn/ScoreLabel.text = "SCORE: 0"
|
|
|
|
func update_floor(floor_num: int):
|
|
$StatsColumn/FloorLabel.text = "FLOOR: " + str(floor_num)
|
|
|
|
func update_saved(count: int):
|
|
$StatsColumn/SavedLabel.text = "SAVED: " + str(count)
|
|
|
|
func update_people(count: int, threshold: int):
|
|
$StatsColumn/PeopleLabel.text = "PEOPLE: " + str(count) + "/" + str(threshold)
|
|
|
|
func update_score(new_score: int):
|
|
$StatsColumn/ScoreLabel.text = "SCORE: " + str(new_score)
|