Compare commits

..
2 changed files with 22 additions and 5 deletions

No files matched your search

@@ -713,6 +713,8 @@ public class LayoutManager implements IContainerInputHandler, IContainerTooltipH
@Override
public void load(GuiContainer gui) {
NEIController.load(gui);
if (isEnabled()) {
setInputFocused(null);
@@ -726,8 +728,6 @@ public class LayoutManager implements IContainerInputHandler, IContainerTooltipH
AutoFocusWidget.instance.load(gui);
}
NEIController.load(gui);
if (checkCreativeInv(gui) && gui.mc.currentScreen instanceof GuiContainerCreative) // override creative with
// creative+
gui.mc.displayGuiScreen(null); // close the screen and wait for the server to open it for us
@@ -10,6 +10,8 @@ import java.util.Map;
import net.minecraft.client.gui.GuiScreen;
import net.minecraft.client.gui.inventory.GuiContainer;
import net.minecraft.item.ItemStack;
import net.minecraftforge.fluids.FluidRegistry;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.oredict.OreDictionary;
import org.lwjgl.input.Mouse;
@@ -205,9 +207,24 @@ public abstract class ShortcutInputHandler {
private static boolean copyItemStackID(ItemStack stackover) {
if (stackover == null || stackover.getItem() == null) return false;
GuiScreen.setClipboardString(
stackover.getItem().delegate.name()
+ (stackover.getItemDamage() != 0 ? "/" + stackover.getItemDamage() : ""));
String clipboard;
if (StackInfo.isFluidDisplayItem(stackover)) {
final FluidStack fluid = StackInfo.getFluid(stackover);
if (fluid == null) {
return false;
}
clipboard = FluidRegistry.getDefaultFluidName(fluid.getFluid());
} else {
clipboard = stackover.getItem().delegate.name()
+ (stackover.getItemDamage() != 0 ? "/" + stackover.getItemDamage() : "");
}
GuiScreen.setClipboardString(clipboard);
return true;
}