Added a label for the effect timer

It looks a bit weird but I couldn't be bothered to fix it
This commit is contained in:
Puppet committed 2025-10-08 23:06:56 -07:00
1 parent ace7c8fb03
commit 213dd83e24
2 files changed
+32 -4

No files matched your search

+11
View File
@@ -5,8 +5,19 @@ public partial class ScoreText : Control {
public override void _Process(double delta) {
Label ScoreText = GetNode<Label>("ScoreLabel");
Label HighScoreText = GetNode<Label>("HighScoreLabel");
Label EffectTimerText = GetNode<Label>("EffectTimerLabel");
ScoreText.Text = "Score: " + Globals.Score;
HighScoreText.Text = "High Score: " + Globals.HighScore;
if (Globals.ActiveEffect == "none") {
EffectTimerText.Text = "";
} else {
string EffectTimerType = "";
if (Globals.ActiveEffect == "ultra") {
EffectTimerType = "Boost";
}
EffectTimerText.Text = EffectTimerType + " " + "expires in: " + Math.Floor(Globals.EffectTimer * 10) / 10 + "s";
}
}
}