montzions ui pausenmenü ui lebns ui nachladen pausen menü neues digsein

This commit is contained in:
NBTEMP\bib
2026-07-16 15:09:38 +02:00
parent c320f54ec9
commit 7cc9554e6a
343 changed files with 106043 additions and 50 deletions
+21
View File
@@ -0,0 +1,21 @@
using UnityEngine;
using TMPro; // WICHTIG: Erforderlich für TextMeshPro!
public class AmmoUI : MonoBehaviour
{
[Header("Referenzen")]
[Tooltip("Ziehe hier dein TextMeshPro Text-Objekt rein")]
public TextMeshProUGUI ammoText;
[Tooltip("Ziehe hier das Objekt mit deinem WeaponReload-Skript rein")]
public WeaponReload weapon;
void Update()
{
if (ammoText != null && weapon != null)
{
// Zeigt z. B. "30 / 30" im Textfeld an
ammoText.text = weapon.currentAmmo + " / " + weapon.maxAmmo;
}
}
}