TO SQUASH: Multiplier label.

This commit is contained in:
2026-08-26 22:53:17 -04:00
parent 37c802978b
commit afbef6c389
9 changed files with 314 additions and 22 deletions
+14
View File
@@ -1,5 +1,6 @@
using UnityEngine;
using UnityEngine.UI;
using UnityProgressBar;
public class UIManager : MonoBehaviour
{
@@ -25,6 +26,8 @@ public class UIManager : MonoBehaviour
public SpriteRenderer lastLifeLabel;
public ProgressBar progressBar;
private AudioSource audioSource;
private float warningTimer = 0f;
@@ -56,6 +59,17 @@ public class UIManager : MonoBehaviour
percentCoveredText.text = $"{Clamp(player.percentCovered, 0, 100)}";
lasersText.text = $"{Clamp(player.laserCount, 0, 99)}";
magnetsText.text = $"{Clamp(player.magnetCount, 0, 99)}";
progressBar.Value = player.speedBonus;
if (player.multiplier != 1)
{
int multiplierValue = player.multiplier == 0.5f ? 1 : (int)(player.multiplier);
multiplierText.text = $"{multiplierValue}";
}
else
{
multiplierText.text = "";
}
if (player.lives == 1)
{