diff options
Diffstat (limited to 'scripts/interface.gd')
-rw-r--r-- | scripts/interface.gd | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/scripts/interface.gd b/scripts/interface.gd index a242ae2..d61b8d5 100644 --- a/scripts/interface.gd +++ b/scripts/interface.gd @@ -2,6 +2,8 @@ extends CanvasLayer var time_left = 30 var phase_index = 0 +var phase_type = ["RANDOM", "INCREASED RANGE"] +var paused = false func _ready(): update_labels() @@ -17,7 +19,11 @@ func update_labels(): if phase_index < $"../Basketball".phase_increment.size() - 1: if $"../Basketball".phase_increment[phase_index] <= global_variables.score: phase_index += 1 - $PhaseLabel.text = "Next Phase: " + str($"../Basketball".phase_increment[phase_index] - global_variables.score) + $Difficulty/ChangeLabel.text = phase_type[$"../Basketball".phase - 1] + $Difficulty/AnimationPlayer.play("blinking") + var phase_difference = $"../Basketball".phase_increment[phase_index] - global_variables.score + if phase_difference >= 0: + $PhaseLabel.text = "Next Phase: " + str($"../Basketball".phase_increment[phase_index] - global_variables.score) func update_timer(): $TimerLabel.set_text("%03d" % time_left) @@ -29,4 +35,4 @@ func _on_Timer_timeout(): else: global_variables.timer_zero = true $Timer.stop() - $Control.visible = true + $LoseLabel.visible = true |