diff --git a/common/net/minecraftforge/common/ForgeDummyContainer.java b/common/net/minecraftforge/common/ForgeDummyContainer.java index 2815eeb8b..d62a69c24 100644 --- a/common/net/minecraftforge/common/ForgeDummyContainer.java +++ b/common/net/minecraftforge/common/ForgeDummyContainer.java @@ -41,7 +41,6 @@ import static net.minecraftforge.common.ForgeVersion.*; public class ForgeDummyContainer extends DummyModContainer implements WorldAccessContainer { public static int clumpingThreshold = 64; - public static boolean legacyFurnaceSides = false; public static boolean removeErroringEntities = false; public static boolean removeErroringTileEntities = false; public static boolean disableStitchedFileSaving = false; @@ -99,10 +98,6 @@ public class ForgeDummyContainer extends DummyModContainer implements WorldAcces prop.set(64); } - prop = config.get(Configuration.CATEGORY_GENERAL, "legacyFurnaceOutput", false); - prop.comment = "Controls the sides of vanilla furnaces for Forge's ISidedInventory, Vanilla defines the output as the bottom, but mods/Forge define it as the sides. Settings this to true will restore the old side relations."; - legacyFurnaceSides = prop.getBoolean(false); - prop = config.get(Configuration.CATEGORY_GENERAL, "removeErroringEntities", false); prop.comment = "Set this to just remove any TileEntity that throws a error in there update method instead of closing the server and reporting a crash log. BE WARNED THIS COULD SCREW UP EVERYTHING USE SPARINGLY WE ARE NOT RESPONSIBLE FOR DAMAGES."; removeErroringEntities = prop.getBoolean(false); diff --git a/common/net/minecraftforge/common/ISidedInventory.java b/common/net/minecraftforge/common/ISidedInventory.java deleted file mode 100644 index 028b09c2a..000000000 --- a/common/net/minecraftforge/common/ISidedInventory.java +++ /dev/null @@ -1,31 +0,0 @@ -/** - * This software is provided under the terms of the Minecraft Forge Public - * License v1.0. - */ - -package net.minecraftforge.common; - -import net.minecraft.inventory.IInventory; - -/** Inventory ranges mapped by side. This class is implemented by TileEntities - * that provide different inventory slot ranges to different sides. - */ -@Deprecated //A equivalent Interface is now in Minecraft Vanilla will be removed next major MC version -public interface ISidedInventory extends IInventory -{ - - /** - * Get the start of the side inventory. - * @param side The global side to get the start of range. - */ - @Deprecated - int getStartInventorySide(ForgeDirection side); - - /** - * Get the size of the side inventory. - * @param side The global side. - */ - @Deprecated - int getSizeInventorySide(ForgeDirection side); -} - diff --git a/patches/minecraft/net/minecraft/tileentity/TileEntityFurnace.java.patch b/patches/minecraft/net/minecraft/tileentity/TileEntityFurnace.java.patch index d4bccd0b1..4487d07f9 100644 --- a/patches/minecraft/net/minecraft/tileentity/TileEntityFurnace.java.patch +++ b/patches/minecraft/net/minecraft/tileentity/TileEntityFurnace.java.patch @@ -8,19 +8,15 @@ import net.minecraft.item.ItemHoe; import net.minecraft.item.ItemStack; import net.minecraft.item.ItemSword; -@@ -16,8 +17,10 @@ +@@ -16,6 +17,8 @@ import net.minecraft.item.crafting.FurnaceRecipes; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.nbt.NBTTagList; -- --public class TileEntityFurnace extends TileEntity implements ISidedInventory +import net.minecraftforge.common.ForgeDirection; +import net.minecraftforge.common.ForgeDummyContainer; -+ -+public class TileEntityFurnace extends TileEntity implements ISidedInventory, net.minecraftforge.common.ISidedInventory + + public class TileEntityFurnace extends TileEntity implements ISidedInventory { - private static final int[] slots_top = new int[] {0}; - private static final int[] slots_bottom = new int[] {2, 1}; @@ -279,8 +282,7 @@ if (this.furnaceItemStacks[1].stackSize == 0) @@ -75,54 +71,3 @@ { Block block = Block.blocksList[i]; -@@ -459,4 +465,50 @@ - { - return par3 != 0 || par1 != 1 || par2ItemStack.itemID == Item.bucketEmpty.itemID; - } -+ -+ /*********************************************************************************** -+ * This function is here for compatibilities sake, Modders should Check for -+ * Sided before ContainerWorldly, Vanilla Minecraft does not follow the sided standard -+ * that Modding has for a while. -+ * -+ * In vanilla: -+ * -+ * Top: Ores -+ * Sides: Fuel -+ * Bottom: Output -+ * -+ * Standard Modding: -+ * Top: Ores -+ * Sides: Output -+ * Bottom: Fuel -+ * -+ * The Modding one is designed after the GUI, the vanilla one is designed because its -+ * intended use is for the hopper, which logically would take things in from the top. -+ * -+ * This will possibly be removed in future updates, and make vanilla the definitive -+ * standard. -+ */ -+ -+ @Override -+ public int getStartInventorySide(ForgeDirection side) -+ { -+ if (ForgeDummyContainer.legacyFurnaceSides) -+ { -+ if (side == ForgeDirection.DOWN) return 1; -+ if (side == ForgeDirection.UP) return 0; -+ return 2; -+ } -+ else -+ { -+ if (side == ForgeDirection.DOWN) return 2; -+ if (side == ForgeDirection.UP) return 0; -+ return 1; -+ } -+ } -+ -+ @Override -+ public int getSizeInventorySide(ForgeDirection side) -+ { -+ return 1; -+ } - }