Fixed armor hud not updating after rejoining

This commit is contained in:
RaphiMC 2023-12-03 02:24:20 +01:00
parent e2a5c3396d
commit fb7a349bbf
No known key found for this signature in database
GPG Key ID: 0F6BB0657A03AC94

View File

@ -42,7 +42,7 @@ public class ArmorHudEmulation1_8 {
private static double oldArmor = 0;
public static void init() {
ClientTickEvents.START_WORLD_TICK.register(world -> {
ClientTickEvents.START_CLIENT_TICK.register(world -> {
if (!VisualSettings.global().emulateArmorHud.isEnabled()) {
return;
}
@ -56,6 +56,8 @@ public class ArmorHudEmulation1_8 {
ViaFabricPlus.global().getLogger().error("Error sending armor update", t);
}
}
} else {
oldArmor = 0;
}
});
}