diff --git a/src/main/java/mcp/mobius/waila/addons/core/HUDHandlerEntities.java b/src/main/java/mcp/mobius/waila/addons/core/HUDHandlerEntities.java index 6ff811415..a5424a1aa 100644 --- a/src/main/java/mcp/mobius/waila/addons/core/HUDHandlerEntities.java +++ b/src/main/java/mcp/mobius/waila/addons/core/HUDHandlerEntities.java @@ -34,15 +34,15 @@ public void appendHead(List tooltip, IEntityAccessor accessor, IPluginConf public void appendBody(List tooltip, IEntityAccessor accessor, IPluginConfig config) { if (config.get(PluginCore.CONFIG_SHOW_ENTITY_HEALTH) && accessor.getEntity() instanceof LivingEntity) { LivingEntity living = (LivingEntity) accessor.getEntity(); - float health = living.getHealth() / 2.0F; - float maxHealth = living.getMaxHealth() / 2.0F; + float health = living.getHealth(); + float maxHealth = living.getMaxHealth(); if (living.getMaxHealth() > Waila.CONFIG.get().getGeneral().getMaxHealthForRender()) tooltip.add(new TranslatableText("tooltip.waila.health", String.format("%.2f", health), String.format("%.2f", maxHealth))); else { CompoundTag healthData = new CompoundTag(); - healthData.putFloat("health", health); - healthData.putFloat("max", maxHealth); + healthData.putFloat("health", health / 2.0F); + healthData.putFloat("max", maxHealth / 2.0F); tooltip.add(new RenderableTextComponent(PluginCore.RENDER_ENTITY_HEALTH, healthData)); } }