From eecd49ef02a7be178ddc35801e1d18469ed92841 Mon Sep 17 00:00:00 2001 From: nea Date: Sun, 8 Oct 2023 17:00:59 +0200 Subject: Fix auction house sort double rendering with chattriggers See: https://github.com/hannibal002/SkyHanni/pull/539 --- .../github/moulberry/notenoughupdates/mixins/MixinGuiContainer.java | 5 +++-- .../notenoughupdates/mixins/MixinThreadDownloadImageDataThread.java | 6 ++++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/main/java/io/github/moulberry/notenoughupdates/mixins/MixinGuiContainer.java b/src/main/java/io/github/moulberry/notenoughupdates/mixins/MixinGuiContainer.java index f9e0a132..49ef0390 100644 --- a/src/main/java/io/github/moulberry/notenoughupdates/mixins/MixinGuiContainer.java +++ b/src/main/java/io/github/moulberry/notenoughupdates/mixins/MixinGuiContainer.java @@ -184,8 +184,9 @@ public abstract class MixinGuiContainer extends GuiScreen { @Inject(method = "drawScreen", at = @At( value = "INVOKE", - target = "Lnet/minecraft/client/renderer/GlStateManager;popMatrix()V", - shift = At.Shift.AFTER + target = "Lnet/minecraft/entity/player/InventoryPlayer;getItemStack()Lnet/minecraft/item/ItemStack;", + shift = At.Shift.BEFORE, + ordinal = 1 ) ) public void drawScreen_after(int mouseX, int mouseY, float partialTicks, CallbackInfo ci) { diff --git a/src/main/java/io/github/moulberry/notenoughupdates/mixins/MixinThreadDownloadImageDataThread.java b/src/main/java/io/github/moulberry/notenoughupdates/mixins/MixinThreadDownloadImageDataThread.java index aea52378..ac8868e6 100644 --- a/src/main/java/io/github/moulberry/notenoughupdates/mixins/MixinThreadDownloadImageDataThread.java +++ b/src/main/java/io/github/moulberry/notenoughupdates/mixins/MixinThreadDownloadImageDataThread.java @@ -35,9 +35,11 @@ public class MixinThreadDownloadImageDataThread { method = "run", at = @At( value = "INVOKE", - target = "Ljava/net/HttpURLConnection;setDoOutput(Z)V" + target = "Ljava/net/HttpURLConnection;setDoOutput(Z)V", + remap = false ), - locals = LocalCapture.CAPTURE_FAILSOFT + locals = LocalCapture.CAPTURE_FAILSOFT, + remap = false ) public void patchHttpConnection(CallbackInfo ci, HttpURLConnection httpURLConnection) { ThreadDownloadImageHook.hookThreadImageConnection(httpURLConnection); -- cgit