From 311ab89f93558233a40079f7cb16605b141b5346 Mon Sep 17 00:00:00 2001 From: Johann Bernhardt Date: Sun, 12 Dec 2021 19:38:06 +0100 Subject: Move sources and resources --- .../gregtech/api/gui/CONTAINER_AdvancedBoiler.java | 93 ------- .../xmod/gregtech/api/gui/CONTAINER_Cyclotron.java | 37 --- .../gregtech/api/gui/CONTAINER_DeluxeTank.java | 80 ------ .../api/gui/CONTAINER_Hatch_Muffler_Advanced.java | 51 ---- .../api/gui/CONTAINER_IndustrialCentrifuge.java | 39 --- .../api/gui/CONTAINER_IronBlastFurnace.java | 32 --- .../xmod/gregtech/api/gui/CONTAINER_MatterFab.java | 42 --- .../api/gui/CONTAINER_MetaTileMachineLong.java | 244 ----------------- .../gregtech/api/gui/CONTAINER_MultiMachine.java | 283 -------------------- .../CONTAINER_MultiMachine_NoPlayerInventory.java | 27 -- .../api/gui/CONTAINER_PowerSubStation.java | 41 --- .../xmod/gregtech/api/gui/CONTAINER_SafeBlock.java | 124 --------- .../gregtech/api/gui/CONTAINER_SolarGenerator.java | 85 ------ .../gregtech/api/gui/CONTAINER_SteamCondenser.java | 99 ------- .../gregtech/api/gui/CONTAINER_SuperChest.java | 78 ------ .../gregtech/api/gui/CONTAINER_TreeFarmer.java | 71 ----- .../xmod/gregtech/api/gui/GUI_AdvancedBoiler.java | 44 --- .../xmod/gregtech/api/gui/GUI_Cyclotron.java | 44 --- .../xmod/gregtech/api/gui/GUI_DeluxeTank.java | 37 --- .../api/gui/GUI_Hatch_Muffler_Advanced.java | 46 ---- .../gregtech/api/gui/GUI_IndustrialCentrifuge.java | 73 ----- .../gregtech/api/gui/GUI_IronBlastFurnace.java | 32 --- .../xmod/gregtech/api/gui/GUI_MatterFab.java | 81 ------ .../xmod/gregtech/api/gui/GUI_MultiMachine.java | 296 --------------------- .../gregtech/api/gui/GUI_MultiMachine_Default.java | 68 ----- .../gregtech/api/gui/GUI_Multi_Basic_Slotted.java | 88 ------ .../xmod/gregtech/api/gui/GUI_PowerSubStation.java | 175 ------------ .../xmod/gregtech/api/gui/GUI_SafeBlock.java | 51 ---- .../xmod/gregtech/api/gui/GUI_SolarGenerator.java | 44 --- .../xmod/gregtech/api/gui/GUI_SteamCondenser.java | 56 ---- .../xmod/gregtech/api/gui/GUI_SuperChest.java | 38 --- .../xmod/gregtech/api/gui/GUI_TreeFarmer.java | 46 ---- .../api/gui/basic/CONTAINER_PollutionCleaner.java | 105 -------- .../api/gui/basic/GUI_PollutionCleaner.java | 65 ----- .../gui/fluidreactor/Container_FluidReactor.java | 184 ------------- .../api/gui/fluidreactor/GUI_FluidReactor.java | 122 --------- .../api/gui/hatches/CONTAINER_1by1_Turbine.java | 60 ----- .../gregtech/api/gui/hatches/CONTAINER_2by2.java | 32 --- .../gregtech/api/gui/hatches/CONTAINER_4by4.java | 44 --- .../gui/hatches/CONTAINER_HatchNbtConsumable.java | 282 -------------------- .../gregtech/api/gui/hatches/GUI_1by1_Turbine.java | 36 --- .../xmod/gregtech/api/gui/hatches/GUI_2by2.java | 36 --- .../xmod/gregtech/api/gui/hatches/GUI_4by4.java | 36 --- .../api/gui/hatches/GUI_HatchNbtConsumable.java | 59 ---- .../hatches/charge/CONTAINER_Electric_2by2.java | 24 -- .../hatches/charge/CONTAINER_Electric_4by4.java | 37 --- .../api/gui/hatches/charge/GUI_Electric_2by2.java | 21 -- .../api/gui/hatches/charge/GUI_Electric_4by4.java | 22 -- .../api/gui/power/CONTAINER_BasicTank.java | 69 ----- .../xmod/gregtech/api/gui/power/GUI_BasicTank.java | 36 --- 50 files changed, 3915 deletions(-) delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_AdvancedBoiler.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_Cyclotron.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_DeluxeTank.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_Hatch_Muffler_Advanced.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_IndustrialCentrifuge.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_IronBlastFurnace.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MatterFab.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MetaTileMachineLong.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MultiMachine.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MultiMachine_NoPlayerInventory.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_PowerSubStation.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SafeBlock.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SolarGenerator.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SteamCondenser.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SuperChest.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_TreeFarmer.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_AdvancedBoiler.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_Cyclotron.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_DeluxeTank.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_Hatch_Muffler_Advanced.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_IndustrialCentrifuge.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_IronBlastFurnace.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_MatterFab.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_MultiMachine.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_MultiMachine_Default.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_Multi_Basic_Slotted.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_PowerSubStation.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_SafeBlock.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_SolarGenerator.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_SteamCondenser.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_SuperChest.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_TreeFarmer.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/basic/CONTAINER_PollutionCleaner.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/basic/GUI_PollutionCleaner.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/fluidreactor/Container_FluidReactor.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/fluidreactor/GUI_FluidReactor.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/hatches/CONTAINER_1by1_Turbine.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/hatches/CONTAINER_2by2.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/hatches/CONTAINER_4by4.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/hatches/CONTAINER_HatchNbtConsumable.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/hatches/GUI_1by1_Turbine.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/hatches/GUI_2by2.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/hatches/GUI_4by4.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/hatches/GUI_HatchNbtConsumable.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/hatches/charge/CONTAINER_Electric_2by2.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/hatches/charge/CONTAINER_Electric_4by4.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/hatches/charge/GUI_Electric_2by2.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/hatches/charge/GUI_Electric_4by4.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/power/CONTAINER_BasicTank.java delete mode 100644 src/Java/gtPlusPlus/xmod/gregtech/api/gui/power/GUI_BasicTank.java (limited to 'src/Java/gtPlusPlus/xmod/gregtech/api/gui') diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_AdvancedBoiler.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_AdvancedBoiler.java deleted file mode 100644 index 04d8d91201..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_AdvancedBoiler.java +++ /dev/null @@ -1,93 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import java.util.Iterator; - -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -import net.minecraft.entity.player.InventoryPlayer; -import net.minecraft.inventory.ICrafting; -import net.minecraft.inventory.Slot; - -import gregtech.api.gui.GT_ContainerMetaTile_Machine; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; - -import gtPlusPlus.xmod.gregtech.common.tileentities.generators.GT_MetaTileEntity_Boiler_Base; - -public class CONTAINER_AdvancedBoiler - extends GT_ContainerMetaTile_Machine { - public int mWaterAmount = 0; - public int mSteamAmount = 0; - public int mProcessingEnergy = 0; - public int mTemperature = 2; - - public CONTAINER_AdvancedBoiler(InventoryPlayer aInventoryPlayer, IGregTechTileEntity aTileEntity) { - super(aInventoryPlayer, aTileEntity); - } - - @Override - public void addSlots(InventoryPlayer aInventoryPlayer) { - addSlotToContainer(new Slot(this.mTileEntity, 2, 116, 62)); - addSlotToContainer(new Slot(this.mTileEntity, 0, 44, 26)); - addSlotToContainer(new Slot(this.mTileEntity, 1, 44, 62)); - addSlotToContainer(new Slot(this.mTileEntity, 3, 116, 26)); - } - - @Override - public int getSlotCount() { - return 4; - } - - @Override - public int getShiftClickSlotCount() { - return 1; - } - - @Override - public void detectAndSendChanges() { - super.detectAndSendChanges(); - if ((this.mTileEntity.isClientSide()) || (this.mTileEntity.getMetaTileEntity() == null)) { - return; - } - - int steamCapacity = ((GT_MetaTileEntity_Boiler_Base) this.mTileEntity.getMetaTileEntity()).getSteamCapacity(); - int waterCapacity = ((GT_MetaTileEntity_Boiler_Base) this.mTileEntity.getMetaTileEntity()).getCapacity(); - this.mTemperature = ((GT_MetaTileEntity_Boiler_Base) this.mTileEntity.getMetaTileEntity()).mTemperature; - this.mProcessingEnergy = ((GT_MetaTileEntity_Boiler_Base) this.mTileEntity.getMetaTileEntity()).mProcessingEnergy; - this.mSteamAmount = (((GT_MetaTileEntity_Boiler_Base) this.mTileEntity.getMetaTileEntity()).mSteam == null ? 0 : ((GT_MetaTileEntity_Boiler_Base) this.mTileEntity.getMetaTileEntity()).mSteam.amount); - this.mWaterAmount = (((GT_MetaTileEntity_Boiler_Base) this.mTileEntity.getMetaTileEntity()).mFluid == null ? 0 : ((GT_MetaTileEntity_Boiler_Base) this.mTileEntity.getMetaTileEntity()).mFluid.amount); - - this.mTemperature = Math.min(54, Math.max(0, this.mTemperature * 54 / (((GT_MetaTileEntity_Boiler_Base) this.mTileEntity.getMetaTileEntity()).maxProgresstime() - 10))); - this.mSteamAmount = Math.min(54, Math.max(0, this.mSteamAmount * 54 / (steamCapacity - 100))); - this.mWaterAmount = Math.min(54, Math.max(0, this.mWaterAmount * 54 / (waterCapacity - 100))); - this.mProcessingEnergy = Math.min(14, Math.max(this.mProcessingEnergy > 0 ? 1 : 0, this.mProcessingEnergy * 14 / 1000)); - - Iterator var2 = this.crafters.iterator(); - while (var2.hasNext()) { - ICrafting var1 = (ICrafting) var2.next(); - var1.sendProgressBarUpdate(this, 100, this.mTemperature); - var1.sendProgressBarUpdate(this, 101, this.mProcessingEnergy); - var1.sendProgressBarUpdate(this, 102, this.mSteamAmount); - var1.sendProgressBarUpdate(this, 103, this.mWaterAmount); - } - } - - @Override - @SideOnly(Side.CLIENT) - public void updateProgressBar(int par1, int par2) { - super.updateProgressBar(par1, par2); - switch (par1) { - case 100: - this.mTemperature = par2; - break; - case 101: - this.mProcessingEnergy = par2; - break; - case 102: - this.mSteamAmount = par2; - break; - case 103: - this.mWaterAmount = par2; - } - } -} diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_Cyclotron.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_Cyclotron.java deleted file mode 100644 index 6d0eb6b14c..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_Cyclotron.java +++ /dev/null @@ -1,37 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import gregtech.api.gui.GT_ContainerMetaTile_Machine; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; -import net.minecraft.entity.player.InventoryPlayer; - -/** - * NEVER INCLUDE THIS FILE IN YOUR MOD!!! - *

- * The Container I use for all my Basic Machines - */ -public class CONTAINER_Cyclotron extends GT_ContainerMetaTile_Machine { - - public CONTAINER_Cyclotron(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity) { - - super(aInventoryPlayer, aTileEntity); - } - - public CONTAINER_Cyclotron(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity, final boolean bindInventory) { - super(aInventoryPlayer, aTileEntity, bindInventory); - } - - @Override - public void addSlots(final InventoryPlayer aInventoryPlayer) { - //this.addSlotToContainer(new Slot(this.mTileEntity, 1, 154, 42)); - } - - @Override - public int getSlotCount() { - return 0; - } - - @Override - public int getShiftClickSlotCount() { - return 0; - } -} diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_DeluxeTank.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_DeluxeTank.java deleted file mode 100644 index a4508781aa..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_DeluxeTank.java +++ /dev/null @@ -1,80 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import java.util.Iterator; - -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -import net.minecraft.entity.player.InventoryPlayer; -import net.minecraft.inventory.ICrafting; -import net.minecraft.inventory.Slot; - -import gregtech.api.gui.GT_Container_BasicTank; -import gregtech.api.gui.GT_Slot_Output; -import gregtech.api.gui.GT_Slot_Render; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; - -import gtPlusPlus.xmod.gregtech.api.metatileentity.implementations.GT_MetaTileEntity_DeluxeTank; - -/** - * NEVER INCLUDE THIS FILE IN YOUR MOD!!! - *

- * The Container I use for all my Basic Tanks - */ -public class CONTAINER_DeluxeTank extends GT_Container_BasicTank { - - public CONTAINER_DeluxeTank(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity) { - super(aInventoryPlayer, aTileEntity); - } - - @Override - public void addSlots(final InventoryPlayer aInventoryPlayer) { - this.addSlotToContainer(new Slot(this.mTileEntity, 0, 80, 17)); - this.addSlotToContainer(new GT_Slot_Output(this.mTileEntity, 1, 80, 53)); - this.addSlotToContainer(new GT_Slot_Render(this.mTileEntity, 2, 41, 42)); - this.addSlotToContainer(new GT_Slot_Render(this.mTileEntity, 3, 59, 42)); - } - - @Override - public void detectAndSendChanges() { - super.detectAndSendChanges(); - if (this.mTileEntity.isClientSide() || (this.mTileEntity.getMetaTileEntity() == null)) { - return; - } - if (((GT_MetaTileEntity_DeluxeTank) this.mTileEntity.getMetaTileEntity()).mFluid != null) { - this.mContent = ((GT_MetaTileEntity_DeluxeTank) this.mTileEntity.getMetaTileEntity()).mFluid.amount; - } else { - this.mContent = 0; - } - final Iterator var2 = this.crafters.iterator(); - while (var2.hasNext()) { - final ICrafting var1 = (ICrafting) var2.next(); - var1.sendProgressBarUpdate(this, 100, this.mContent & 65535); - var1.sendProgressBarUpdate(this, 101, this.mContent >>> 16); - } - } - - @Override - @SideOnly(Side.CLIENT) - public void updateProgressBar(final int par1, final int par2) { - super.updateProgressBar(par1, par2); - switch (par1) { - case 100: - this.mContent = (this.mContent & -65536) | par2; - break; - case 101: - this.mContent = (this.mContent & 65535) | (par2 << 16); - break; - } - } - - @Override - public int getSlotCount() { - return 2; - } - - @Override - public int getShiftClickSlotCount() { - return 1; - } -} diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_Hatch_Muffler_Advanced.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_Hatch_Muffler_Advanced.java deleted file mode 100644 index 17226a399e..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_Hatch_Muffler_Advanced.java +++ /dev/null @@ -1,51 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import gregtech.api.gui.GT_ContainerMetaTile_Machine; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; -import gtPlusPlus.core.slots.SlotAirFilter; -import net.minecraft.entity.player.InventoryPlayer; - - -public class CONTAINER_Hatch_Muffler_Advanced extends GT_ContainerMetaTile_Machine { - - public long maxEU = 0; - public long storedEU = 0; - - public CONTAINER_Hatch_Muffler_Advanced(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity) { - super(aInventoryPlayer, aTileEntity); - } - - public CONTAINER_Hatch_Muffler_Advanced(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity, final boolean bindInventory) { - super(aInventoryPlayer, aTileEntity, bindInventory); - } - - @Override - public void addSlots(final InventoryPlayer aInventoryPlayer) { - this.addSlotToContainer(new SlotAirFilter(this.mTileEntity, 0, 80, 35)); - } - - @Override - public int getSlotCount() { - return 1; - } - - @Override - public int getShiftClickSlotCount() { - return 1; - } - - @Override - public void updateProgressBar(final int id, final int value) { - super.updateProgressBar(id, value); - switch (id) { - default: - break; - } - } - - @Override - public void detectAndSendChanges() { - super.detectAndSendChanges(); - } - -} \ No newline at end of file diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_IndustrialCentrifuge.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_IndustrialCentrifuge.java deleted file mode 100644 index df8df2f775..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_IndustrialCentrifuge.java +++ /dev/null @@ -1,39 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import net.minecraft.entity.player.InventoryPlayer; -import net.minecraft.inventory.Slot; - -import gregtech.api.gui.GT_ContainerMetaTile_Machine; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; - -/** - * NEVER INCLUDE THIS FILE IN YOUR MOD!!! - *

- * The Container I use for all my Basic Machines - */ -public class CONTAINER_IndustrialCentrifuge extends GT_ContainerMetaTile_Machine { - - public CONTAINER_IndustrialCentrifuge(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity) { - - super(aInventoryPlayer, aTileEntity); - } - - public CONTAINER_IndustrialCentrifuge(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity, final boolean bindInventory) { - super(aInventoryPlayer, aTileEntity, bindInventory); - } - - @Override - public void addSlots(final InventoryPlayer aInventoryPlayer) { - this.addSlotToContainer(new Slot(this.mTileEntity, 1, 154, 42)); - } - - @Override - public int getSlotCount() { - return 1; - } - - @Override - public int getShiftClickSlotCount() { - return 1; - } -} diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_IronBlastFurnace.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_IronBlastFurnace.java deleted file mode 100644 index 78150aedbe..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_IronBlastFurnace.java +++ /dev/null @@ -1,32 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import net.minecraft.entity.player.InventoryPlayer; -import net.minecraft.inventory.Slot; - -import gregtech.api.gui.GT_ContainerMetaTile_Machine; -import gregtech.api.gui.GT_Slot_Output; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; - -public class CONTAINER_IronBlastFurnace extends GT_ContainerMetaTile_Machine { - public CONTAINER_IronBlastFurnace(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity) { - super(aInventoryPlayer, aTileEntity); - } - - @Override - public void addSlots(final InventoryPlayer aInventoryPlayer) { - this.addSlotToContainer(new Slot(this.mTileEntity, 0, 34, 16)); - this.addSlotToContainer(new Slot(this.mTileEntity, 1, 34, 34)); - this.addSlotToContainer(new GT_Slot_Output(this.mTileEntity, 2, 86, 25)); - this.addSlotToContainer(new GT_Slot_Output(this.mTileEntity, 3, 104, 25)); - } - - @Override - public int getSlotCount() { - return 4; - } - - @Override - public int getShiftClickSlotCount() { - return 2; - } -} diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MatterFab.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MatterFab.java deleted file mode 100644 index 808eb90728..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MatterFab.java +++ /dev/null @@ -1,42 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import net.minecraft.entity.player.InventoryPlayer; - -import gregtech.api.gui.GT_ContainerMetaTile_Machine; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; -import gtPlusPlus.core.slots.SlotNoInput; -import gtPlusPlus.xmod.gregtech.common.tileentities.machines.multi.production.GregtechMetaTileEntity_MassFabricator; - -/** - * NEVER INCLUDE THIS FILE IN YOUR MOD!!! - *

- * The Container I use for all my Basic Machines - */ -public class CONTAINER_MatterFab extends GT_ContainerMetaTile_Machine { - - public int mUUA_USED = ((GregtechMetaTileEntity_MassFabricator)this.mTileEntity.getMetaTileEntity()).getAmplifierUsed(); - public int mUUM_MADE = ((GregtechMetaTileEntity_MassFabricator)this.mTileEntity.getMetaTileEntity()).getMatterProduced(); - - public CONTAINER_MatterFab(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity) { - super(aInventoryPlayer, aTileEntity); - } - - public CONTAINER_MatterFab(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity, final boolean bindInventory) { - super(aInventoryPlayer, aTileEntity, bindInventory); - } - - @Override - public void addSlots(InventoryPlayer aInventoryPlayer) { - //addSlotToContainer(new SlotNoInput(mTileEntity, 1, 152, 5)); - } - - @Override - public int getSlotCount() { - return 0; - } - - @Override - public int getShiftClickSlotCount() { - return 0; - } -} diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MetaTileMachineLong.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MetaTileMachineLong.java deleted file mode 100644 index 6a3322ab2e..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MetaTileMachineLong.java +++ /dev/null @@ -1,244 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -import gregtech.api.gui.GT_Container; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; -import gregtech.api.util.GT_LanguageManager; - -import gtPlusPlus.api.objects.Logger; -import gtPlusPlus.api.objects.data.Pair; - -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.entity.player.InventoryPlayer; -import net.minecraft.inventory.ICrafting; - -import java.util.Iterator; - -public class CONTAINER_MetaTileMachineLong extends GT_Container { - - public int mActive = 0, mMaxProgressTime = 0, mProgressTime = 0, mSteam = 0, mSteamStorage = 0, mOutput = 0, mInput = 0, mID = 0, mDisplayErrorCode = 0; - private int oActive = 0, oMaxProgressTime = 0, oProgressTime = 0, oSteam = 0, oSteamStorage = 0, oOutput = 0, oInput = 0, oID = 0, oDisplayErrorCode = 0, mTimer = 0; - - public long pEnergy, pStorage; - private long nEnergy, nStorage; - - public short pIntMaxCountCurrent, pIntMaxCountMax; - private short nIntMaxCountCurrent, nIntMaxCountMax; - - public CONTAINER_MetaTileMachineLong(InventoryPlayer aInventoryPlayer, IGregTechTileEntity aTileEntity) { - super(aInventoryPlayer, aTileEntity); - - mTileEntity = aTileEntity; - - if (mTileEntity != null && mTileEntity.getMetaTileEntity() != null) { - addSlots(aInventoryPlayer); - if (doesBindPlayerInventory()) bindPlayerInventory(aInventoryPlayer); - detectAndSendChanges(); - } else { - aInventoryPlayer.player.openContainer = aInventoryPlayer.player.inventoryContainer; - } - } - public CONTAINER_MetaTileMachineLong(InventoryPlayer aInventoryPlayer, IGregTechTileEntity aTileEntity, boolean doesBindInventory) { - super(aInventoryPlayer, aTileEntity); - mTileEntity = aTileEntity; - - if (mTileEntity != null && mTileEntity.getMetaTileEntity() != null) { - addSlots(aInventoryPlayer); - if (doesBindPlayerInventory() && doesBindInventory) bindPlayerInventory(aInventoryPlayer); - detectAndSendChanges(); - } else { - aInventoryPlayer.player.openContainer = aInventoryPlayer.player.inventoryContainer; - } - } - - private Pair getPowerStored(){ - final long mStoredPower = this.pEnergy; - long mMaxInts = (mStoredPower/Integer.MAX_VALUE); - long mLeftOver = (mStoredPower % Integer.MAX_VALUE); - if (mMaxInts < 0 || mMaxInts >= /*4294967298L*/ Integer.MAX_VALUE) { - return new Pair(-1, 0); - } - if (mLeftOver < 0 || mLeftOver > Integer.MAX_VALUE) { - mLeftOver = 0; - } - Pair power = new Pair((int) mMaxInts, (int) mLeftOver); - return power; - } - - private Pair getMaxPowerStored(){ - final long mMaxStoredPower = this.pStorage; - long mMaxInts = (mMaxStoredPower/Integer.MAX_VALUE); - long mLeftOver = (mMaxStoredPower % Integer.MAX_VALUE); - if (mMaxInts < 0 || mMaxInts >= /*4294967298L*/ Integer.MAX_VALUE) { - return new Pair(-1, 0); - } - if (mLeftOver < 0 || mLeftOver > Integer.MAX_VALUE) { - mLeftOver = 0; - } - Pair power = new Pair((int) mMaxInts, (int) mLeftOver); - return power; - } - - @Override - public void detectAndSendChanges() { - super.detectAndSendChanges(); - if (mTileEntity.isClientSide() || mTileEntity.getMetaTileEntity() == null) return; - pStorage = Math.min(Long.MAX_VALUE, mTileEntity.getEUCapacity()); - pEnergy = Math.min(Long.MAX_VALUE, mTileEntity.getStoredEU()); - mSteamStorage = (int) Math.min(Integer.MAX_VALUE, mTileEntity.getSteamCapacity()); - mSteam = (int) Math.min(Integer.MAX_VALUE, mTileEntity.getStoredSteam()); - mOutput = (int) Math.min(Integer.MAX_VALUE, mTileEntity.getOutputVoltage()); - mInput = (int) Math.min(Integer.MAX_VALUE, mTileEntity.getInputVoltage()); - mDisplayErrorCode = mTileEntity.getErrorDisplayID(); - mProgressTime = mTileEntity.getProgress(); - mMaxProgressTime = mTileEntity.getMaxProgress(); - mActive = mTileEntity.isActive() ? 1 : 0; - mTimer++; - - Pair powerPacket = getPowerStored(); - Pair maxPowerPacket = getMaxPowerStored(); - - int mPacketsToSend = powerPacket.getKey(); - int mLeftOverPowerStored = powerPacket.getValue(); - - int mMaxStorageA = maxPowerPacket.getKey(); - int mMaxStorageB = maxPowerPacket.getValue(); - - //Someone has a VERY FULL power supply. - if (mPacketsToSend == -1) { - Logger.INFO("TOO MUCH MATH - USE BIGINTEGER - GAME BREAKING BUG MAY OCCUR"); - return; - } - - - Iterator var2 = this.crafters.iterator(); - while (var2.hasNext()) { - ICrafting var1 = (ICrafting) var2.next(); - if (mTimer % 500 == 10 || nEnergy != pEnergy) { - var1.sendProgressBarUpdate(this, 0, mLeftOverPowerStored & 65535); - var1.sendProgressBarUpdate(this, 1, mLeftOverPowerStored >>> 16); - var1.sendProgressBarUpdate(this, 7730, mPacketsToSend); - } - if (mTimer % 500 == 10 || nStorage != pStorage) { - var1.sendProgressBarUpdate(this, 2, mMaxStorageB & 65535); - var1.sendProgressBarUpdate(this, 3, mMaxStorageB >>> 16); - var1.sendProgressBarUpdate(this, 7731, mMaxStorageA); - } - if (mTimer % 500 == 10 || oOutput != mOutput) { - var1.sendProgressBarUpdate(this, 4, mOutput); - } - if (mTimer % 500 == 10 || oInput != mInput) { - var1.sendProgressBarUpdate(this, 5, mInput); - } - if (mTimer % 500 == 10 || oDisplayErrorCode != mDisplayErrorCode) { - var1.sendProgressBarUpdate(this, 6, mDisplayErrorCode); - } - if (mTimer % 500 == 10 || oProgressTime != mProgressTime) { - var1.sendProgressBarUpdate(this, 11, mProgressTime & 65535); - var1.sendProgressBarUpdate(this, 12, mProgressTime >>> 16); - } - if (mTimer % 500 == 10 || oMaxProgressTime != mMaxProgressTime) { - var1.sendProgressBarUpdate(this, 13, mMaxProgressTime & 65535); - var1.sendProgressBarUpdate(this, 14, mMaxProgressTime >>> 16); - } - if (mTimer % 500 == 10 || oID != mID) { - var1.sendProgressBarUpdate(this, 15, mID); - } - if (mTimer % 500 == 10 || oActive != mActive) { - var1.sendProgressBarUpdate(this, 16, mActive); - } - if (mTimer % 500 == 10 || oSteam != mSteam) { - var1.sendProgressBarUpdate(this, 17, mSteam & 65535); - var1.sendProgressBarUpdate(this, 18, mSteam >>> 16); - } - if (mTimer % 500 == 10 || oSteamStorage != mSteamStorage) { - var1.sendProgressBarUpdate(this, 19, mSteamStorage & 65535); - var1.sendProgressBarUpdate(this, 20, mSteamStorage >>> 16); - } - } - - oID = mID; - oSteam = mSteam; - oInput = mInput; - oActive = mActive; - oOutput = mOutput; - nEnergy = pEnergy; - nStorage = pStorage; - oSteamStorage = mSteamStorage; - oProgressTime = mProgressTime; - oMaxProgressTime = mMaxProgressTime; - oDisplayErrorCode = mDisplayErrorCode; - } - - @SideOnly(Side.CLIENT) - @Override - public void updateProgressBar(int par1, int par2) { - super.updateProgressBar(par1, par2); - switch (par1) { - /*case 7730: - pIntMaxCountCurrent = par2;*/ - case 0: - pEnergy = pEnergy & -65536 | par2; - break; - case 1: - pEnergy = pEnergy & 65535 | par2 << 16; - break; - case 2: - pStorage = pStorage & -65536 | par2; - break; - case 3: - pStorage = pStorage & 65535 | par2 << 16; - break; - case 4: - mOutput = par2; - break; - case 5: - mInput = par2; - break; - case 6: - mDisplayErrorCode = par2; - break; - case 11: - mProgressTime = mProgressTime & -65536 | par2; - break; - case 12: - mProgressTime = mProgressTime & 65535 | par2 << 16; - break; - case 13: - mMaxProgressTime = mMaxProgressTime & -65536 | par2; - break; - case 14: - mMaxProgressTime = mMaxProgressTime & 65535 | par2 << 16; - break; - case 15: - mID = par2; - break; - case 16: - mActive = par2; - break; - case 17: - mSteam = mSteam & -65536 | par2; - break; - case 18: - mSteam = mSteam & 65535 | par2 << 16; - break; - case 19: - mSteamStorage = mSteamStorage & -65536 | par2; - break; - case 20: - mSteamStorage = mSteamStorage & 65535 | par2 << 16; - break; - } - } - - @Override - public boolean canInteractWith(EntityPlayer player) { - return mTileEntity.isUseableByPlayer(player); - } - - public String trans(String aKey, String aEnglish){ - return GT_LanguageManager.addStringLocalization("Interaction_DESCRIPTION_Index_"+aKey, aEnglish, false); - } -} \ No newline at end of file diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MultiMachine.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MultiMachine.java deleted file mode 100644 index 88b9661c95..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MultiMachine.java +++ /dev/null @@ -1,283 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import java.lang.reflect.Field; -import java.util.ArrayList; -import java.util.List; - -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; -import gregtech.api.gui.GT_ContainerMetaTile_Machine; -import gregtech.api.interfaces.metatileentity.IMetaTileEntity; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; -import gregtech.api.util.GT_Recipe; -import gtPlusPlus.api.objects.Logger; -import gtPlusPlus.core.util.math.MathUtils; -import gtPlusPlus.core.util.reflect.ReflectionUtils; -import gtPlusPlus.xmod.gregtech.api.metatileentity.implementations.base.GregtechMeta_MultiBlockBase; -import net.minecraft.entity.player.InventoryPlayer; -import net.minecraft.inventory.Container; -import net.minecraft.inventory.ICrafting; - -/** - * NEVER INCLUDE THIS FILE IN YOUR MOD!!! - *

- * The Container I use for all my Basic Machines - */ -public class CONTAINER_MultiMachine extends GT_ContainerMetaTile_Machine { - - public String[] mTileDescription; - private String[] oTileDescription; - - private GregtechMeta_MultiBlockBase mMCTEI; - private boolean mControllerSet = false; - - - public CONTAINER_MultiMachine(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity) { - super(aInventoryPlayer, aTileEntity); - } - - public CONTAINER_MultiMachine(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity, final boolean bindInventory) { - super(aInventoryPlayer, aTileEntity, bindInventory); - } - - public static void setControllerInstance(CONTAINER_MultiMachine aContainer, IGregTechTileEntity aTile) { - if (aTile == null) { - return; - } - final IMetaTileEntity aMetaTileEntity = aTile.getMetaTileEntity(); - if (aMetaTileEntity == null) { - return; - } - if (aMetaTileEntity instanceof GregtechMeta_MultiBlockBase) { - aContainer.mMCTEI = (GregtechMeta_MultiBlockBase) aMetaTileEntity; - } - } - - public int aTotalTickTime = 0; - public int aMaxParallel = 0; - public int aPollutionTick = 0; - public int aMaxInputVoltage = 0; - public int aInputTier = 0; - public int aOutputTier = 0; - public int aRecipeDuration = 0; - public int aRecipeEU = 0; - public int aRecipeSpecial = 0; - public int aPollutionReduction = 0; - public int aStoredEnergy = 0; - public int aMaxEnergy = 0; - public int aEfficiency = 0; - - private int oTotalTickTime = 0; - private int oMaxParallel = 0; - private int oPollutionTick = 0; - private int oMaxInputVoltage = 0; - private int oInputTier = 0; - private int oOutputTier = 0; - private int oRecipeDuration = 0; - private int oRecipeEU = 0; - private int oRecipeSpecial = 0; - private int oPollutionReduction = 0; - private int oStoredEnergy = 0; - private int oMaxEnergy = 0; - private int oEfficiency = 0; - - private static Field timer; - //private static Field crafters; - - @Override - public final void detectAndSendChanges() { - super.detectAndSendChanges(); - if (this.mTileEntity.isClientSide() || this.mTileEntity.getMetaTileEntity() == null) { - return; - } - if (!mControllerSet) { - setControllerInstance(this, this.mTileEntity); - } - mControllerSet = (mMCTEI != null); - if (timer == null) { - timer = ReflectionUtils.getField(getClass(), "mTimer"); - } - if (crafters == null) { - //crafters = ReflectionUtils.getField(getClass(), "crafters"); - } - if (timer != null && crafters != null && mControllerSet) { - //Logger.INFO("Trying to update clientside GUI data"); - try { - //Logger.INFO("0"); - int aTimer = (int) ReflectionUtils.getFieldValue(timer, this); - - //List crafters1List = (List) crafters1; - List crafters2 = new ArrayList(); - //Logger.INFO("1"); - for (Object o : crafters) { - if (o instanceof ICrafting) { - crafters2.add((ICrafting) o); - } - } - //Logger.INFO("2"); - if (!crafters2.isEmpty()) { - //Logger.INFO("3"); - handleInitialFieldSetting(); - - try { - //Logger.INFO("4"); - for (final ICrafting var3 : crafters2) { - handleCraftingEvent(aTimer, var3); - } - //Logger.INFO("5"); - handleInternalFieldSetting(); - //Logger.INFO("6"); - } catch (Throwable t) { - - } - } - } catch (Throwable t) { - t.printStackTrace(); - } - } - else { - Logger.INFO("Failed."); - } - } - - public void handleInitialFieldSetting() { - this.aTotalTickTime = MathUtils.balance((int) mMCTEI.getTotalRuntimeInTicks(), Integer.MIN_VALUE, Integer.MAX_VALUE); - this.aMaxParallel = mMCTEI.getMaxParallelRecipes(); - this.aPollutionTick = mMCTEI.getPollutionPerTick(null); - this.aMaxInputVoltage = MathUtils.balance((int) mMCTEI.getMaxInputVoltage(), Integer.MIN_VALUE, Integer.MAX_VALUE); - this.aInputTier = MathUtils.balance((int) mMCTEI.getInputTier(), Integer.MIN_VALUE, Integer.MAX_VALUE); - this.aOutputTier = MathUtils.balance((int) mMCTEI.getOutputTier(), Integer.MIN_VALUE, Integer.MAX_VALUE); - if (mMCTEI.mLastRecipe != null) { - GT_Recipe aRecipe = mMCTEI.mLastRecipe; - this.aRecipeDuration = MathUtils.balance(aRecipe.mDuration, Integer.MIN_VALUE, Integer.MAX_VALUE); - this.aRecipeEU = MathUtils.balance(aRecipe.mEUt, Integer.MIN_VALUE, Integer.MAX_VALUE); - this.aRecipeSpecial = MathUtils.balance(aRecipe.mSpecialValue, Integer.MIN_VALUE, Integer.MAX_VALUE); - } - this.aPollutionReduction = mMCTEI.getPollutionReductionForAllMufflers(); - - this.aStoredEnergy = MathUtils.balance((int) mMCTEI.getStoredEnergyInAllEnergyHatches(), Integer.MIN_VALUE, Integer.MAX_VALUE); - this.aMaxEnergy = MathUtils.balance((int) mMCTEI.getMaxEnergyStorageOfAllEnergyHatches(), Integer.MIN_VALUE, Integer.MAX_VALUE); - this.aEfficiency = MathUtils.balance(mMCTEI.mEfficiency, Integer.MIN_VALUE, Integer.MAX_VALUE); - } - - public void handleCraftingEvent(int aTimer, ICrafting aCrafter) { - int aID = 750; - if (aTimer % 500 == 10 || this.oTotalTickTime != this.aTotalTickTime) { - aCrafter.sendProgressBarUpdate((Container) this, aID++, this.aTotalTickTime); - } - if (aTimer % 500 == 10 || this.oMaxParallel != this.aMaxParallel) { - aCrafter.sendProgressBarUpdate((Container) this, aID++, this.aMaxParallel); - } - if (aTimer % 500 == 10 || this.oPollutionTick != this.aPollutionTick) { - aCrafter.sendProgressBarUpdate((Container) this, aID++, this.aPollutionTick); - } - if (aTimer % 500 == 10 || this.oMaxInputVoltage != this.aMaxInputVoltage) { - aCrafter.sendProgressBarUpdate((Container) this, aID++, this.aMaxInputVoltage); - } - if (aTimer % 500 == 10 || this.oInputTier != this.aInputTier) { - aCrafter.sendProgressBarUpdate((Container) this, aID++, this.aInputTier); - } - if (aTimer % 500 == 10 || this.oOutputTier != this.aOutputTier) { - aCrafter.sendProgressBarUpdate((Container) this, aID++, this.aOutputTier); - } - if (aTimer % 500 == 10 || this.oRecipeDuration != this.aRecipeDuration) { - aCrafter.sendProgressBarUpdate((Container) this, aID++, this.aRecipeDuration); - } - if (aTimer % 500 == 10 || this.oRecipeEU != this.aRecipeEU) { - aCrafter.sendProgressBarUpdate((Container) this, aID++, this.aRecipeEU); - } - if (aTimer % 500 == 10 || this.oRecipeSpecial != this.aRecipeSpecial) { - aCrafter.sendProgressBarUpdate((Container) this, aID++, this.aRecipeSpecial); - } - if (aTimer % 500 == 10 || this.oPollutionReduction != this.aPollutionReduction) { - aCrafter.sendProgressBarUpdate((Container) this, aID++, this.aPollutionReduction); - } - if (aTimer % 500 == 10 || this.oStoredEnergy != this.aStoredEnergy) { - aCrafter.sendProgressBarUpdate((Container) this, aID++, this.aStoredEnergy); - } - if (aTimer % 500 == 10 || this.oMaxEnergy != this.aMaxEnergy) { - aCrafter.sendProgressBarUpdate((Container) this, aID++, this.aMaxEnergy); - } - if (aTimer % 500 == 10 || this.oEfficiency != this.aEfficiency) { - aCrafter.sendProgressBarUpdate((Container) this, aID++, this.aEfficiency); - } - } - - public void handleInternalFieldSetting() { - this.oTotalTickTime = this.aTotalTickTime; - this.oMaxParallel = this.aMaxParallel; - this.oPollutionTick = this.aPollutionTick; - this.oMaxInputVoltage = this.aMaxInputVoltage; - this.oInputTier = this.aInputTier; - this.oOutputTier = this.aOutputTier; - this.oRecipeDuration = this.aRecipeDuration; - this.oRecipeEU = this.aRecipeEU; - this.oRecipeSpecial = this.aRecipeSpecial; - this.oPollutionReduction = this.aPollutionReduction; - this.oStoredEnergy = this.aStoredEnergy; - this.oMaxEnergy = this.aMaxEnergy; - this.oEfficiency = this.aEfficiency; - } - - @SideOnly(Side.CLIENT) - @Override - public void updateProgressBar(final int par1, final int par2) { - super.updateProgressBar(par1, par2); - int shiftedSwitch = par1 - 750; - switch (shiftedSwitch) { - case 0: { - this.aTotalTickTime = par2; - break; - } - case 1: { - this.aMaxParallel = par2; - break; - } - case 2: { - this.aPollutionTick = par2; - break; - } - case 3: { - this.aMaxInputVoltage = par2; - break; - } - case 4: { - this.aInputTier = par2; - break; - } - case 5: { - this.aOutputTier = par2; - break; - } - case 6: { - this.aRecipeDuration = par2; - break; - } - case 7: { - this.aRecipeEU = par2; - break; - } - case 8: { - this.aRecipeSpecial = par2; - break; - } - case 9: { - this.aPollutionReduction = par2; - break; - } - case 10: { - this.aStoredEnergy = par2; - break; - } - case 11: { - this.aMaxEnergy = par2; - break; - } - case 12: { - this.aEfficiency = par2; - break; - } - } - } - -} diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MultiMachine_NoPlayerInventory.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MultiMachine_NoPlayerInventory.java deleted file mode 100644 index 2d63a13d60..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_MultiMachine_NoPlayerInventory.java +++ /dev/null @@ -1,27 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.entity.player.InventoryPlayer; -import net.minecraft.item.ItemStack; - -public class CONTAINER_MultiMachine_NoPlayerInventory extends CONTAINER_MultiMachine { - - public CONTAINER_MultiMachine_NoPlayerInventory(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity) { - super(aInventoryPlayer, aTileEntity); - } - - public CONTAINER_MultiMachine_NoPlayerInventory(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity, final boolean bindInventory) { - super(aInventoryPlayer, aTileEntity, bindInventory); - } - - public boolean doesBindPlayerInventory() { - return false; - } - - @Override - public ItemStack slotClick(final int aSlotIndex, final int aMouseclick, final int aShifthold, final EntityPlayer aPlayer) { - return null; - } - -} diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_PowerSubStation.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_PowerSubStation.java deleted file mode 100644 index 937513751b..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_PowerSubStation.java +++ /dev/null @@ -1,41 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import net.minecraft.inventory.IInventory; -import net.minecraft.inventory.Slot; - -import gregtech.api.gui.GT_Container_MultiMachine; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; - -import gtPlusPlus.core.slots.SlotNoInput; - -import net.minecraft.entity.player.InventoryPlayer; - -public class CONTAINER_PowerSubStation extends GT_Container_MultiMachine { - - public CONTAINER_PowerSubStation(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity) { - super(aInventoryPlayer, aTileEntity); - } - - public CONTAINER_PowerSubStation(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity, - final boolean bindInventory) { - super(aInventoryPlayer, aTileEntity, bindInventory); - } - - public void addSlots(final InventoryPlayer aInventoryPlayer) { - this.addSlotToContainer(new Slot((IInventory) this.mTileEntity, 1, 155, 5)); - this.addSlotToContainer(new SlotNoInput((IInventory) this.mTileEntity, 2, 155, 23)); - - for (int i = 0; i < 9; ++i) { - this.addSlotToContainer(new Slot((IInventory) aInventoryPlayer, i, 8 + i * 18, 167)); - } - - } - - public int getSlotCount() { - return 10; - } - - public int getShiftClickSlotCount() { - return 1; - } -} \ No newline at end of file diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SafeBlock.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SafeBlock.java deleted file mode 100644 index 9a84ba66ab..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SafeBlock.java +++ /dev/null @@ -1,124 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import java.util.UUID; - -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.entity.player.InventoryPlayer; -import net.minecraft.inventory.Slot; -import net.minecraft.item.ItemStack; - -import gregtech.api.gui.GT_ContainerMetaTile_Machine; -import gregtech.api.gui.GT_Slot_Holo; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; - -import gtPlusPlus.core.util.player.PlayerCache; -import gtPlusPlus.xmod.gregtech.common.tileentities.storage.GregtechMetaSafeBlock; - -public class CONTAINER_SafeBlock -extends GT_ContainerMetaTile_Machine { - public CONTAINER_SafeBlock(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity) { - super(aInventoryPlayer, aTileEntity); - } - - //public String UUID = ((BaseMetaTileEntity)mTileEntity).getMetaTileEntity().getBaseMetaTileEntity().getOwnerName(); - public UUID ownerUUID = ((GregtechMetaSafeBlock)this.mTileEntity.getMetaTileEntity()).ownerUUID; - public String tempPlayer = PlayerCache.lookupPlayerByUUID(this.ownerUUID); - public boolean blockStatus = ((GregtechMetaSafeBlock)this.mTileEntity.getMetaTileEntity()).bUnbreakable; - - @Override - public void addSlots(final InventoryPlayer aInventoryPlayer) { - for (int y = 0; y < 3; y++) { - for (int x = 0; x < 9; x++) { - this.addSlotToContainer(new Slot(this.mTileEntity, x + (y * 9), 8 + (x * 18), 5 + (y * 18))); - } - } - this.addSlotToContainer(new GT_Slot_Holo(this.mTileEntity, 27, 8, 63, false, true, 1)); - this.addSlotToContainer(new GT_Slot_Holo(this.mTileEntity, 27, 26, 63, false, true, 1)); - this.addSlotToContainer(new GT_Slot_Holo(this.mTileEntity, 27, 44, 63, false, true, 1)); - } - - @Override - public ItemStack slotClick(final int aSlotIndex, final int aMouseclick, final int aShifthold, final EntityPlayer aPlayer) { - final int runs = 0; - if (aSlotIndex < 27) { - return super.slotClick(aSlotIndex, aMouseclick, aShifthold, aPlayer); - } - final Slot tSlot = (Slot) this.inventorySlots.get(aSlotIndex); - if (tSlot != null) { - if (this.mTileEntity.getMetaTileEntity() == null) { - return null; - } - if (aSlotIndex == 27) { - - - /*((GregtechMetaSafeBlock) this.mTileEntity.getMetaTileEntity()).bOutput = (!((GregtechMetaSafeBlock) this.mTileEntity.getMetaTileEntity()).bOutput); - if (((GregtechMetaSafeBlock) this.mTileEntity.getMetaTileEntity()).bOutput) { - if (aPlayer != null && aPlayer instanceof EntityPlayerMP && (((GregtechMetaSafeBlock)this.mTileEntity.getMetaTileEntity()).bOutput != false)) { - - Utils.LOG_INFO(String.valueOf(Sys.is64Bit())); - Utils.messagePlayer(aPlayer, "Salmon"); - } - - GT_Utility.sendChatToPlayer(aPlayer, "Emit Energy to Outputside"); - } else { - GT_Utility.sendChatToPlayer(aPlayer, "Don't emit Energy"); - } - return null;*/ - - - } - if (aSlotIndex == 28) {} - /* ((GregtechMetaSafeBlock) this.mTileEntity.getMetaTileEntity()).bRedstoneIfFull = (!((GregtechMetaSafeBlock) this.mTileEntity.getMetaTileEntity()).bRedstoneIfFull); - if (((GregtechMetaSafeBlock) this.mTileEntity.getMetaTileEntity()).bRedstoneIfFull) { - GT_Utility.sendChatToPlayer(aPlayer, "Emit Redstone if no Slot is free"); - } else { - GT_Utility.sendChatToPlayer(aPlayer, "Don't emit Redstone"); - } - return null; - }*/ - if (aSlotIndex == 29) /*{ - if (((GregtechMetaSafeBlock) this.mTileEntity.getMetaTileEntity()).bUnbreakable) { - if (((GregtechMetaSafeBlock) this.mTileEntity.getMetaTileEntity()).bUnbreakable) { - makeIndestructible(aPlayer); - } - else { - - } - } else { - makeIndestructible(aPlayer); - } - return null; - }*/ - - { - ((GregtechMetaSafeBlock) this.mTileEntity.getMetaTileEntity()).bUnbreakable = (!((GregtechMetaSafeBlock) this.mTileEntity.getMetaTileEntity()).bUnbreakable); - this.blockStatus = ((GregtechMetaSafeBlock)this.mTileEntity.getMetaTileEntity()).bUnbreakable; - this.ownerUUID = ((GregtechMetaSafeBlock)this.mTileEntity.getMetaTileEntity()).ownerUUID; - //Utils.messagePlayer(aPlayer, "Is the safe locked? "+String.valueOf(((GregtechMetaSafeBlock) this.mTileEntity.getMetaTileEntity()).bUnbreakable).toUpperCase()); - /*if (aPlayer != null && aPlayer instanceof EntityPlayerMP && (((GregtechMetaSafeBlock)this.mTileEntity.getMetaTileEntity()).bUnbreakable != false)) { - UnbreakableBlockManager Xasda = new UnbreakableBlockManager(); - Xasda.setmTileEntity((BaseMetaTileEntity) mTileEntity, aPlayer); - } - else { - UnbreakableBlockManager Xasda = new UnbreakableBlockManager(); - Xasda.setmTileEntity((BaseMetaTileEntity) mTileEntity, aPlayer); - }*/ - return null; - } - - - } - return super.slotClick(aSlotIndex, aMouseclick, aShifthold, aPlayer); - } - - @Override - public int getSlotCount() { - return 27; - } - - @Override - public int getShiftClickSlotCount() { - return 27; - } - -} diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SolarGenerator.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SolarGenerator.java deleted file mode 100644 index a3f58836e3..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SolarGenerator.java +++ /dev/null @@ -1,85 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import java.util.Iterator; - -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -import net.minecraft.entity.player.InventoryPlayer; -import net.minecraft.inventory.ICrafting; - -import gregtech.api.gui.GT_ContainerMetaTile_Machine; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; - -import gtPlusPlus.xmod.gregtech.common.tileentities.generators.GregtechMetaTileEntitySolarGenerator; - -public class CONTAINER_SolarGenerator -extends GT_ContainerMetaTile_Machine { - public int mWaterAmount = 0; - public int mSteamAmount = 0; - public int mProcessingEnergy = 0; - public int mTemperature = 2; - public CONTAINER_SolarGenerator(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity) { - super(aInventoryPlayer, aTileEntity); - } - - @Override - public void addSlots(final InventoryPlayer aInventoryPlayer) { - //addSlotToContainer(new Slot(this.mTileEntity, 2, 116, 62)); - //addSlotToContainer(new Slot(this.mTileEntity, 0, 44, 26)); - //addSlotToContainer(new Slot(this.mTileEntity, 1, 44, 62)); - //addSlotToContainer(new Slot(this.mTileEntity, 3, 116, 26)); - } - - @Override - public int getSlotCount() { - return 0; - } - - @Override - public int getShiftClickSlotCount() { - return 0; - } - - @Override - public void detectAndSendChanges() { - super.detectAndSendChanges(); - if ((this.mTileEntity.isClientSide()) || (this.mTileEntity.getMetaTileEntity() == null)) { - return; - } - this.mTemperature = ((GregtechMetaTileEntitySolarGenerator) this.mTileEntity.getMetaTileEntity()).mSolarCharge; - this.mProcessingEnergy = ((GregtechMetaTileEntitySolarGenerator) this.mTileEntity.getMetaTileEntity()).mProcessingEnergy; - - this.mTemperature = Math.min(54, Math.max(0, (this.mTemperature * 54) / (((GregtechMetaTileEntitySolarGenerator) this.mTileEntity.getMetaTileEntity()).maxProgresstime() - 10))); - this.mEnergy = (int) Math.min(Integer.MAX_VALUE, this.mTileEntity.getStoredEU()); - this.mProcessingEnergy = Math.min(14, Math.max(this.mProcessingEnergy > 0 ? 1 : 0, (this.mProcessingEnergy * 14) / 1000)); - - final Iterator var2 = this.crafters.iterator(); - while (var2.hasNext()) { - final ICrafting var1 = (ICrafting) var2.next(); - var1.sendProgressBarUpdate(this, 100, this.mTemperature); - var1.sendProgressBarUpdate(this, 101, this.mProcessingEnergy); - var1.sendProgressBarUpdate(this, 102, this.mSteamAmount); - var1.sendProgressBarUpdate(this, 103, this.mWaterAmount); - } - } - - @Override - @SideOnly(Side.CLIENT) - public void updateProgressBar(final int par1, final int par2) { - super.updateProgressBar(par1, par2); - switch (par1) { - case 100: - this.mTemperature = par2; - break; - case 101: - this.mProcessingEnergy = par2; - break; - case 102: - this.mSteamAmount = par2; - break; - case 103: - this.mWaterAmount = par2; - } - } -} diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SteamCondenser.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SteamCondenser.java deleted file mode 100644 index 6fcd53b139..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SteamCondenser.java +++ /dev/null @@ -1,99 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import java.util.Iterator; - -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -import net.minecraft.entity.player.InventoryPlayer; -import net.minecraft.inventory.ICrafting; -import net.minecraft.inventory.Slot; - -import gregtech.api.gui.GT_ContainerMetaTile_Machine; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; - -import gtPlusPlus.xmod.gregtech.api.metatileentity.implementations.base.generators.GregtechMetaBoilerBase; - -public class CONTAINER_SteamCondenser extends GT_ContainerMetaTile_Machine -{ - public CONTAINER_SteamCondenser(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity) - { - super(aInventoryPlayer, aTileEntity); - } - - @Override - public void addSlots(final InventoryPlayer aInventoryPlayer) - { - this.addSlotToContainer(new Slot(this.mTileEntity, 2, 116, 62)); - this.addSlotToContainer(new Slot(this.mTileEntity, 0, 44, 26)); - this.addSlotToContainer(new Slot(this.mTileEntity, 1, 44, 62)); - this.addSlotToContainer(new Slot(this.mTileEntity, 3, 116, 26)); - } - - @Override - public int getSlotCount() - { - return 4; - } - - @Override - public int getShiftClickSlotCount() - { - return 1; - } - - public int mWaterAmount = 0; - public int mSteamAmount = 0; - public int mProcessingEnergy = 0; - public int mTemperature = 2; - public long mTickingTime = ((GregtechMetaBoilerBase)this.mTileEntity.getMetaTileEntity()).RI; - - @Override - public void detectAndSendChanges() - { - super.detectAndSendChanges(); - if ((this.mTileEntity.isClientSide()) || (this.mTileEntity.getMetaTileEntity() == null)) { - return; - } - int steamCapacity = ((GregtechMetaBoilerBase)this.mTileEntity.getMetaTileEntity()).getSteamCapacity(); - int waterCapacity = ((GregtechMetaBoilerBase)this.mTileEntity.getMetaTileEntity()).getCapacity(); - this.mTemperature = ((GregtechMetaBoilerBase)this.mTileEntity.getMetaTileEntity()).mTemperature; - this.mProcessingEnergy = ((GregtechMetaBoilerBase)this.mTileEntity.getMetaTileEntity()).mProcessingEnergy; - this.mSteamAmount = (((GregtechMetaBoilerBase)this.mTileEntity.getMetaTileEntity()).mSteam == null ? 0 : ((GregtechMetaBoilerBase)this.mTileEntity.getMetaTileEntity()).mSteam.amount); - this.mWaterAmount = (((GregtechMetaBoilerBase)this.mTileEntity.getMetaTileEntity()).mFluid == null ? 0 : ((GregtechMetaBoilerBase)this.mTileEntity.getMetaTileEntity()).mFluid.amount); - this.mTickingTime = ((GregtechMetaBoilerBase)this.mTileEntity.getMetaTileEntity()).RI; - - this.mTemperature = Math.min(54, Math.max(0, (this.mTemperature * 54) / (((GregtechMetaBoilerBase)this.mTileEntity.getMetaTileEntity()).maxProgresstime() - 10))); - this.mSteamAmount = Math.min(54, Math.max(0, (this.mSteamAmount * 54) / (steamCapacity - 100))); - this.mWaterAmount = Math.min(54, Math.max(0, (this.mWaterAmount * 54) / (waterCapacity - 100))); - this.mProcessingEnergy = Math.min(14, Math.max(this.mProcessingEnergy > 0 ? 1 : 0, (this.mProcessingEnergy * 14) / 1000)); - - final Iterator var2 = this.crafters.iterator(); - while (var2.hasNext()) - { - final ICrafting var1 = (ICrafting)var2.next(); - var1.sendProgressBarUpdate(this, 100, this.mTemperature); - var1.sendProgressBarUpdate(this, 101, this.mProcessingEnergy); - var1.sendProgressBarUpdate(this, 102, this.mSteamAmount); - var1.sendProgressBarUpdate(this, 103, this.mWaterAmount); - } - } - - @Override - @SideOnly(Side.CLIENT) - public void updateProgressBar(final int par1, final int par2) - { - super.updateProgressBar(par1, par2); - switch (par1) - { - case 100: - this.mTemperature = par2; break; - case 101: - this.mProcessingEnergy = par2; break; - case 102: - this.mSteamAmount = par2; break; - case 103: - this.mWaterAmount = par2; - } - } -} \ No newline at end of file diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SuperChest.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SuperChest.java deleted file mode 100644 index dcab57c380..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_SuperChest.java +++ /dev/null @@ -1,78 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import java.util.Iterator; - -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; -import gregtech.api.gui.GT_ContainerMetaTile_Machine; -import gregtech.api.gui.GT_Slot_Output; -import gregtech.api.gui.GT_Slot_Render; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; -import gtPlusPlus.core.slots.SlotLockedInput; -import gtPlusPlus.xmod.gregtech.common.tileentities.storage.GT_MetaTileEntity_TieredChest; -import gtPlusPlus.xmod.gregtech.common.tileentities.storage.shelving.GT4Entity_Shelf_Large; -import net.minecraft.entity.player.InventoryPlayer; -import net.minecraft.inventory.ICrafting; -import net.minecraft.item.ItemStack; - -public class CONTAINER_SuperChest extends GT_ContainerMetaTile_Machine { - - public int mContent = 0; - private ItemStack mLockedSlotStack = null; - - public CONTAINER_SuperChest(InventoryPlayer aInventoryPlayer, IGregTechTileEntity aTileEntity) { - super(aInventoryPlayer, aTileEntity); - } - - public void addSlots(InventoryPlayer aInventoryPlayer) { - this.addSlotToContainer(new SlotLockedInput(this.mTileEntity, 0, 80, 17, mLockedSlotStack)); - this.addSlotToContainer(new GT_Slot_Output(this.mTileEntity, 1, 80, 53)); - this.addSlotToContainer(new GT_Slot_Render(this.mTileEntity, 2, 59, 42)); - } - - public void detectAndSendChanges() { - super.detectAndSendChanges(); - if (!this.mTileEntity.isClientSide() && this.mTileEntity.getMetaTileEntity() != null) { - if (this.mTileEntity.getMetaTileEntity() instanceof GT_MetaTileEntity_TieredChest) { - this.mContent = ((GT_MetaTileEntity_TieredChest) this.mTileEntity.getMetaTileEntity()).mItemCount; - mLockedSlotStack = ((GT_MetaTileEntity_TieredChest) this.mTileEntity.getMetaTileEntity()).mItemStack; - } - if (this.mTileEntity.getMetaTileEntity() instanceof GT4Entity_Shelf_Large) { - this.mContent = ((GT4Entity_Shelf_Large) this.mTileEntity.getMetaTileEntity()).mItemCount; - mLockedSlotStack = ((GT4Entity_Shelf_Large) this.mTileEntity.getMetaTileEntity()).mItemStack; - } - else { - this.mContent = 0; - } - - Iterator var2 = this.crafters.iterator(); - - while (var2.hasNext()) { - ICrafting var1 = (ICrafting) var2.next(); - var1.sendProgressBarUpdate(this, 100, this.mContent & 65535); - var1.sendProgressBarUpdate(this, 101, this.mContent >>> 16); - } - } - } - - @SideOnly(Side.CLIENT) - public void updateProgressBar(int par1, int par2) { - super.updateProgressBar(par1, par2); - switch (par1) { - case 100 : - this.mContent = this.mContent & -65536 | par2; - break; - case 101 : - this.mContent = this.mContent & 65535 | par2 << 16; - } - - } - - public int getSlotCount() { - return 2; - } - - public int getShiftClickSlotCount() { - return 1; - } -} \ No newline at end of file diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_TreeFarmer.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_TreeFarmer.java deleted file mode 100644 index bf4dffb904..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/CONTAINER_TreeFarmer.java +++ /dev/null @@ -1,71 +0,0 @@ - -package gtPlusPlus.xmod.gregtech.api.gui; - -import java.util.List; - -import net.minecraft.entity.player.InventoryPlayer; -import net.minecraft.inventory.ICrafting; - -import gregtech.api.gui.GT_ContainerMetaTile_Machine; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; - -import gtPlusPlus.core.slots.SlotBuzzSaw; -import gtPlusPlus.xmod.gregtech.common.tileentities.machines.multi.production.GregtechMetaTileEntityTreeFarm; - -public class CONTAINER_TreeFarmer extends GT_ContainerMetaTile_Machine { - - public long maxEU = 0; - public long storedEU = 0; - - public CONTAINER_TreeFarmer(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity) { - super(aInventoryPlayer, aTileEntity); - } - - public CONTAINER_TreeFarmer(final InventoryPlayer aInventoryPlayer, final IGregTechTileEntity aTileEntity, final boolean bindInventory) { - super(aInventoryPlayer, aTileEntity, bindInventory); - } - - @Override - public void addSlots(final InventoryPlayer aInventoryPlayer) { - this.addSlotToContainer(new SlotBuzzSaw(this.mTileEntity, 1, 80, 17)); - } - - @Override - public int getSlotCount() { - return 1; - } - - @Override - public int getShiftClickSlotCount() { - return 1; - } - - @Override - public void updateProgressBar(final int id, final int value) { - super.updateProgressBar(id, value); - switch (id) { - case 100: - this.maxEU = value; - return; - case 101: - this.storedEU = value; - break; - default: - break; - } - } - - @SuppressWarnings("unchecked") - @Override - public void detectAndSendChanges() { - super.detectAndSendChanges(); - for(final ICrafting crafting : (List)this.crafters) { - crafting.sendProgressBarUpdate(this, 100, (int) ((GregtechMetaTileEntityTreeFarm) this.mTileEntity.getMetaTileEntity()).maxEUStore()); - crafting.sendProgressBarUpdate(this, 101, (int) ((GregtechMetaTileEntityTreeFarm) this.mTileEntity.getMetaTileEntity()).getEUVar()); - if (((GregtechMetaTileEntityTreeFarm) this.mTileEntity.getMetaTileEntity()).isCorrectMachinePart(this.mTileEntity.getStackInSlot(1))){ - this.mTileEntity.markDirty(); - } - } - } - -} diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_AdvancedBoiler.java b/src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_AdvancedBoiler.java deleted file mode 100644 index d532a98030..0000000000 --- a/src/Java/gtPlusPlus/xmod/gregtech/api/gui/GUI_AdvancedBoiler.java +++ /dev/null @@ -1,44 +0,0 @@ -package gtPlusPlus.xmod.gregtech.api.gui; - -import net.minecraft.entity.player.InventoryPlayer; - -import gregtech.api.gui.GT_GUIContainerMetaTile_Machine; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; - -public class GUI_AdvancedBoiler - extends GT_GUIContainerMetaTile_Machine { - public GUI_AdvancedBoiler(InventoryPlayer aInventoryPlayer, IGregTechTileEntity aTileEntity, String aTextureName) { - super(new CONTAINER_AdvancedBoiler(aInventoryPlayer, aTileEntity), "miscutils:textures/gui/" + aTextureName); - } - - @Override - protected void drawGuiContainerForegroundLayer(int par1, int par2) { - this.fontRendererObj.drawString("Advanced Boiler", 8, 4, 4210752); - } - - @Override - protected void drawGuiContainerBackgroundLayer(float par1, int par2, int par3) { - super.drawGuiContainerBackgroundLayer(par1, par2, par3); - int x = (this.width - this.xSize) / 2; - int y = (this.height - this.ySize) / 2; - drawTexturedModalRect(x, y, 0, 0, this.xSize, this.ySize); - if (this.mContainer != null) { - int tScale = ((CONTAINER_AdvancedBoiler) this.mContainer).mSteamAmount; - if (tScale > 0) { - drawTexturedModalRect(x + 70, y + 25 + 54 - tScale, 194, 54 - tScale, 10, tScale); - } - tScale = ((CONTAINER_AdvancedBoiler) this.mContainer).mWaterAmount; - if (tScale > 0) { - drawTexturedModalRect(x + 83, y + 25 +