fixed small issue

This commit is contained in:
RudideC
2026-02-19 13:33:54 +01:00
parent 38041b01cf
commit 052a2ac06c
@@ -32,10 +32,16 @@ public class Nametags extends Module {
if (state.customName == null) return null;
if (!healthDisplay.value) return state.customName.getString(); // name only
if (!(state instanceof HealthRenderState hrs)) return null;
float health = hrs.saturn$getHealth();
float maxHealth = hrs.saturn$getMaxHealth();
if (health <= 0f || maxHealth <= 0f || health > maxHealth) return null;
return state.customName.getString()
+ " §c" + String.format("%.1f", hrs.saturn$getHealth())
+ " / " + String.format("%.1f", hrs.saturn$getMaxHealth()) + " ❤";
}
public static boolean shouldReplaceName() {