From c963229fdd9c426b70630ff970dd7b05c6b62100 Mon Sep 17 00:00:00 2001 From: Su5eD Date: Sat, 27 Apr 2024 22:04:23 +0200 Subject: [PATCH] Patch hud mixins to getSaturationLevel Fixes #1045 --- .../su5ed/sinytra/connector/transformer/MixinPatches.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/main/java/dev/su5ed/sinytra/connector/transformer/MixinPatches.java b/src/main/java/dev/su5ed/sinytra/connector/transformer/MixinPatches.java index ac66c57..9050026 100644 --- a/src/main/java/dev/su5ed/sinytra/connector/transformer/MixinPatches.java +++ b/src/main/java/dev/su5ed/sinytra/connector/transformer/MixinPatches.java @@ -303,6 +303,14 @@ public static List getPatches() { .modifyParams(b -> b.insert(0, Type.INT_TYPE).insert(1, Type.INT_TYPE).targetType(ParamTransformTarget.METHOD)) .modifyInjectionPoint("INVOKE", "Lcom/mojang/blaze3d/systems/RenderSystem;disableBlend()V") .build(), + Patch.builder() + .targetClass("net/minecraft/client/gui/Gui") + .targetMethod("m_280173_(Lnet/minecraft/client/gui/GuiGraphics;)V") + .targetInjectionPoint("Lnet/minecraft/world/food/FoodData;m_38722_()F") + .extractMixin("net/minecraftforge/client/gui/overlay/ForgeGui") + .modifyTarget("renderFood(IILnet/minecraft/client/gui/GuiGraphics;)V") + .modifyParams(b -> b.insert(0, Type.INT_TYPE).insert(1, Type.INT_TYPE).targetType(ParamTransformTarget.METHOD)) + .build(), Patch.builder() .targetClass("net/minecraft/client/gui/Gui") .targetMethod("m_280173_(Lnet/minecraft/client/gui/GuiGraphics;)V")