From 697d81d895eff10b408b621cefcd0842a537b208 Mon Sep 17 00:00:00 2001 From: AlgorithmX2 Date: Sat, 29 Mar 2014 22:19:15 -0500 Subject: [PATCH] Fixed Obfuscation Issue with Guis. --- client/gui/AEBaseGui.java | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/client/gui/AEBaseGui.java b/client/gui/AEBaseGui.java index 156a6de85..3778fa4ef 100644 --- a/client/gui/AEBaseGui.java +++ b/client/gui/AEBaseGui.java @@ -49,7 +49,7 @@ import appeng.core.sync.packets.PacketInventoryAction; import appeng.core.sync.packets.PacketSwapSlots; import appeng.helpers.InventoryAction; import appeng.util.Platform; -import cpw.mods.fml.relauncher.ReflectionHelper; +import cpw.mods.fml.common.ObfuscationReflectionHelper; public abstract class AEBaseGui extends GuiContainer { @@ -276,7 +276,16 @@ public abstract class AEBaseGui extends GuiContainer @Override protected boolean checkHotbarKeys(int p_146983_1_) { - Slot theSlot = ReflectionHelper.getPrivateValue( GuiContainer.class, this, "theSlot" ); + Slot theSlot; + + try + { + theSlot = ObfuscationReflectionHelper.getPrivateValue( GuiContainer.class, this, "theSlot", "field_147006_u", "f" ); + } + catch (Throwable t) + { + return false; + } if ( this.mc.thePlayer.inventory.getItemStack() == null && theSlot != null ) {