From de3679def5044a622e00b2f3b46a84d255eb32c1 Mon Sep 17 00:00:00 2001 From: Aidan Brady Date: Wed, 3 Apr 2013 15:37:26 -0400 Subject: [PATCH] v5.5.4 Beta #4 *Default minecraft ISidedInventory support in all machines. *Fancied up Universal Cable texture. *Electrolytic Separators and Bio-Generators use LiquidTanks instead of LiquidSlots. *Fixed IInventory support. *Fixed Universal Cable BuildCraft crash. *Added the Electric Pump, a machine that can pump any kind of liquid and automatically outputs into adjacent pipes. --- .../mods/mekanism/gui/GuiElectricPump.png | Bin 0 -> 4325 bytes .../mods/mekanism/render/UniversalCable.png | Bin 13703 -> 17865 bytes .../textures/blocks/ElectricPumpFront.png | Bin 0 -> 1555 bytes .../textures/blocks/ElectricPumpSide.png | Bin 0 -> 1494 bytes src/minecraft/mekanism/api/SideData.java | 6 +- .../mekanism/client/ClientProxy.java | 3 + .../mekanism/client/GuiElectricPump.java | 95 ++++++++++ .../mekanism/common/BlockMachine.java | 27 ++- .../mekanism/common/CommonProxy.java | 2 + .../common/ContainerElectricPump.java | 101 +++++++++++ .../common/EnergyTransferProtocol.java | 2 +- .../mekanism/common/ItemBlockMachine.java | 4 + .../mekanism/common/ItemStorageTank.java | 4 +- src/minecraft/mekanism/common/Mekanism.java | 2 + .../TileEntityAdvancedElectricMachine.java | 32 +++- .../common/TileEntityAdvancedFactory.java | 10 +- .../common/TileEntityBasicMachine.java | 6 + .../common/TileEntityContainerBlock.java | 29 ++- .../common/TileEntityElectricMachine.java | 30 +++- .../common/TileEntityElectricPump.java | 166 ++++++++++++++++++ .../common/TileEntityEliteFactory.java | 10 +- .../mekanism/common/TileEntityEnergyCube.java | 26 +++ .../mekanism/common/TileEntityFactory.java | 48 ++++- .../mekanism/common/TileEntityGasTank.java | 22 +++ .../common/TileEntityMetallurgicInfuser.java | 36 +++- .../mekanism/common/TileEntityTeleporter.java | 20 +++ .../common/TileEntityBioGenerator.java | 23 +++ .../TileEntityElectrolyticSeparator.java | 41 +++++ .../common/TileEntityHeatGenerator.java | 23 +++ .../common/TileEntityHydrogenGenerator.java | 24 +++ .../common/TileEntitySolarGenerator.java | 25 ++- 31 files changed, 768 insertions(+), 49 deletions(-) create mode 100755 bin/minecraft/mods/mekanism/gui/GuiElectricPump.png create mode 100644 bin/minecraft/mods/mekanism/textures/blocks/ElectricPumpFront.png create mode 100644 bin/minecraft/mods/mekanism/textures/blocks/ElectricPumpSide.png create mode 100644 src/minecraft/mekanism/client/GuiElectricPump.java create mode 100644 src/minecraft/mekanism/common/ContainerElectricPump.java create mode 100644 src/minecraft/mekanism/common/TileEntityElectricPump.java diff --git a/bin/minecraft/mods/mekanism/gui/GuiElectricPump.png b/bin/minecraft/mods/mekanism/gui/GuiElectricPump.png new file mode 100755 index 0000000000000000000000000000000000000000..b0f95a9a264c1f70543d1e3f2959d9ff396679a5 GIT binary patch literal 4325 zcmeI0X;2f}w#Pe75)uX(BC|-Ckr{)4ObG`B83Ys%5g{N)f-kv?Fz6BnppejT?n<#g0KkMSlt1fkl zp&BB&Fv2Guq2s3Vg2?kRpT4tR*t#UBm)ahWnSCQ9ud;}68?TQ%uj=yV+{RYN(Xpd5 zCNti{R%XPDFSDiG5+9V&a=MhVGK$1Ab5A7q();Xr`pV`UwbDB}MYUgvZN8r$mrX`> zET%8*I(}DVMyGu4Nm6iPg^0s`1^mDG5LDa{a)HeI>D?&ek^`!AaZdjRm9RPOg{SCx?&D z*bs^3`$v(Zh?t(RBK{NGmm>6H4oFt@Y$(q^Y*REEh#-m5|B#?8pXR(6^qWmDZgaWF z_GQ1aBbPoRW?w!%eRHIPe)iEjP%-USW>M!Pg_nYVQQlCD=C-=#Xl?OJ-~RN~A1qe&t|gNXWEiJ^OWBfSgZ zNXhGi_y%L0Y2<-nuf9{~s|#2*vsPA$j^bM9`%COh{&3DcocX5F+Q3x#aNEsWe|7lk zDLD0t28~=ln)apjX6m03japAn7MiqHgfZV%ox!_&f^p@}(-(AQNSHq=4F?}DpzL26 zzuJf3yAo_Hrv8Dfwz1a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KOk5~hl<6oRa0BJ8yc;~21%2p?MfD<>DVeH z9(p*dx19w`~g7O0}n_%Aq@s%d)fBDv`JHkDym6Hd+5XuAtvnwRpGmK zVkc9?T=n|PIo~X-eVh__(Z?q}P9Z-Dj?gOW6|D%o20XmjW-qs4UjrD(li^iv8@eK9k+ZFm zVRFymFOPAzG5-%Pn|1W;U4vNroTa&AxDScmEA~{ri9gr1^c?U@uwSpaNnw8l_>cP1 zd;)kMQS_;jeRSUEM_*s96y65j1$)tOrwdK{YIQMt92l|D^(E_=$Rjw{b!QT@q!)ni zR`|5oW9X5n$Wv+HVc@|^eX5yXnsHX8PF3UX~a6)MwxDE0HaPjyrlI!;jX{6Kvuh*8ej?;85ekN$?5uuCiS zBTvvVG+XTxAO{m@bvM#Jr)z6J><&E22D|vq?Y?Vkbo_DijopiF$2PET#mZ8eu=y$(ArYkv7@Ex`GL?QCc!_*KFrd&;n1r7 zqW-CFs9&fT)ZaU5gc&=gBz-DaCw(vdOp0__x+47~U6sC(E(JNe@4cTT*n6*E zVH4eoU1-&7pEV~_PRe`a7v+@vy!^5}8?Y3)UmlaER00051Nkl_kDkgg)~i* z#Q>>SRkdki7>3OnFO1{JFTL}oX_orC7xiDt$D8h=OE#Qq7V?Kc1b002ovPDHLk FV1kqM?>GPe literal 0 HcmV?d00001 diff --git a/bin/minecraft/mods/mekanism/textures/blocks/ElectricPumpSide.png b/bin/minecraft/mods/mekanism/textures/blocks/ElectricPumpSide.png new file mode 100644 index 0000000000000000000000000000000000000000..b12791ef9e5a9dab8455678aee8be7ba67cab3e8 GIT binary patch literal 1494 zcmV;{1u6Q8P)4Tx05}naRo`#hR1`jmZ&IWdKOk5~hl<6oRa0BJ8yc;~21%2p?MfD<>DVeH z9(p*dx19w`~g7O0}n_%Aq@s%d)fBDv`JHkDym6Hd+5XuAtvnwRpGmK zVkc9?T=n|PIo~X-eVh__(Z?q}P9Z-Dj?gOW6|D%o20XmjW-qs4UjrD(li^iv8@eK9k+ZFm zVRFymFOPAzG5-%Pn|1W;U4vNroTa&AxDScmEA~{ri9gr1^c?U@uwSpaNnw8l_>cP1 zd;)kMQS_;jeRSUEM_*s96y65j1$)tOrwdK{YIQMt92l|D^(E_=$Rjw{b!QT@q!)ni zR`|5oW9X5n$Wv+HVc@|^eX5yXnsHX8PF3UX~a6)MwxDE0HaPjyrlI!;jX{6Kvuh*8ej?;85ekN$?5uuCiS zBTvvVG+XTxAO{m@bvM#Jr)z6J><&E22D|vq?Y?Vkbo_DijopiF$2PET#mZ8eu=y$(ArYkv7@Ex`GL?QCc!_*KFrd&;n1r7 zqW-CFs9&fT)ZaU5gc&=gBz-DaCw(vdOp0__x+47~U6sC(E(JNe@4cTT*n6*E zVH4eoU1-&7pEV~_PRe`a7v+@vy!^5}8?Y3)UmlaER0004PNklTOZM%*CIA{G2-T{|Pr@-BCi0~CiD=ipne9|r%)ZPhb;h|s>__%^^ z!y&;LID^MJF`b<1j|@=ItnY$@!x=E4)F*h?bre$7Wm&4`Sp^6zcNxb~cCGC+O|4_* zz)s)@Y%Usx!3=HvEXxk#t{^`H0EfT$-A?1vqkZL&AXy5~!*w!B1OEc(8yL zjCn_J#CH!Ng4)tF&FNGdm=*?I0c~Qd&)`_+E#UgA$uSKa0++5pg0M+Q@e=TP!?~oE zW#M79z}dT9n{o+X8~z1g@SQXHZ|k(SfyKtTj_l`(4gJ3^*h%Wk3tJotjRM w+B*X=;obtV;Sk^}pl>w 0) + { + displayGauge(guiWidth, guiHeight, 14, 7, tileEntity.getScaledLiquidLevel(58), tileEntity.liquidTank.getLiquid()); + } + } + + /* + * Credit to BuildCraft for both the gauge texture and parts of the code. + */ + public void displayGauge(int width, int height, int xPos, int yPos, int scale, LiquidStack liquid) + { + if(liquid == null) + { + return; + } + + int start = 0; + + while(true) + { + int renderRemaining = 0; + + if(scale > 16) + { + renderRemaining = 16; + scale -= 16; + } + else { + renderRemaining = scale; + scale = 0; + } + + mc.renderEngine.bindTexture(liquid.canonical().getTextureSheet()); + drawTexturedModelRectFromIcon(width + yPos, height + xPos + 58 - renderRemaining - start, liquid.canonical().getRenderingIcon(), 16, 16 - (16 - renderRemaining)); + start = start + 16; + + if (renderRemaining == 0 || scale == 0) + { + break; + } + } + + mc.renderEngine.bindTexture("/mods/mekanism/gui/GuiElectricPump.png"); + drawTexturedModalRect(width + yPos, height + xPos, 176, 52, 16, 60); + } +} diff --git a/src/minecraft/mekanism/common/BlockMachine.java b/src/minecraft/mekanism/common/BlockMachine.java index 19fc1dceb..80a11150a 100644 --- a/src/minecraft/mekanism/common/BlockMachine.java +++ b/src/minecraft/mekanism/common/BlockMachine.java @@ -45,6 +45,7 @@ import cpw.mods.fml.relauncher.SideOnly; * 9: Purification Chamber * 10: Energized Smelter * 11: Teleporter + * 12: Electric Pump * @author AidanBrady * */ @@ -100,6 +101,8 @@ public class BlockMachine extends BlockContainer implements IDismantleable icons[10][1] = register.registerIcon("mekanism:EnergizedSmelterFrontOn"); icons[10][2] = register.registerIcon("mekanism:SteelCasing"); icons[11][0] = register.registerIcon("mekanism:Teleporter"); + icons[12][0] = register.registerIcon("mekanism:ElectricPumpFront"); + icons[12][1] = register.registerIcon("mekanism:ElectricPumpSide"); } @Override @@ -304,6 +307,16 @@ public class BlockMachine extends BlockContainer implements IDismantleable { return icons[11][0]; } + else if(meta == 12) + { + if(side == 1) + { + return icons[12][0]; + } + else { + return icons[12][1]; + } + } return null; } @@ -441,6 +454,16 @@ public class BlockMachine extends BlockContainer implements IDismantleable { return icons[11][0]; } + else if(metadata == 12) + { + if(side == 1) + { + return icons[12][0]; + } + else { + return icons[12][1]; + } + } return null; } @@ -479,6 +502,7 @@ public class BlockMachine extends BlockContainer implements IDismantleable list.add(new ItemStack(i, 1, 9)); list.add(new ItemStack(i, 1, 10)); list.add(new ItemStack(i, 1, 11)); + list.add(new ItemStack(i, 1, 12)); } @Override @@ -709,7 +733,8 @@ public class BlockMachine extends BlockContainer implements IDismantleable METALLURGIC_INFUSER(8, 12, 2000, TileEntityMetallurgicInfuser.class, false), PURIFICATION_CHAMBER(9, 15, 12000, TileEntityPurificationChamber.class, false), ENERGIZED_SMELTER(10, 16, 2000, TileEntityEnergizedSmelter.class, false), - TELEPORTER(11, 13, 5000000, TileEntityTeleporter.class, false); + TELEPORTER(11, 13, 5000000, TileEntityTeleporter.class, false), + ELECTRIC_PUMP(12, 17, 16000, TileEntityElectricPump.class, false); public int meta; public int guiId; diff --git a/src/minecraft/mekanism/common/CommonProxy.java b/src/minecraft/mekanism/common/CommonProxy.java index 901b1e2e4..b534124fc 100644 --- a/src/minecraft/mekanism/common/CommonProxy.java +++ b/src/minecraft/mekanism/common/CommonProxy.java @@ -158,6 +158,8 @@ public class CommonProxy return new ContainerAdvancedElectricMachine(player.inventory, (TileEntityAdvancedElectricMachine)tileEntity); case 16: return new ContainerElectricMachine(player.inventory, (TileEntityElectricMachine)tileEntity); + case 17: + return new ContainerElectricPump(player.inventory, (TileEntityElectricPump)tileEntity); } return null; } diff --git a/src/minecraft/mekanism/common/ContainerElectricPump.java b/src/minecraft/mekanism/common/ContainerElectricPump.java new file mode 100644 index 000000000..350aecb03 --- /dev/null +++ b/src/minecraft/mekanism/common/ContainerElectricPump.java @@ -0,0 +1,101 @@ +package mekanism.common; + +import ic2.api.IElectricItem; +import mekanism.common.SlotEnergy.SlotDischarge; +import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.entity.player.InventoryPlayer; +import net.minecraft.inventory.Container; +import net.minecraft.inventory.Slot; +import net.minecraft.item.Item; +import net.minecraft.item.ItemStack; +import universalelectricity.core.item.IItemElectric; + +public class ContainerElectricPump extends Container +{ + private TileEntityElectricPump tileEntity; + + public ContainerElectricPump(InventoryPlayer inventory, TileEntityElectricPump tentity) + { + tileEntity = tentity; + addSlotToContainer(new Slot(tentity, 0, 28, 20)); + addSlotToContainer(new Slot(tentity, 1, 28, 51)); + addSlotToContainer(new SlotDischarge(tentity, 2, 143, 35)); + int slotX; + + for(slotX = 0; slotX < 3; ++slotX) + { + for(int slotY = 0; slotY < 9; ++slotY) + { + addSlotToContainer(new Slot(inventory, slotY + slotX * 9 + 9, 8 + slotY * 18, 84 + slotX * 18)); + } + } + + for(slotX = 0; slotX < 9; ++slotX) + { + addSlotToContainer(new Slot(inventory, slotX, 8 + slotX * 18, 142)); + } + + tileEntity.openChest(); + } + + @Override + public void onCraftGuiClosed(EntityPlayer entityplayer) + { + super.onCraftGuiClosed(entityplayer); + tileEntity.closeChest(); + } + + @Override + public boolean canInteractWith(EntityPlayer par1EntityPlayer) + { + return tileEntity.isUseableByPlayer(par1EntityPlayer); + } + + @Override + public ItemStack transferStackInSlot(EntityPlayer player, int slotID) + { + ItemStack stack = null; + Slot currentSlot = (Slot)inventorySlots.get(slotID); + + if(currentSlot != null && currentSlot.getHasStack()) + { + ItemStack slotStack = currentSlot.getStack(); + stack = slotStack.copy(); + + if((slotStack.getItem() instanceof IElectricItem && ((IElectricItem)slotStack.getItem()).canProvideEnergy(slotStack)) || (slotStack.getItem() instanceof IItemElectric && ((IItemElectric)slotStack.getItem()).getProvideRequest(slotStack).amperes != 0) || slotStack.itemID == Item.redstone.itemID) + { + if(slotID != 1) + { + if (!mergeItemStack(slotStack, 1, 2, false)) + { + return null; + } + } + else if(slotID == 1) + { + if(!mergeItemStack(slotStack, 2, inventorySlots.size(), false)) + { + return null; + } + } + } + + if(slotStack.stackSize == 0) + { + currentSlot.putStack((ItemStack)null); + } + else { + currentSlot.onSlotChanged(); + } + + if(slotStack.stackSize == stack.stackSize) + { + return null; + } + + currentSlot.onPickupFromSlot(player, slotStack); + } + + return stack; + } +} diff --git a/src/minecraft/mekanism/common/EnergyTransferProtocol.java b/src/minecraft/mekanism/common/EnergyTransferProtocol.java index 4559bc66a..b729cd936 100644 --- a/src/minecraft/mekanism/common/EnergyTransferProtocol.java +++ b/src/minecraft/mekanism/common/EnergyTransferProtocol.java @@ -104,7 +104,7 @@ public class EnergyTransferProtocol { if(((IPowerReceptor)acceptor).getPowerProvider() != null) { - if((((IPowerReceptor)acceptor).powerRequest(acceptorDirections.get(acceptor).getOpposite())*Mekanism.FROM_BC) > 0) + if((((IPowerReceptor)acceptor).powerRequest(ForgeDirection.getOrientation(Arrays.asList(acceptors).indexOf(acceptor)).getOpposite())*Mekanism.FROM_BC) > 0) { availableAcceptors.add(acceptor); acceptorDirections.put(acceptor, ForgeDirection.getOrientation(Arrays.asList(acceptors).indexOf(acceptor))); diff --git a/src/minecraft/mekanism/common/ItemBlockMachine.java b/src/minecraft/mekanism/common/ItemBlockMachine.java index 27096601d..1c73fd435 100644 --- a/src/minecraft/mekanism/common/ItemBlockMachine.java +++ b/src/minecraft/mekanism/common/ItemBlockMachine.java @@ -39,6 +39,7 @@ import net.minecraft.world.World; * 9: Purification Chamber * 10: Energized Smelter * 11: Teleporter + * 12: Electric Pump * @author AidanBrady * */ @@ -103,6 +104,9 @@ public class ItemBlockMachine extends ItemBlock implements IItemElectric, ICusto case 11: name = "Teleporter"; break; + case 12: + name = "ElectricPump"; + break; default: name = "Unknown"; break; diff --git a/src/minecraft/mekanism/common/ItemStorageTank.java b/src/minecraft/mekanism/common/ItemStorageTank.java index d81560545..7ceb8f63f 100644 --- a/src/minecraft/mekanism/common/ItemStorageTank.java +++ b/src/minecraft/mekanism/common/ItemStorageTank.java @@ -68,7 +68,7 @@ public class ItemStorageTank extends ItemMekanism implements IStorageTank { ItemStack itemstack = (ItemStack)data[0]; - if(getGasType(itemstack) == type) + if(getGasType(itemstack) == type || type == EnumGas.NONE) { if(itemstack.stackTagCompound == null) { @@ -157,7 +157,7 @@ public class ItemStorageTank extends ItemMekanism implements IStorageTank ItemStack itemStack = (ItemStack)data[0]; IStorageTank tank = (IStorageTank)itemStack.getItem(); - if(getGasType(itemStack) == EnumGas.NONE || getGasType(itemStack) == type) + if(getGasType(itemStack) == EnumGas.NONE || getGasType(itemStack) == type || type == EnumGas.NONE) { return MAX_GAS; } diff --git a/src/minecraft/mekanism/common/Mekanism.java b/src/minecraft/mekanism/common/Mekanism.java index a30524ea9..48b0a6f86 100644 --- a/src/minecraft/mekanism/common/Mekanism.java +++ b/src/minecraft/mekanism/common/Mekanism.java @@ -453,6 +453,7 @@ public class Mekanism LanguageRegistry.instance().addStringLocalization("tile.MachineBlock.PurificationChamber.name", "Purification Chamber"); LanguageRegistry.instance().addStringLocalization("tile.MachineBlock.EnergizedSmelter.name", "Energized Smelter"); LanguageRegistry.instance().addStringLocalization("tile.MachineBlock.Teleporter.name", "Teleporter"); + LanguageRegistry.instance().addStringLocalization("tile.MachineBlock.ElectricPump.name", "Electric Pump"); //Localization for OreBlock LanguageRegistry.instance().addStringLocalization("tile.OreBlock.OsmiumOre.name", "Osmium Ore"); @@ -922,6 +923,7 @@ public class Mekanism GameRegistry.registerTileEntity(TileEntityTeleporter.class, "MekanismTeleporter"); GameRegistry.registerTileEntity(TileEntityPurificationChamber.class, "PurificationChamber"); GameRegistry.registerTileEntity(TileEntityEnergizedSmelter.class, "EnergizedSmelter"); + GameRegistry.registerTileEntity(TileEntityElectricPump.class, "ElectricPump"); //Load tile entities that have special renderers. proxy.registerSpecialTileEntities(); diff --git a/src/minecraft/mekanism/common/TileEntityAdvancedElectricMachine.java b/src/minecraft/mekanism/common/TileEntityAdvancedElectricMachine.java index 375a75286..9b9650739 100644 --- a/src/minecraft/mekanism/common/TileEntityAdvancedElectricMachine.java +++ b/src/minecraft/mekanism/common/TileEntityAdvancedElectricMachine.java @@ -48,12 +48,12 @@ public abstract class TileEntityAdvancedElectricMachine extends TileEntityBasicM { super(soundPath, name, path, perTick, ticksRequired, maxEnergy); - sideOutputs.add(new SideData(EnumColor.GREY, 0, 0)); - sideOutputs.add(new SideData(EnumColor.DARK_RED, 0, 1)); - sideOutputs.add(new SideData(EnumColor.PURPLE, 1, 1)); - sideOutputs.add(new SideData(EnumColor.DARK_BLUE, 2, 1)); - sideOutputs.add(new SideData(EnumColor.DARK_GREEN, 3, 1)); - sideOutputs.add(new SideData(EnumColor.ORANGE, 4, 1)); + sideOutputs.add(new SideData(EnumColor.GREY, 0, 0, new int[0])); + sideOutputs.add(new SideData(EnumColor.DARK_RED, 0, 1, new int[] {0})); + sideOutputs.add(new SideData(EnumColor.PURPLE, 1, 1, new int[] {1})); + sideOutputs.add(new SideData(EnumColor.DARK_BLUE, 2, 1, new int[] {2})); + sideOutputs.add(new SideData(EnumColor.DARK_GREEN, 3, 1, new int[] {3})); + sideOutputs.add(new SideData(EnumColor.ORANGE, 4, 1, new int[] {4})); sideConfig = new byte[] {2, 1, 0, 4, 5, 3}; @@ -231,7 +231,7 @@ public abstract class TileEntityAdvancedElectricMachine extends TileEntityBasicM } else if(slotID == 0) { - return RecipeHandler.getOutput(inventory[0], false, getRecipes()) != null; + return RecipeHandler.getOutput(itemstack, false, getRecipes()) != null; } else if(slotID == 3) { @@ -345,6 +345,24 @@ public abstract class TileEntityAdvancedElectricMachine extends TileEntityBasicM { return secondaryEnergyStored*i / MAX_SECONDARY_ENERGY; } + + @Override + public boolean func_102008_b(int slotID, ItemStack itemstack, int side) + { + if(slotID == 3) + { + return (itemstack.getItem() instanceof IItemElectric && ((IItemElectric)itemstack.getItem()).getProvideRequest(itemstack).getWatts() == 0) || + (itemstack.getItem() instanceof IElectricItem && ((IElectricItem)itemstack.getItem()).canProvideEnergy(itemstack) && + (!(itemstack.getItem() instanceof IItemElectric) || + ((IItemElectric)itemstack.getItem()).getProvideRequest(itemstack).getWatts() == 0)); + } + else if(slotID == 2) + { + return true; + } + + return false; + } @Override public String[] getMethodNames() diff --git a/src/minecraft/mekanism/common/TileEntityAdvancedFactory.java b/src/minecraft/mekanism/common/TileEntityAdvancedFactory.java index 096ab0892..d98478493 100644 --- a/src/minecraft/mekanism/common/TileEntityAdvancedFactory.java +++ b/src/minecraft/mekanism/common/TileEntityAdvancedFactory.java @@ -10,11 +10,11 @@ public class TileEntityAdvancedFactory extends TileEntityFactory { super(FactoryTier.ADVANCED); - sideOutputs.add(new SideData(EnumColor.GREY, 0, 0)); - sideOutputs.add(new SideData(EnumColor.ORANGE, 0, 1)); - sideOutputs.add(new SideData(EnumColor.DARK_GREEN, 1, 1)); - sideOutputs.add(new SideData(EnumColor.DARK_RED, 2, 5)); - sideOutputs.add(new SideData(EnumColor.DARK_BLUE, 7, 5)); + sideOutputs.add(new SideData(EnumColor.GREY, 0, 0, new int[0])); + sideOutputs.add(new SideData(EnumColor.ORANGE, 0, 1, new int[] {0})); + sideOutputs.add(new SideData(EnumColor.DARK_GREEN, 1, 1, new int[] {1})); + sideOutputs.add(new SideData(EnumColor.DARK_RED, 2, 5, new int[] {2, 3, 4, 5, 6})); + sideOutputs.add(new SideData(EnumColor.DARK_BLUE, 7, 5, new int[] {7, 8, 9, 10, 11})); sideConfig = new byte[] {4, 3, 0, 0, 2, 1}; } diff --git a/src/minecraft/mekanism/common/TileEntityBasicMachine.java b/src/minecraft/mekanism/common/TileEntityBasicMachine.java index b8edc5ae4..0e52d1008 100644 --- a/src/minecraft/mekanism/common/TileEntityBasicMachine.java +++ b/src/minecraft/mekanism/common/TileEntityBasicMachine.java @@ -372,6 +372,12 @@ public abstract class TileEntityBasicMachine extends TileEntityElectricBlock imp @Override public void detach(IComputerAccess computer) {} + @Override + public int[] getSizeInventorySide(int side) + { + return sideOutputs.get(sideConfig[MekanismUtils.getBaseOrientation(side, facing)]).availableSlots; + } + @Override public int powerRequest(ForgeDirection side) { diff --git a/src/minecraft/mekanism/common/TileEntityContainerBlock.java b/src/minecraft/mekanism/common/TileEntityContainerBlock.java index b30baca4c..e83ba41b4 100644 --- a/src/minecraft/mekanism/common/TileEntityContainerBlock.java +++ b/src/minecraft/mekanism/common/TileEntityContainerBlock.java @@ -2,13 +2,13 @@ package mekanism.common; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.inventory.IInventory; +import net.minecraft.inventory.ISidedInventory; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.nbt.NBTTagList; import net.minecraftforge.common.ForgeDirection; -import net.minecraftforge.common.ISidedInventory; -public abstract class TileEntityContainerBlock extends TileEntityBasicBlock implements ISidedInventory, IInventory, ISustainedInventory +public abstract class TileEntityContainerBlock extends TileEntityBasicBlock implements net.minecraftforge.common.ISidedInventory, ISidedInventory, IInventory, ISustainedInventory { /** The inventory slot itemstacks used by this block. */ public ItemStack[] inventory; @@ -122,14 +122,13 @@ public abstract class TileEntityContainerBlock extends TileEntityBasicBlock impl @Override public ItemStack getStackInSlotOnClosing(int slotID) { - if (inventory[slotID] != null) + if(inventory[slotID] != null) { ItemStack var2 = inventory[slotID]; inventory[slotID] = null; return var2; } - else - { + else { return null; } } @@ -139,7 +138,7 @@ public abstract class TileEntityContainerBlock extends TileEntityBasicBlock impl { inventory[slotID] = itemstack; - if (itemstack != null && itemstack.stackSize > getInventoryStackLimit()) + if(itemstack != null && itemstack.stackSize > getInventoryStackLimit()) { itemstack.stackSize = getInventoryStackLimit(); } @@ -186,6 +185,24 @@ public abstract class TileEntityContainerBlock extends TileEntityBasicBlock impl { return true; } + + @Override + public boolean func_102007_a(int slotID, ItemStack itemstack, int side) + { + return isStackValidForSlot(slotID, itemstack); + } + + @Override + public int[] getSizeInventorySide(int side) + { + return new int[0]; + } + + @Override + public boolean func_102008_b(int slotID, ItemStack itemstack, int side) + { + return true; + } @Override public void setInventory(NBTTagList nbtTags, Object... data) diff --git a/src/minecraft/mekanism/common/TileEntityElectricMachine.java b/src/minecraft/mekanism/common/TileEntityElectricMachine.java index 91bcc4a0e..2b60c2618 100644 --- a/src/minecraft/mekanism/common/TileEntityElectricMachine.java +++ b/src/minecraft/mekanism/common/TileEntityElectricMachine.java @@ -28,11 +28,11 @@ public abstract class TileEntityElectricMachine extends TileEntityBasicMachine { super(soundPath, name, path, perTick, ticksRequired, maxEnergy); - sideOutputs.add(new SideData(EnumColor.GREY, 0, 0)); - sideOutputs.add(new SideData(EnumColor.DARK_RED, 0, 1)); - sideOutputs.add(new SideData(EnumColor.DARK_GREEN, 1, 1)); - sideOutputs.add(new SideData(EnumColor.DARK_BLUE, 2, 1)); - sideOutputs.add(new SideData(EnumColor.ORANGE, 3, 1)); + sideOutputs.add(new SideData(EnumColor.GREY, 0, 0, new int[0])); + sideOutputs.add(new SideData(EnumColor.DARK_RED, 0, 1, new int[] {0})); + sideOutputs.add(new SideData(EnumColor.DARK_GREEN, 1, 1, new int[] {1})); + sideOutputs.add(new SideData(EnumColor.DARK_BLUE, 2, 1, new int[] {2})); + sideOutputs.add(new SideData(EnumColor.ORANGE, 3, 1, new int[] {3})); sideConfig = new byte[] {2, 1, 0, 0, 4, 3}; @@ -169,7 +169,7 @@ public abstract class TileEntityElectricMachine extends TileEntityBasicMachine } else if(slotID == 0) { - return RecipeHandler.getOutput(inventory[0], false, getRecipes()) != null; + return RecipeHandler.getOutput(itemstack, false, getRecipes()) != null; } else if(slotID == 1) { @@ -227,6 +227,24 @@ public abstract class TileEntityElectricMachine extends TileEntityBasicMachine return inventory[2].stackSize + itemstack.stackSize <= inventory[2].getMaxStackSize(); } } + + @Override + public boolean func_102008_b(int slotID, ItemStack itemstack, int side) + { + if(slotID == 1) + { + return (itemstack.getItem() instanceof IItemElectric && ((IItemElectric)itemstack.getItem()).getProvideRequest(itemstack).getWatts() == 0) || + (itemstack.getItem() instanceof IElectricItem && ((IElectricItem)itemstack.getItem()).canProvideEnergy(itemstack) && + (!(itemstack.getItem() instanceof IItemElectric) || + ((IItemElectric)itemstack.getItem()).getProvideRequest(itemstack).getWatts() == 0)); + } + else if(slotID == 2) + { + return true; + } + + return false; + } @Override public String[] getMethodNames() diff --git a/src/minecraft/mekanism/common/TileEntityElectricPump.java b/src/minecraft/mekanism/common/TileEntityElectricPump.java new file mode 100644 index 000000000..2e9a175eb --- /dev/null +++ b/src/minecraft/mekanism/common/TileEntityElectricPump.java @@ -0,0 +1,166 @@ +package mekanism.common; + +import java.util.ArrayList; + +import com.google.common.io.ByteArrayDataInput; + +import ic2.api.ElectricItem; +import ic2.api.IElectricItem; +import universalelectricity.core.item.ElectricItemHelper; +import mekanism.api.InfusionType; +import net.minecraft.block.Block; +import net.minecraft.item.Item; +import net.minecraft.item.ItemStack; +import net.minecraft.nbt.NBTTagCompound; +import net.minecraftforge.liquids.LiquidContainerRegistry; +import net.minecraftforge.liquids.LiquidStack; +import net.minecraftforge.liquids.LiquidTank; + +public class TileEntityElectricPump extends TileEntityElectricBlock +{ + public LiquidTank liquidTank; + + public TileEntityElectricPump() + { + super("Electric Pump", 16000); + liquidTank = new LiquidTank(16000); + inventory = new ItemStack[3]; + liquidTank.setLiquid(new LiquidStack(Block.waterStill.blockID, 8000, 0)); + } + + @Override + public void onUpdate() + { + if(inventory[2] != null) + { + if(electricityStored < MAX_ELECTRICITY) + { + setJoules(getJoules() + ElectricItemHelper.dechargeItem(inventory[2], getMaxJoules() - getJoules(), getVoltage())); + + if(Mekanism.hooks.IC2Loaded && inventory[2].getItem() instanceof IElectricItem) + { + IElectricItem item = (IElectricItem)inventory[2].getItem(); + if(item.canProvideEnergy(inventory[2])) + { + double gain = ElectricItem.discharge(inventory[2], (int)((MAX_ELECTRICITY - electricityStored)*Mekanism.TO_IC2), 3, false, false)*Mekanism.FROM_IC2; + setJoules(electricityStored + gain); + } + } + } + if(inventory[2].itemID == Item.redstone.itemID && electricityStored+1000 <= MAX_ELECTRICITY) + { + setJoules(electricityStored + 1000); + inventory[2].stackSize--; + + if(inventory[2].stackSize <= 0) + { + inventory[2] = null; + } + } + } + + if(inventory[0] != null) + { + if(liquidTank.getLiquid() != null && liquidTank.getLiquid().amount >= 1000) + { + if(LiquidContainerRegistry.isEmptyContainer(inventory[0])) + { + ItemStack tempStack = LiquidContainerRegistry.fillLiquidContainer(liquidTank.getLiquid(), inventory[0]); + + if(tempStack != null) + { + if(inventory[1] == null) + { + liquidTank.drain(1000, true); + + inventory[1] = tempStack; + inventory[0].stackSize--; + + if(inventory[0].stackSize <= 0) + { + inventory[0] = null; + } + } + else if(tempStack.isItemEqual(inventory[1]) && tempStack.getMaxStackSize() > inventory[1].stackSize) + { + liquidTank.drain(1000, true); + + inventory[1].stackSize++; + inventory[0].stackSize--; + + if(inventory[0].stackSize <= 0) + { + inventory[0] = null; + } + } + } + } + } + } + } + + @Override + public void handlePacketData(ByteArrayDataInput dataStream) + { + super.handlePacketData(dataStream); + + try { + int amount = dataStream.readInt(); + int itemID = dataStream.readInt(); + int itemMeta = dataStream.readInt(); + + liquidTank.setLiquid(new LiquidStack(itemID, amount, itemMeta)); + } catch(Exception e) {} + + MekanismUtils.updateBlock(worldObj, xCoord, yCoord, zCoord); + } + + @Override + public ArrayList getNetworkedData(ArrayList data) + { + super.getNetworkedData(data); + + if(liquidTank.getLiquid() != null) + { + data.add(liquidTank.getLiquid().amount); + data.add(liquidTank.getLiquid().itemID); + data.add(liquidTank.getLiquid().itemMeta); + } + + return data; + } + + public int getScaledEnergyLevel(int i) + { + return (int)(electricityStored*i / MAX_ELECTRICITY); + } + + public int getScaledLiquidLevel(int i) + { + return liquidTank.getLiquid() != null ? liquidTank.getLiquid().amount*i / 16000 : 0; + } + + @Override + public void writeToNBT(NBTTagCompound nbtTags) + { + super.writeToNBT(nbtTags); + + if(liquidTank.getLiquid() != null) + { + nbtTags.setTag("liquidTank", liquidTank.getLiquid().writeToNBT(new NBTTagCompound())); + } + } + + @Override + public void readFromNBT(NBTTagCompound nbtTags) + { + super.readFromNBT(nbtTags); + + if(nbtTags.hasKey("liquidTank")) + { + //liquidTank.setLiquid(LiquidStack.loadLiquidStackFromNBT(nbtTags)); + } + + liquidTank.setLiquid(new LiquidStack(Block.waterStill.blockID, 8000, 0)); + } +} diff --git a/src/minecraft/mekanism/common/TileEntityEliteFactory.java b/src/minecraft/mekanism/common/TileEntityEliteFactory.java index 36d8ec06d..a413a5347 100644 --- a/src/minecraft/mekanism/common/TileEntityEliteFactory.java +++ b/src/minecraft/mekanism/common/TileEntityEliteFactory.java @@ -10,11 +10,11 @@ public class TileEntityEliteFactory extends TileEntityFactory { super(FactoryTier.ELITE); - sideOutputs.add(new SideData(EnumColor.GREY, 0, 0)); - sideOutputs.add(new SideData(EnumColor.ORANGE, 0, 1)); - sideOutputs.add(new SideData(EnumColor.DARK_GREEN, 1, 1)); - sideOutputs.add(new SideData(EnumColor.DARK_RED, 2, 7)); - sideOutputs.add(new SideData(EnumColor.DARK_BLUE, 9, 7)); + sideOutputs.add(new SideData(EnumColor.GREY, 0, 0, new int[0])); + sideOutputs.add(new SideData(EnumColor.ORANGE, 0, 1, new int[] {0})); + sideOutputs.add(new SideData(EnumColor.DARK_GREEN, 1, 1, new int[] {1})); + sideOutputs.add(new SideData(EnumColor.DARK_RED, 2, 7, new int[] {2, 3, 4, 5, 6, 7, 8})); + sideOutputs.add(new SideData(EnumColor.DARK_BLUE, 9, 7, new int[] {9, 10, 11, 12, 13, 14, 15})); sideConfig = new byte[] {4, 3, 0, 0, 2, 1}; } diff --git a/src/minecraft/mekanism/common/TileEntityEnergyCube.java b/src/minecraft/mekanism/common/TileEntityEnergyCube.java index 9f99009ad..329d43b83 100644 --- a/src/minecraft/mekanism/common/TileEntityEnergyCube.java +++ b/src/minecraft/mekanism/common/TileEntityEnergyCube.java @@ -300,6 +300,32 @@ public class TileEntityEnergyCube extends TileEntityElectricBlock implements IEn return tier.MAX_ELECTRICITY; } + @Override + public int[] getSizeInventorySide(int side) + { + return side == 1 ? new int[] {0} : new int[] {1}; + } + + @Override + public boolean func_102008_b(int slotID, ItemStack itemstack, int side) + { + if(slotID == 1) + { + return (itemstack.getItem() instanceof IItemElectric && ((IItemElectric)itemstack.getItem()).getProvideRequest(itemstack).getWatts() == 0) || + (itemstack.getItem() instanceof IElectricItem && ((IElectricItem)itemstack.getItem()).canProvideEnergy(itemstack) && + (!(itemstack.getItem() instanceof IItemElectric) || + ((IItemElectric)itemstack.getItem()).getProvideRequest(itemstack).getWatts() == 0)); + } + else if(slotID == 0) + { + return (itemstack.getItem() instanceof IItemElectric && ((IItemElectric)itemstack.getItem()).getReceiveRequest(itemstack).getWatts() == 0) || + (itemstack.getItem() instanceof IElectricItem && (!(itemstack.getItem() instanceof IItemElectric) || + ((IItemElectric)itemstack.getItem()).getReceiveRequest(itemstack).getWatts() == 0)); + } + + return false; + } + @Override public int getStartInventorySide(ForgeDirection side) { diff --git a/src/minecraft/mekanism/common/TileEntityFactory.java b/src/minecraft/mekanism/common/TileEntityFactory.java index e387e0eb1..976e8027b 100644 --- a/src/minecraft/mekanism/common/TileEntityFactory.java +++ b/src/minecraft/mekanism/common/TileEntityFactory.java @@ -81,11 +81,11 @@ public class TileEntityFactory extends TileEntityElectricBlock implements IEnerg { this(FactoryTier.BASIC); - sideOutputs.add(new SideData(EnumColor.GREY, 0, 0)); - sideOutputs.add(new SideData(EnumColor.ORANGE, 0, 1)); - sideOutputs.add(new SideData(EnumColor.DARK_GREEN, 1, 1)); - sideOutputs.add(new SideData(EnumColor.DARK_RED, 2, 3)); - sideOutputs.add(new SideData(EnumColor.DARK_BLUE, 5, 3)); + sideOutputs.add(new SideData(EnumColor.GREY, 0, 0, new int[0])); + sideOutputs.add(new SideData(EnumColor.ORANGE, 0, 1, new int[] {0})); + sideOutputs.add(new SideData(EnumColor.DARK_GREEN, 1, 1, new int[] {1})); + sideOutputs.add(new SideData(EnumColor.DARK_RED, 2, 3, new int[] {2, 3, 4})); + sideOutputs.add(new SideData(EnumColor.DARK_BLUE, 5, 3, new int[] {5, 6, 7})); sideConfig = new byte[] {4, 3, 0, 0, 2, 1}; } @@ -253,6 +253,32 @@ public class TileEntityFactory extends TileEntityElectricBlock implements IEnerg } } + @Override + public boolean func_102008_b(int slotID, ItemStack itemstack, int side) + { + if(slotID == 1) + { + return (itemstack.getItem() instanceof IItemElectric && ((IItemElectric)itemstack.getItem()).getProvideRequest(itemstack).getWatts() == 0) || + (itemstack.getItem() instanceof IElectricItem && ((IElectricItem)itemstack.getItem()).canProvideEnergy(itemstack) && + (!(itemstack.getItem() instanceof IItemElectric) || + ((IItemElectric)itemstack.getItem()).getProvideRequest(itemstack).getWatts() == 0)); + } + else if(tier == FactoryTier.BASIC && slotID >= 5 && slotID <= 7) + { + return true; + } + else if(tier == FactoryTier.ADVANCED && slotID >= 7 && slotID <= 11) + { + return true; + } + else if(tier == FactoryTier.ELITE && slotID >= 9 && slotID <= 15) + { + return true; + } + + return false; + } + @Override public boolean isStackValidForSlot(int slotID, ItemStack itemstack) { @@ -264,7 +290,7 @@ public class TileEntityFactory extends TileEntityElectricBlock implements IEnerg } else if(slotID >= 2 && slotID <= 4) { - return RecipeType.values()[recipeType].getCopiedOutput(inventory[slotID], false) != null; + return RecipeType.values()[recipeType].getCopiedOutput(itemstack, false) != null; } } else if(tier == FactoryTier.ADVANCED) @@ -275,7 +301,7 @@ public class TileEntityFactory extends TileEntityElectricBlock implements IEnerg } else if(slotID >= 2 && slotID <= 6) { - return RecipeType.values()[recipeType].getCopiedOutput(inventory[slotID], false) != null; + return RecipeType.values()[recipeType].getCopiedOutput(itemstack, false) != null; } } else if(tier == FactoryTier.ELITE) @@ -286,7 +312,7 @@ public class TileEntityFactory extends TileEntityElectricBlock implements IEnerg } else if(slotID >= 2 && slotID <= 8) { - return RecipeType.values()[recipeType].getCopiedOutput(inventory[slotID], false) != null; + return RecipeType.values()[recipeType].getCopiedOutput(itemstack, false) != null; } } @@ -684,6 +710,12 @@ public class TileEntityFactory extends TileEntityElectricBlock implements IEnerg return (int)Math.min(((MekanismUtils.getEnergy(energyMultiplier, MAX_ELECTRICITY)-electricityStored)*Mekanism.TO_BC), 100); } + @Override + public int[] getSizeInventorySide(int side) + { + return sideOutputs.get(sideConfig[MekanismUtils.getBaseOrientation(side, facing)]).availableSlots; + } + @Override public ArrayList getSideData() { diff --git a/src/minecraft/mekanism/common/TileEntityGasTank.java b/src/minecraft/mekanism/common/TileEntityGasTank.java index 78af0f771..47dd91067 100644 --- a/src/minecraft/mekanism/common/TileEntityGasTank.java +++ b/src/minecraft/mekanism/common/TileEntityGasTank.java @@ -139,6 +139,22 @@ public class TileEntityGasTank extends TileEntityContainerBlock implements IGasS } } + @Override + public boolean func_102008_b(int slotID, ItemStack itemstack, int side) + { + if(slotID == 1) + { + return (itemstack.getItem() instanceof IStorageTank && ((IStorageTank)itemstack.getItem()).getGas(EnumGas.NONE, itemstack) == 0); + } + else if(slotID == 0) + { + return (itemstack.getItem() instanceof IStorageTank && + ((IStorageTank)itemstack.getItem()).getGas(EnumGas.NONE, itemstack) == ((IStorageTank)itemstack.getItem()).getMaxGas(EnumGas.NONE, itemstack)); + } + + return false; + } + @Override public boolean isStackValidForSlot(int slotID, ItemStack itemstack) { @@ -153,6 +169,12 @@ public class TileEntityGasTank extends TileEntityContainerBlock implements IGasS return true; } + @Override + public int[] getSizeInventorySide(int side) + { + return side == 1 ? new int[] {0} : new int[] {1}; + } + @Override public int getStartInventorySide(ForgeDirection side) { diff --git a/src/minecraft/mekanism/common/TileEntityMetallurgicInfuser.java b/src/minecraft/mekanism/common/TileEntityMetallurgicInfuser.java index aff75b2f3..03457d58f 100644 --- a/src/minecraft/mekanism/common/TileEntityMetallurgicInfuser.java +++ b/src/minecraft/mekanism/common/TileEntityMetallurgicInfuser.java @@ -88,12 +88,12 @@ public class TileEntityMetallurgicInfuser extends TileEntityElectricBlock implem { super("Metallurgic Infuser", 2000); - sideOutputs.add(new SideData(EnumColor.GREY, 0, 0)); - sideOutputs.add(new SideData(EnumColor.ORANGE, 0, 1)); - sideOutputs.add(new SideData(EnumColor.PURPLE, 1, 1)); - sideOutputs.add(new SideData(EnumColor.DARK_RED, 2, 1)); - sideOutputs.add(new SideData(EnumColor.DARK_BLUE, 3, 1)); - sideOutputs.add(new SideData(EnumColor.DARK_GREEN, 4, 1)); + sideOutputs.add(new SideData(EnumColor.GREY, 0, 0, new int[0])); + sideOutputs.add(new SideData(EnumColor.ORANGE, 0, 1, new int[] {0})); + sideOutputs.add(new SideData(EnumColor.PURPLE, 1, 1, new int[] {1})); + sideOutputs.add(new SideData(EnumColor.DARK_RED, 2, 1, new int[] {2})); + sideOutputs.add(new SideData(EnumColor.DARK_BLUE, 3, 1, new int[] {3})); + sideOutputs.add(new SideData(EnumColor.DARK_GREEN, 4, 1, new int[] {4})); sideConfig = new byte[] {0, 1, 0, 5, 3, 4}; @@ -292,6 +292,24 @@ public class TileEntityMetallurgicInfuser extends TileEntityElectricBlock implem } } + @Override + public boolean func_102008_b(int slotID, ItemStack itemstack, int side) + { + if(slotID == 4) + { + return (itemstack.getItem() instanceof IItemElectric && ((IItemElectric)itemstack.getItem()).getProvideRequest(itemstack).getWatts() == 0) || + (itemstack.getItem() instanceof IElectricItem && ((IElectricItem)itemstack.getItem()).canProvideEnergy(itemstack) && + (!(itemstack.getItem() instanceof IItemElectric) || + ((IItemElectric)itemstack.getItem()).getProvideRequest(itemstack).getWatts() == 0)); + } + else if(slotID == 3) + { + return true; + } + + return false; + } + @Override public boolean isStackValidForSlot(int slotID, ItemStack itemstack) { @@ -584,6 +602,12 @@ public class TileEntityMetallurgicInfuser extends TileEntityElectricBlock implem @Override public void detach(IComputerAccess computer) {} + + @Override + public int[] getSizeInventorySide(int side) + { + return sideOutputs.get(sideConfig[MekanismUtils.getBaseOrientation(side, facing)]).availableSlots; + } @Override public double getMaxJoules() diff --git a/src/minecraft/mekanism/common/TileEntityTeleporter.java b/src/minecraft/mekanism/common/TileEntityTeleporter.java index 1c99c1760..0dc3b90ef 100644 --- a/src/minecraft/mekanism/common/TileEntityTeleporter.java +++ b/src/minecraft/mekanism/common/TileEntityTeleporter.java @@ -120,6 +120,12 @@ public class TileEntityTeleporter extends TileEntityElectricBlock implements IEn } } + @Override + public int[] getSizeInventorySide(int side) + { + return new int[] {0}; + } + @Override public boolean isStackValidForSlot(int slotID, ItemStack itemstack) { @@ -233,6 +239,12 @@ public class TileEntityTeleporter extends TileEntityElectricBlock implements IEn } } } + + @Override + public int getSizeInventorySide(ForgeDirection side) + { + return 1; + } @Override public void invalidate() @@ -380,6 +392,14 @@ public class TileEntityTeleporter extends TileEntityElectricBlock implements IEn return true; } + @Override + public boolean func_102008_b(int slotID, ItemStack itemstack, int side) + { + return (itemstack.getItem() instanceof IItemElectric && ((IItemElectric)itemstack.getItem()).getProvideRequest(itemstack).getWatts() == 0) || + (itemstack.getItem() instanceof IElectricItem && (!(itemstack.getItem() instanceof IItemElectric) || + ((IItemElectric)itemstack.getItem()).getProvideRequest(itemstack).getWatts() == 0)); + } + @Override public double transferEnergyToAcceptor(double amount) { diff --git a/src/minecraft/mekanism/generators/common/TileEntityBioGenerator.java b/src/minecraft/mekanism/generators/common/TileEntityBioGenerator.java index ab8d1b3c8..6d53607c2 100644 --- a/src/minecraft/mekanism/generators/common/TileEntityBioGenerator.java +++ b/src/minecraft/mekanism/generators/common/TileEntityBioGenerator.java @@ -170,6 +170,23 @@ public class TileEntityBioGenerator extends TileEntityGenerator implements ITank } } + @Override + public boolean func_102008_b(int slotID, ItemStack itemstack, int side) + { + if(slotID == 1) + { + return (itemstack.getItem() instanceof IItemElectric && ((IItemElectric)itemstack.getItem()).getReceiveRequest(itemstack).getWatts() == 0) || + (itemstack.getItem() instanceof IElectricItem && (!(itemstack.getItem() instanceof IItemElectric) || + ((IItemElectric)itemstack.getItem()).getReceiveRequest(itemstack).getWatts() == 0)); + } + else if(slotID == 0) + { + return LiquidContainerRegistry.isEmptyContainer(itemstack); + } + + return false; + } + @Override public boolean isStackValidForSlot(int slotID, ItemStack itemstack) { @@ -229,6 +246,12 @@ public class TileEntityBioGenerator extends TileEntityGenerator implements ITank return bioFuelSlot.liquidStored*i / bioFuelSlot.MAX_LIQUID; } + @Override + public int[] getSizeInventorySide(int side) + { + return ForgeDirection.getOrientation(side) == MekanismUtils.getRight(facing) ? new int[] {1} : new int[] {0}; + } + @Override public int getStartInventorySide(ForgeDirection side) { diff --git a/src/minecraft/mekanism/generators/common/TileEntityElectrolyticSeparator.java b/src/minecraft/mekanism/generators/common/TileEntityElectrolyticSeparator.java index 659709912..9e33bc0f4 100644 --- a/src/minecraft/mekanism/generators/common/TileEntityElectrolyticSeparator.java +++ b/src/minecraft/mekanism/generators/common/TileEntityElectrolyticSeparator.java @@ -247,6 +247,32 @@ public class TileEntityElectrolyticSeparator extends TileEntityElectricBlock imp } } + @Override + public boolean func_102008_b(int slotID, ItemStack itemstack, int side) + { + if(slotID == 3) + { + return (itemstack.getItem() instanceof IItemElectric && ((IItemElectric)itemstack.getItem()).getProvideRequest(itemstack).getWatts() > 0) || + (itemstack.getItem() instanceof IElectricItem && ((IElectricItem)itemstack.getItem()).canProvideEnergy(itemstack) && + (!(itemstack.getItem() instanceof IItemElectric) || + ((IItemElectric)itemstack.getItem()).getProvideRequest(itemstack).getWatts() > 0)); + } + else if(slotID == 0) + { + return LiquidContainerRegistry.isEmptyContainer(itemstack); + } + else if(slotID == 1) + { + return itemstack.getItem() instanceof IStorageTank && ((IStorageTank)itemstack.getItem()).getGas(EnumGas.HYDROGEN, itemstack) == ((IStorageTank)itemstack.getItem()).getMaxGas(EnumGas.HYDROGEN, itemstack); + } + else if(slotID == 2) + { + return itemstack.getItem() instanceof IStorageTank && ((IStorageTank)itemstack.getItem()).getGas(EnumGas.OXYGEN, itemstack) == ((IStorageTank)itemstack.getItem()).getMaxGas(EnumGas.HYDROGEN, itemstack); + } + + return false; + } + @Override public boolean isStackValidForSlot(int slotID, ItemStack itemstack) { @@ -271,6 +297,21 @@ public class TileEntityElectrolyticSeparator extends TileEntityElectricBlock imp return true; } + @Override + public int[] getSizeInventorySide(int side) + { + if(ForgeDirection.getOrientation(side) == MekanismUtils.getLeft(facing)) + { + return new int[] {3}; + } + else if(side == facing || ForgeDirection.getOrientation(side) == ForgeDirection.getOrientation(facing).getOpposite()) + { + return new int[] {1, 2}; + } + + return new int[] {0}; + } + @Override public int getStartInventorySide(ForgeDirection side) { diff --git a/src/minecraft/mekanism/generators/common/TileEntityHeatGenerator.java b/src/minecraft/mekanism/generators/common/TileEntityHeatGenerator.java index 4d74a2d3c..e444de1d3 100644 --- a/src/minecraft/mekanism/generators/common/TileEntityHeatGenerator.java +++ b/src/minecraft/mekanism/generators/common/TileEntityHeatGenerator.java @@ -178,6 +178,23 @@ public class TileEntityHeatGenerator extends TileEntityGenerator implements ITan nbtTags.setInteger("fuelStored", fuelSlot.liquidStored); } + @Override + public boolean func_102008_b(int slotID, ItemStack itemstack, int side) + { + if(slotID == 1) + { + return (itemstack.getItem() instanceof IItemElectric && ((IItemElectric)itemstack.getItem()).getReceiveRequest(itemstack).getWatts() == 0) || + (itemstack.getItem() instanceof IElectricItem && (!(itemstack.getItem() instanceof IItemElectric) || + ((IItemElectric)itemstack.getItem()).getReceiveRequest(itemstack).getWatts() == 0)); + } + else if(slotID == 0) + { + return LiquidContainerRegistry.isEmptyContainer(itemstack); + } + + return false; + } + @Override public int getEnvironmentBoost() { @@ -209,6 +226,12 @@ public class TileEntityHeatGenerator extends TileEntityGenerator implements ITan return TileEntityFurnace.getItemBurnTime(itemstack); } + @Override + public int[] getSizeInventorySide(int side) + { + return ForgeDirection.getOrientation(side) == MekanismUtils.getRight(facing) ? new int[] {1} : new int[] {0}; + } + @Override public int getStartInventorySide(ForgeDirection side) { diff --git a/src/minecraft/mekanism/generators/common/TileEntityHydrogenGenerator.java b/src/minecraft/mekanism/generators/common/TileEntityHydrogenGenerator.java index 126ad13f6..4adb7dbfe 100644 --- a/src/minecraft/mekanism/generators/common/TileEntityHydrogenGenerator.java +++ b/src/minecraft/mekanism/generators/common/TileEntityHydrogenGenerator.java @@ -14,6 +14,7 @@ import mekanism.common.MekanismUtils; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraftforge.common.ForgeDirection; +import net.minecraftforge.liquids.LiquidContainerRegistry; import universalelectricity.core.UniversalElectricity; import universalelectricity.core.item.ElectricItemHelper; import universalelectricity.core.item.IItemElectric; @@ -98,6 +99,23 @@ public class TileEntityHydrogenGenerator extends TileEntityGenerator implements } } + @Override + public boolean func_102008_b(int slotID, ItemStack itemstack, int side) + { + if(slotID == 1) + { + return (itemstack.getItem() instanceof IItemElectric && ((IItemElectric)itemstack.getItem()).getReceiveRequest(itemstack).getWatts() == 0) || + (itemstack.getItem() instanceof IElectricItem && (!(itemstack.getItem() instanceof IItemElectric) || + ((IItemElectric)itemstack.getItem()).getReceiveRequest(itemstack).getWatts() == 0)); + } + else if(slotID == 0) + { + return (itemstack.getItem() instanceof IStorageTank && ((IStorageTank)itemstack.getItem()).getGas(EnumGas.NONE, itemstack) == 0); + } + + return false; + } + @Override public boolean isStackValidForSlot(int slotID, ItemStack itemstack) { @@ -114,6 +132,12 @@ public class TileEntityHydrogenGenerator extends TileEntityGenerator implements return true; } + @Override + public int[] getSizeInventorySide(int side) + { + return ForgeDirection.getOrientation(side) == MekanismUtils.getRight(facing) ? new int[] {1} : new int[] {0}; + } + @Override public int getStartInventorySide(ForgeDirection side) { diff --git a/src/minecraft/mekanism/generators/common/TileEntitySolarGenerator.java b/src/minecraft/mekanism/generators/common/TileEntitySolarGenerator.java index 21b56e0a1..bbc3e3c66 100644 --- a/src/minecraft/mekanism/generators/common/TileEntitySolarGenerator.java +++ b/src/minecraft/mekanism/generators/common/TileEntitySolarGenerator.java @@ -7,8 +7,12 @@ import universalelectricity.core.item.IItemElectric; import ic2.api.ElectricItem; import ic2.api.IElectricItem; +import mekanism.api.EnumGas; +import mekanism.api.IStorageTank; import mekanism.common.Mekanism; +import mekanism.common.MekanismUtils; import mekanism.generators.common.BlockGenerator.GeneratorType; +import micdoodle8.mods.galacticraft.API.ISolarLevel; import net.minecraft.item.ItemStack; import net.minecraftforge.common.ForgeDirection; @@ -41,6 +45,12 @@ public class TileEntitySolarGenerator extends TileEntityGenerator @Override public void updateSound() {/* No super - prevent sound updating */} + @Override + public int[] getSizeInventorySide(int side) + { + return new int[] {0}; + } + @Override public int getSizeInventorySide(ForgeDirection side) { @@ -91,6 +101,19 @@ public class TileEntitySolarGenerator extends TileEntityGenerator } } + @Override + public boolean func_102008_b(int slotID, ItemStack itemstack, int side) + { + if(slotID == 0) + { + return (itemstack.getItem() instanceof IItemElectric && ((IItemElectric)itemstack.getItem()).getReceiveRequest(itemstack).getWatts() == 0) || + (itemstack.getItem() instanceof IElectricItem && (!(itemstack.getItem() instanceof IItemElectric) || + ((IItemElectric)itemstack.getItem()).getReceiveRequest(itemstack).getWatts() == 0)); + } + + return false; + } + @Override public boolean isStackValidForSlot(int slotID, ItemStack itemstack) { @@ -112,7 +135,7 @@ public class TileEntitySolarGenerator extends TileEntityGenerator @Override public int getEnvironmentBoost() { - return seesSun ? GENERATION_RATE : 0; + return seesSun ? (GENERATION_RATE*(worldObj.provider instanceof ISolarLevel ? (int)((ISolarLevel)worldObj.provider).getSolorEnergyMultiplier() : 1)) : 0; } @Override