From 3abd80f1a2ff43a7ccb6a535d107a231fc41378d Mon Sep 17 00:00:00 2001 From: "Aidan C. Brady" Date: Sat, 26 Jul 2014 19:10:17 -0400 Subject: [PATCH 1/4] Generators now sustain fluid and gas data --- .../common/block/BlockGenerator.java | 9 +++++++-- .../common/item/ItemBlockGenerator.java | 10 +++++++++- .../common/tile/TileEntityBioGenerator.java | 15 ++++++++++++++- .../common/tile/TileEntityGasGenerator.java | 19 +++++++++++++++++-- .../common/tile/TileEntityHeatGenerator.java | 18 +++++++++++++++++- 5 files changed, 64 insertions(+), 7 deletions(-) diff --git a/src/main/java/mekanism/generators/common/block/BlockGenerator.java b/src/main/java/mekanism/generators/common/block/BlockGenerator.java index cc31bc86d..0f94d9688 100644 --- a/src/main/java/mekanism/generators/common/block/BlockGenerator.java +++ b/src/main/java/mekanism/generators/common/block/BlockGenerator.java @@ -7,6 +7,7 @@ import mekanism.api.energy.IEnergizedItem; import mekanism.common.IActiveState; import mekanism.common.IBoundingBlock; import mekanism.common.ISpecialBounds; +import mekanism.common.ISustainedData; import mekanism.common.ISustainedInventory; import mekanism.common.ISustainedTank; import mekanism.common.ItemAttacher; @@ -18,8 +19,8 @@ import mekanism.generators.client.GeneratorsClientProxy; import mekanism.generators.common.MekanismGenerators; import mekanism.generators.common.tile.TileEntityAdvancedSolarGenerator; import mekanism.generators.common.tile.TileEntityBioGenerator; -import mekanism.generators.common.tile.TileEntityHeatGenerator; import mekanism.generators.common.tile.TileEntityGasGenerator; +import mekanism.generators.common.tile.TileEntityHeatGenerator; import mekanism.generators.common.tile.TileEntitySolarGenerator; import mekanism.generators.common.tile.TileEntityWindTurbine; import net.minecraft.block.Block; @@ -39,7 +40,6 @@ import net.minecraft.world.IBlockAccess; import net.minecraft.world.World; import net.minecraftforge.common.util.ForgeDirection; import buildcraft.api.tools.IToolWrench; - import cpw.mods.fml.common.ModAPIManager; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; @@ -459,6 +459,11 @@ public class BlockGenerator extends BlockContainer implements ISpecialBounds ISustainedInventory inventory = (ISustainedInventory)itemStack.getItem(); inventory.setInventory(((ISustainedInventory)tileEntity).getInventory(), itemStack); + + if(tileEntity instanceof ISustainedData) + { + ((ISustainedData)tileEntity).writeSustainedData(itemStack); + } if(((ISustainedTank)itemStack.getItem()).hasTank(itemStack)) { diff --git a/src/main/java/mekanism/generators/common/item/ItemBlockGenerator.java b/src/main/java/mekanism/generators/common/item/ItemBlockGenerator.java index 33e373e8f..83b05f678 100644 --- a/src/main/java/mekanism/generators/common/item/ItemBlockGenerator.java +++ b/src/main/java/mekanism/generators/common/item/ItemBlockGenerator.java @@ -8,6 +8,7 @@ import java.util.List; import mekanism.api.EnumColor; import mekanism.api.energy.IEnergizedItem; import mekanism.client.MekanismKeyHandler; +import mekanism.common.ISustainedData; import mekanism.common.ISustainedInventory; import mekanism.common.ISustainedTank; import mekanism.common.Mekanism; @@ -31,7 +32,6 @@ import net.minecraftforge.fluids.FluidStack; import org.lwjgl.input.Keyboard; import cofh.api.energy.IEnergyContainerItem; - import cpw.mods.fml.common.Optional.Interface; import cpw.mods.fml.common.Optional.InterfaceList; import cpw.mods.fml.common.Optional.Method; @@ -169,6 +169,14 @@ public class ItemBlockGenerator extends ItemBlock implements IEnergizedItem, ISp tileEntity.electricityStored = getEnergy(stack); ((ISustainedInventory)tileEntity).setInventory(getInventory(stack)); + + if(tileEntity instanceof ISustainedData) + { + if(stack.stackTagCompound != null) + { + ((ISustainedData)tileEntity).readSustainedData(stack); + } + } if(tileEntity instanceof ISustainedTank) { diff --git a/src/main/java/mekanism/generators/common/tile/TileEntityBioGenerator.java b/src/main/java/mekanism/generators/common/tile/TileEntityBioGenerator.java index 916fab482..33170f7a6 100644 --- a/src/main/java/mekanism/generators/common/tile/TileEntityBioGenerator.java +++ b/src/main/java/mekanism/generators/common/tile/TileEntityBioGenerator.java @@ -7,6 +7,7 @@ import java.util.EnumSet; import mekanism.client.sound.TileSound; import mekanism.common.FluidSlot; +import mekanism.common.ISustainedData; import mekanism.common.Mekanism; import mekanism.common.util.ChargeUtils; import mekanism.common.util.MekanismUtils; @@ -26,7 +27,7 @@ import cpw.mods.fml.relauncher.SideOnly; import dan200.computercraft.api.lua.ILuaContext; import dan200.computercraft.api.peripheral.IComputerAccess; -public class TileEntityBioGenerator extends TileEntityGenerator implements IFluidHandler +public class TileEntityBioGenerator extends TileEntityGenerator implements IFluidHandler, ISustainedData { /** The Sound instance for this machine. */ @SideOnly(Side.CLIENT) @@ -317,4 +318,16 @@ public class TileEntityBioGenerator extends TileEntityGenerator implements IFlui { return null; } + + @Override + public void writeSustainedData(ItemStack itemStack) + { + itemStack.stackTagCompound.setInteger("fluidStored", bioFuelSlot.fluidStored); + } + + @Override + public void readSustainedData(ItemStack itemStack) + { + bioFuelSlot.setFluid(itemStack.stackTagCompound.getInteger("fluidStored")); + } } \ No newline at end of file diff --git a/src/main/java/mekanism/generators/common/tile/TileEntityGasGenerator.java b/src/main/java/mekanism/generators/common/tile/TileEntityGasGenerator.java index e04492126..db53d2050 100644 --- a/src/main/java/mekanism/generators/common/tile/TileEntityGasGenerator.java +++ b/src/main/java/mekanism/generators/common/tile/TileEntityGasGenerator.java @@ -14,6 +14,7 @@ import mekanism.api.gas.GasTransmission; import mekanism.api.gas.IGasHandler; import mekanism.api.gas.IGasItem; import mekanism.api.gas.ITubeConnection; +import mekanism.common.ISustainedData; import mekanism.common.Mekanism; import mekanism.common.util.ChargeUtils; import mekanism.common.util.MekanismUtils; @@ -21,11 +22,10 @@ import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraftforge.common.util.ForgeDirection; import cpw.mods.fml.common.Optional.Method; - import dan200.computercraft.api.lua.ILuaContext; import dan200.computercraft.api.peripheral.IComputerAccess; -public class TileEntityGasGenerator extends TileEntityGenerator implements IGasHandler, ITubeConnection +public class TileEntityGasGenerator extends TileEntityGenerator implements IGasHandler, ITubeConnection, ISustainedData { /** The maximum amount of gas this block can store. */ public int MAX_GAS = 18000; @@ -277,4 +277,19 @@ public class TileEntityGasGenerator extends TileEntityGenerator implements IGasH { return side != ForgeDirection.getOrientation(facing); } + + @Override + public void writeSustainedData(ItemStack itemStack) + { + if(fuelTank.getGas() != null) + { + itemStack.stackTagCompound.setTag("fuelTank", fuelTank.write(new NBTTagCompound())); + } + } + + @Override + public void readSustainedData(ItemStack itemStack) + { + fuelTank.setGas(GasStack.readFromNBT(itemStack.stackTagCompound.getCompoundTag("fuelTank"))); + } } diff --git a/src/main/java/mekanism/generators/common/tile/TileEntityHeatGenerator.java b/src/main/java/mekanism/generators/common/tile/TileEntityHeatGenerator.java index 92af05136..84216e171 100644 --- a/src/main/java/mekanism/generators/common/tile/TileEntityHeatGenerator.java +++ b/src/main/java/mekanism/generators/common/tile/TileEntityHeatGenerator.java @@ -4,6 +4,7 @@ import io.netty.buffer.ByteBuf; import java.util.ArrayList; +import mekanism.common.ISustainedData; import mekanism.common.Mekanism; import mekanism.common.util.ChargeUtils; import mekanism.common.util.FluidContainerUtils; @@ -27,7 +28,7 @@ import cpw.mods.fml.common.Optional.Method; import dan200.computercraft.api.lua.ILuaContext; import dan200.computercraft.api.peripheral.IComputerAccess; -public class TileEntityHeatGenerator extends TileEntityGenerator implements IFluidHandler +public class TileEntityHeatGenerator extends TileEntityGenerator implements IFluidHandler, ISustainedData { /** The FluidTank for this generator. */ public FluidTank lavaTank = new FluidTank(24000); @@ -335,4 +336,19 @@ public class TileEntityHeatGenerator extends TileEntityGenerator implements IFlu { return new FluidTankInfo[] {lavaTank.getInfo()}; } + + @Override + public void writeSustainedData(ItemStack itemStack) + { + if(lavaTank.getFluid() != null) + { + itemStack.stackTagCompound.setTag("lavaTank", lavaTank.getFluid().writeToNBT(new NBTTagCompound())); + } + } + + @Override + public void readSustainedData(ItemStack itemStack) + { + lavaTank.setFluid(FluidStack.loadFluidStackFromNBT(itemStack.stackTagCompound.getCompoundTag("lavaTank"))); + } } From 31e24ecd1ef7cffae667757a9072e7c9dc6b6807 Mon Sep 17 00:00:00 2001 From: "Aidan C. Brady" Date: Sat, 26 Jul 2014 19:17:02 -0400 Subject: [PATCH 2/4] Fixed default enchantibilities --- .../mekanism/tools/common/MekanismTools.java | 36 +++++++++---------- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/src/main/java/mekanism/tools/common/MekanismTools.java b/src/main/java/mekanism/tools/common/MekanismTools.java index 06e80815d..930303c33 100644 --- a/src/main/java/mekanism/tools/common/MekanismTools.java +++ b/src/main/java/mekanism/tools/common/MekanismTools.java @@ -394,84 +394,84 @@ public class MekanismTools implements IModule , Mekanism.configuration.get("tools.tool-balance.obsidian.regular", "maxUses", 2500).getInt() , (float)Mekanism.configuration.get("tools.tool-balance.obsidian.regular", "efficiency", 20d).getDouble(0) , Mekanism.configuration.get("tools.tool-balance.obsidian.regular", "damage", 10).getInt() - , Mekanism.configuration.get("tools.tool-balance.obsidian.regular", "enchantability", 100).getInt() + , Mekanism.configuration.get("tools.tool-balance.obsidian.regular", "enchantability", 40).getInt() ); toolOBSIDIAN2 = EnumHelper.addToolMaterial("OBSIDIAN2" , Mekanism.configuration.get("tools.tool-balance.obsidian.paxel", "harvestLevel", 3).getInt() , Mekanism.configuration.get("tools.tool-balance.obsidian.paxel", "maxUses", 3000).getInt() , (float)Mekanism.configuration.get("tools.tool-balance.obsidian.paxel", "efficiency", 25d).getDouble(0) , Mekanism.configuration.get("tools.tool-balance.obsidian.paxel", "damage", 10).getInt() - , Mekanism.configuration.get("tools.tool-balance.obsidian.paxel", "enchantability", 100).getInt() + , Mekanism.configuration.get("tools.tool-balance.obsidian.paxel", "enchantability", 50).getInt() ); toolLAZULI = EnumHelper.addToolMaterial("LAZULI" , Mekanism.configuration.get("tools.tool-balance.lapis.regular", "harvestLevel", 2).getInt() , Mekanism.configuration.get("tools.tool-balance.lapis.regular", "maxUses", 200).getInt() , (float)Mekanism.configuration.get("tools.tool-balance.lapis.regular", "efficiency", 5d).getDouble(0) , Mekanism.configuration.get("tools.tool-balance.lapis.regular", "damage", 2).getInt() - , Mekanism.configuration.get("tools.tool-balance.lapis.regular", "enchantability", 22).getInt() + , Mekanism.configuration.get("tools.tool-balance.lapis.regular", "enchantability", 8).getInt() ); toolLAZULI2 = EnumHelper.addToolMaterial("LAZULI2" , Mekanism.configuration.get("tools.tool-balance.lapis.paxel", "harvestLevel", 2).getInt() , Mekanism.configuration.get("tools.tool-balance.lapis.paxel", "maxUses", 250).getInt() , (float)Mekanism.configuration.get("tools.tool-balance.lapis.paxel", "efficiency", 6d).getDouble(0) , Mekanism.configuration.get("tools.tool-balance.lapis.paxel", "damage", 4).getInt() - , Mekanism.configuration.get("tools.tool-balance.lapis.paxel", "enchantability", 50).getInt() + , Mekanism.configuration.get("tools.tool-balance.lapis.paxel", "enchantability", 10).getInt() ); toolOSMIUM = EnumHelper.addToolMaterial("OSMIUM" , Mekanism.configuration.get("tools.tool-balance.osmium.regular", "harvestLevel", 2).getInt() , Mekanism.configuration.get("tools.tool-balance.osmium.regular", "maxUses", 500).getInt() , (float)Mekanism.configuration.get("tools.tool-balance.osmium.regular", "efficiency", 10d).getDouble(0) , Mekanism.configuration.get("tools.tool-balance.osmium.regular", "damage", 4).getInt() - , Mekanism.configuration.get("tools.tool-balance.osmium.regular", "enchantability", 30).getInt() + , Mekanism.configuration.get("tools.tool-balance.osmium.regular", "enchantability", 12).getInt() ); toolOSMIUM2 = EnumHelper.addToolMaterial("OSMIUM2" , Mekanism.configuration.get("tools.tool-balance.osmium.paxel", "harvestLevel", 3).getInt() , Mekanism.configuration.get("tools.tool-balance.osmium.paxel", "maxUses", 700).getInt() , (float)Mekanism.configuration.get("tools.tool-balance.osmium.paxel", "efficiency", 12d).getDouble(0) , Mekanism.configuration.get("tools.tool-balance.osmium.paxel", "damage", 5).getInt() - , Mekanism.configuration.get("tools.tool-balance.osmium.paxel", "enchantability", 40).getInt() + , Mekanism.configuration.get("tools.tool-balance.osmium.paxel", "enchantability", 16).getInt() ); toolBRONZE = EnumHelper.addToolMaterial("BRONZE" , Mekanism.configuration.get("tools.tool-balance.bronze.regular", "harvestLevel", 2).getInt() , Mekanism.configuration.get("tools.tool-balance.bronze.regular", "maxUses", 800).getInt() , (float)Mekanism.configuration.get("tools.tool-balance.bronze.regular", "efficiency", 14d).getDouble(0) , Mekanism.configuration.get("tools.tool-balance.bronze.regular", "damage", 6).getInt() - , Mekanism.configuration.get("tools.tool-balance.bronze.regular", "enchantability", 100).getInt() + , Mekanism.configuration.get("tools.tool-balance.bronze.regular", "enchantability", 10).getInt() ); toolBRONZE2 = EnumHelper.addToolMaterial("BRONZE2" , Mekanism.configuration.get("tools.tool-balance.bronze.paxel", "harvestLevel", 3).getInt() , Mekanism.configuration.get("tools.tool-balance.bronze.paxel", "maxUses", 1100).getInt() , (float)Mekanism.configuration.get("tools.tool-balance.bronze.paxel", "efficiency", 16d).getDouble(0) , Mekanism.configuration.get("tools.tool-balance.bronze.paxel", "damage", 10).getInt() - , Mekanism.configuration.get("tools.tool-balance.bronze.paxel", "enchantability", 100).getInt() + , Mekanism.configuration.get("tools.tool-balance.bronze.paxel", "enchantability", 14).getInt() ); toolGLOWSTONE = EnumHelper.addToolMaterial("GLOWSTONE" , Mekanism.configuration.get("tools.tool-balance.glowstone.regular", "harvestLevel", 2).getInt() , Mekanism.configuration.get("tools.tool-balance.glowstone.regular", "maxUses", 300).getInt() , (float)Mekanism.configuration.get("tools.tool-balance.glowstone.regular", "efficiency", 14d).getDouble(0) , Mekanism.configuration.get("tools.tool-balance.glowstone.regular", "damage", 5).getInt() - , Mekanism.configuration.get("tools.tool-balance.glowstone.regular", "enchantability", 80).getInt() + , Mekanism.configuration.get("tools.tool-balance.glowstone.regular", "enchantability", 18).getInt() ); toolGLOWSTONE2 = EnumHelper.addToolMaterial("GLOWSTONE2" , Mekanism.configuration.get("tools.tool-balance.glowstone.paxel", "harvestLevel", 2).getInt() , Mekanism.configuration.get("tools.tool-balance.glowstone.paxel", "maxUses", 450).getInt() , (float)Mekanism.configuration.get("tools.tool-balance.glowstone.paxel", "efficiency", 18d).getDouble(0) , Mekanism.configuration.get("tools.tool-balance.glowstone.paxel", "damage", 5).getInt() - , Mekanism.configuration.get("tools.tool-balance.glowstone.paxel", "enchantability", 100).getInt() + , Mekanism.configuration.get("tools.tool-balance.glowstone.paxel", "enchantability", 22).getInt() ); toolSTEEL = EnumHelper.addToolMaterial("STEEL" , Mekanism.configuration.get("tools.tool-balance.steel.regular", "harvestLevel", 3).getInt() , Mekanism.configuration.get("tools.tool-balance.steel.regular", "maxUses", 850).getInt() , (float)Mekanism.configuration.get("tools.tool-balance.steel.regular", "efficiency", 14d).getDouble(0) , Mekanism.configuration.get("tools.tool-balance.steel.regular", "damage", 4).getInt() - , Mekanism.configuration.get("tools.tool-balance.steel.regular", "enchantability", 100).getInt() + , Mekanism.configuration.get("tools.tool-balance.steel.regular", "enchantability", 10).getInt() ); toolSTEEL2 = EnumHelper.addToolMaterial("STEEL2" , Mekanism.configuration.get("tools.tool-balance.steel.paxel", "harvestLevel", 3).getInt() , Mekanism.configuration.get("tools.tool-balance.steel.paxel", "maxUses", 1250).getInt() , (float)Mekanism.configuration.get("tools.tool-balance.steel.paxel", "efficiency", 18d).getDouble(0) , Mekanism.configuration.get("tools.tool-balance.steel.paxel", "damage", 8).getInt() - , Mekanism.configuration.get("tools.tool-balance.steel.paxel", "enchantability", 100).getInt() + , Mekanism.configuration.get("tools.tool-balance.steel.paxel", "enchantability", 14).getInt() ); //Armors @@ -484,7 +484,7 @@ public class MekanismTools implements IModule , Mekanism.configuration.get("tools.armor-balance.obsidian.protection", "legs", 8).getInt() , Mekanism.configuration.get("tools.armor-balance.obsidian.protection", "feet", 5).getInt() } - , Mekanism.configuration.get("tools.armor-balance.obsidian", "enchantability", 50).getInt() + , Mekanism.configuration.get("tools.armor-balance.obsidian", "enchantability", 40).getInt() ); armorLAZULI = EnumHelper.addArmorMaterial("LAZULI" , Mekanism.configuration.get("tools.armor-balance.lapis", "durability", 13).getInt() @@ -495,7 +495,7 @@ public class MekanismTools implements IModule , Mekanism.configuration.get("tools.armor-balance.lapis.protection", "legs", 6).getInt() , Mekanism.configuration.get("tools.armor-balance.lapis.protection", "feet", 2).getInt() } - , Mekanism.configuration.get("tools.armor-balance.lapis", "enchantability", 50).getInt() + , Mekanism.configuration.get("tools.armor-balance.lapis", "enchantability", 8).getInt() ); armorOSMIUM = EnumHelper.addArmorMaterial("OSMIUM" , Mekanism.configuration.get("tools.armor-balance.osmium", "durability", 30).getInt() @@ -506,7 +506,7 @@ public class MekanismTools implements IModule , Mekanism.configuration.get("tools.armor-balance.osmium.protection", "legs", 6).getInt() , Mekanism.configuration.get("tools.armor-balance.osmium.protection", "feet", 3).getInt() } - , Mekanism.configuration.get("tools.armor-balance.osmium", "enchantability", 50).getInt() + , Mekanism.configuration.get("tools.armor-balance.osmium", "enchantability", 12).getInt() ); armorBRONZE = EnumHelper.addArmorMaterial("BRONZE" , Mekanism.configuration.get("tools.armor-balance.bronze", "durability", 35).getInt() @@ -517,7 +517,7 @@ public class MekanismTools implements IModule , Mekanism.configuration.get("tools.armor-balance.bronze.protection", "legs", 5).getInt() , Mekanism.configuration.get("tools.armor-balance.bronze.protection", "feet", 2).getInt() } - , Mekanism.configuration.get("tools.armor-balance.bronze", "enchantability", 50).getInt() + , Mekanism.configuration.get("tools.armor-balance.bronze", "enchantability", 10).getInt() ); armorGLOWSTONE = EnumHelper.addArmorMaterial("GLOWSTONE" , Mekanism.configuration.get("tools.armor-balance.glowstone", "durability", 18).getInt() @@ -528,7 +528,7 @@ public class MekanismTools implements IModule , Mekanism.configuration.get("tools.armor-balance.glowstone.protection", "legs", 6).getInt() , Mekanism.configuration.get("tools.armor-balance.glowstone.protection", "feet", 3).getInt() } - , Mekanism.configuration.get("tools.armor-balance.glowstone", "enchantability", 50).getInt() + , Mekanism.configuration.get("tools.armor-balance.glowstone", "enchantability", 18).getInt() ); armorSTEEL = EnumHelper.addArmorMaterial("STEEL" , Mekanism.configuration.get("tools.armor-balance.steel", "durability", 40).getInt() @@ -539,7 +539,7 @@ public class MekanismTools implements IModule , Mekanism.configuration.get("tools.armor-balance.steel.protection", "legs", 6).getInt() , Mekanism.configuration.get("tools.armor-balance.steel.protection", "feet", 3).getInt() } - , Mekanism.configuration.get("tools.armor-balance.steel", "enchantability", 50).getInt() + , Mekanism.configuration.get("tools.armor-balance.steel", "enchantability", 10).getInt() ); //Bronze From 1d61c3d4e8696ad568766a970daaff843fc4ee5b Mon Sep 17 00:00:00 2001 From: Ben Spiers Date: Sun, 27 Jul 2014 20:45:13 +0100 Subject: [PATCH 3/4] Tweak energynet logic a bit to safeguard against overly high tiers of IC2 acceptor and things that implement everything but with only one working. Should fix AE2 EU P2P tunnel support. --- .../java/mekanism/common/EnergyNetwork.java | 33 +++++++++++++------ 1 file changed, 23 insertions(+), 10 deletions(-) diff --git a/src/main/java/mekanism/common/EnergyNetwork.java b/src/main/java/mekanism/common/EnergyNetwork.java index 11b012149..f83a19a6b 100644 --- a/src/main/java/mekanism/common/EnergyNetwork.java +++ b/src/main/java/mekanism/common/EnergyNetwork.java @@ -201,21 +201,26 @@ public class EnergyNetwork extends DynamicNetwork if(acceptor instanceof IStrictEnergyAcceptor) { - sent += ((IStrictEnergyAcceptor)acceptor).transferEnergyToAcceptor(side.getOpposite(), currentSending); + double used = ((IStrictEnergyAcceptor)acceptor).transferEnergyToAcceptor(side.getOpposite(), currentSending); + sent += used; + if(used > 0) continue; } - else if(MekanismUtils.useRF() && acceptor instanceof IEnergyHandler) + if(MekanismUtils.useRF() && acceptor instanceof IEnergyHandler) { IEnergyHandler handler = (IEnergyHandler)acceptor; int used = handler.receiveEnergy(side.getOpposite(), (int)Math.round(currentSending*Mekanism.TO_TE), false); sent += used*Mekanism.FROM_TE; + if(used > 0) continue; } - else if(MekanismUtils.useIC2() && acceptor instanceof IEnergySink) + if(MekanismUtils.useIC2() && acceptor instanceof IEnergySink) { - double toSend = Math.min(currentSending, EnergyNet.instance.getPowerFromTier(((IEnergySink) acceptor).getSinkTier())*Mekanism.FROM_IC2); + double toSend = Math.min(currentSending, EnergyNet.instance.getPowerFromTier(Math.min(((IEnergySink) acceptor).getSinkTier(), 8))*Mekanism.FROM_IC2); toSend = Math.min(toSend, ((IEnergySink)acceptor).getDemandedEnergy()*Mekanism.FROM_IC2); - sent += (toSend - (((IEnergySink)acceptor).injectEnergy(side.getOpposite(), toSend*Mekanism.TO_IC2, 0)*Mekanism.FROM_IC2)); + double used = toSend - (((IEnergySink)acceptor).injectEnergy(side.getOpposite(), toSend*Mekanism.TO_IC2, 0)*Mekanism.FROM_IC2); + sent += used; + if(used > 0) continue; } - else if(MekanismUtils.useBuildCraft() && acceptor instanceof IPowerReceptor) + if(MekanismUtils.useBuildCraft() && acceptor instanceof IPowerReceptor) { PowerReceiver receiver = ((IPowerReceptor)acceptor).getPowerReceiver(side.getOpposite()); @@ -223,6 +228,7 @@ public class EnergyNetwork extends DynamicNetwork { double toSend = receiver.receiveEnergy(Type.PIPE, (float)(Math.min(receiver.powerRequest(), currentSending*Mekanism.TO_BC)), side.getOpposite()); sent += toSend*Mekanism.FROM_BC; + if(toSend > 0) continue; } } } @@ -260,10 +266,11 @@ public class EnergyNetwork extends DynamicNetwork if(handler.getMaxEnergy() - handler.getEnergy() > 0) { toReturn.add(acceptor); + continue; } } } - else if(MekanismUtils.useRF() && acceptor instanceof IEnergyHandler) + if(MekanismUtils.useRF() && acceptor instanceof IEnergyHandler) { IEnergyHandler handler = (IEnergyHandler)acceptor; @@ -272,22 +279,27 @@ public class EnergyNetwork extends DynamicNetwork if(handler.getMaxEnergyStored(side.getOpposite()) - handler.getEnergyStored(side.getOpposite()) > 0 || handler.receiveEnergy(side.getOpposite(), 1, true) > 0) { toReturn.add(acceptor); + continue; } } } - else if(MekanismUtils.useIC2() && acceptor instanceof IEnergySink) + if(MekanismUtils.useIC2() && acceptor instanceof IEnergySink) { IEnergySink handler = (IEnergySink)acceptor; if(handler.acceptsEnergyFrom(null, side.getOpposite())) { - if(Math.min((handler.getDemandedEnergy()*Mekanism.FROM_IC2), (EnergyNet.instance.getPowerFromTier(handler.getSinkTier())*Mekanism.FROM_IC2)) > 0) + double demanded = handler.getDemandedEnergy()*Mekanism.FROM_IC2; + int tier = Math.min(handler.getSinkTier(), 8); + double max = EnergyNet.instance.getPowerFromTier(tier)*Mekanism.FROM_IC2; + if(Math.min(demanded, max) > 0) { toReturn.add(acceptor); + continue; } } } - else if(MekanismUtils.useBuildCraft() && acceptor instanceof IPowerReceptor) + if(MekanismUtils.useBuildCraft() && acceptor instanceof IPowerReceptor) { IPowerReceptor handler = (IPowerReceptor)acceptor; @@ -301,6 +313,7 @@ public class EnergyNetwork extends DynamicNetwork } toReturn.add(acceptor); + continue; } } } From e2913e252011301e873206a4c51bebd7442edff9 Mon Sep 17 00:00:00 2001 From: Ben Spiers Date: Mon, 28 Jul 2014 04:24:56 +0100 Subject: [PATCH 4/4] Work on reactor GUI. Three different screens now because there's so much information. Still need an option on the fuel screen to set the injection rate and a proper button to form the multiblock. --- .../client/GeneratorsClientProxy.java | 6 + .../generators/client/gui/GuiFuelTab.java | 84 ++++++++ .../generators/client/gui/GuiHeatTab.java | 84 ++++++++ .../client/gui/GuiReactorController.java | 127 +++--------- .../generators/client/gui/GuiReactorFuel.java | 117 +++++++++++ .../generators/client/gui/GuiReactorHeat.java | 180 +++++++++++++++++ .../common/GeneratorsCommonProxy.java | 4 + .../common/GeneratorsPacketHandler.java | 183 ++++++++++++++++++ .../generators/common/MekanismGenerators.java | 5 + .../generators/common/block/BlockReactor.java | 2 +- .../container/ContainerReactorController.java | 10 +- .../common/network/PacketGeneratorsGui.java | 114 +++++++++++ .../reactor/TileEntityReactorController.java | 13 ++ .../resources/assets/mekanism/gui/GuiTall.png | Bin 1796 -> 1713 bytes .../mekanism/gui/elements/GuiFuelTab.png | Bin 0 -> 2545 bytes .../mekanism/gui/elements/GuiHeatTab.png | Bin 0 -> 2598 bytes .../mekanism/gui/elements/GuiProgress.png | Bin 5077 -> 5055 bytes 17 files changed, 831 insertions(+), 98 deletions(-) create mode 100644 src/main/java/mekanism/generators/client/gui/GuiFuelTab.java create mode 100644 src/main/java/mekanism/generators/client/gui/GuiHeatTab.java create mode 100644 src/main/java/mekanism/generators/client/gui/GuiReactorFuel.java create mode 100644 src/main/java/mekanism/generators/client/gui/GuiReactorHeat.java create mode 100644 src/main/java/mekanism/generators/common/GeneratorsPacketHandler.java create mode 100644 src/main/java/mekanism/generators/common/network/PacketGeneratorsGui.java create mode 100644 src/main/resources/assets/mekanism/gui/elements/GuiFuelTab.png create mode 100644 src/main/resources/assets/mekanism/gui/elements/GuiHeatTab.png diff --git a/src/main/java/mekanism/generators/client/GeneratorsClientProxy.java b/src/main/java/mekanism/generators/client/GeneratorsClientProxy.java index b596bbdcb..cb3698ded 100644 --- a/src/main/java/mekanism/generators/client/GeneratorsClientProxy.java +++ b/src/main/java/mekanism/generators/client/GeneratorsClientProxy.java @@ -5,6 +5,8 @@ import mekanism.generators.client.gui.GuiHeatGenerator; import mekanism.generators.client.gui.GuiGasGenerator; import mekanism.generators.client.gui.GuiNeutronCapture; import mekanism.generators.client.gui.GuiReactorController; +import mekanism.generators.client.gui.GuiReactorFuel; +import mekanism.generators.client.gui.GuiReactorHeat; import mekanism.generators.client.gui.GuiSolarGenerator; import mekanism.generators.client.gui.GuiWindTurbine; import mekanism.generators.client.render.RenderAdvancedSolarGenerator; @@ -77,6 +79,10 @@ public class GeneratorsClientProxy extends GeneratorsCommonProxy case 10: return new GuiReactorController(player.inventory, (TileEntityReactorController)tileEntity); case 11: + return new GuiReactorHeat(player.inventory, (TileEntityReactorController)tileEntity); + case 12: + return new GuiReactorFuel(player.inventory, (TileEntityReactorController)tileEntity); + case 13: return new GuiNeutronCapture(player.inventory, (TileEntityReactorNeutronCapture)tileEntity); } diff --git a/src/main/java/mekanism/generators/client/gui/GuiFuelTab.java b/src/main/java/mekanism/generators/client/gui/GuiFuelTab.java new file mode 100644 index 000000000..bc637a2eb --- /dev/null +++ b/src/main/java/mekanism/generators/client/gui/GuiFuelTab.java @@ -0,0 +1,84 @@ +package mekanism.generators.client.gui; + +import mekanism.api.Coord4D; +import mekanism.client.gui.GuiElement; +import mekanism.client.gui.IGuiWrapper; +import mekanism.client.sound.SoundHandler; +import mekanism.common.Mekanism; +import mekanism.common.network.PacketSimpleGui.SimpleGuiMessage; +import mekanism.common.util.MekanismUtils; +import mekanism.common.util.MekanismUtils.ResourceType; +import mekanism.generators.common.MekanismGenerators; +import mekanism.generators.common.network.PacketGeneratorsGui.GeneratorsGuiMessage; + +import net.minecraft.tileentity.TileEntity; +import net.minecraft.util.ResourceLocation; +import codechicken.lib.vec.Rectangle4i; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; + +@SideOnly(Side.CLIENT) +public class GuiFuelTab extends GuiElement +{ + TileEntity tileEntity; + + public GuiFuelTab(IGuiWrapper gui, TileEntity tile, ResourceLocation def) + { + super(MekanismUtils.getResource(ResourceType.GUI_ELEMENT, "GuiFuelTab.png"), gui, def); + + tileEntity = tile; + } + + @Override + public Rectangle4i getBounds(int guiWidth, int guiHeight) + { + return new Rectangle4i(guiWidth - 26, guiHeight + 34, 26, 26); + } + + @Override + public void renderBackground(int xAxis, int yAxis, int guiWidth, int guiHeight) + { + mc.renderEngine.bindTexture(RESOURCE); + + guiObj.drawTexturedRect(guiWidth - 26, guiHeight + 34, 0, 0, 26, 26); + + if(xAxis >= -21 && xAxis <= -3 && yAxis >= 38 && yAxis <= 56) + { + guiObj.drawTexturedRect(guiWidth - 21, guiHeight + 38, 26, 0, 18, 18); + } + else { + guiObj.drawTexturedRect(guiWidth - 21, guiHeight + 38, 26, 18, 18, 18); + } + + mc.renderEngine.bindTexture(defaultLocation); + } + + @Override + public void renderForeground(int xAxis, int yAxis) + { + mc.renderEngine.bindTexture(RESOURCE); + + if(xAxis >= -21 && xAxis <= -3 && yAxis >= 38 && yAxis <= 56) + { + displayTooltip(MekanismUtils.localize("gui.fuel"), xAxis, yAxis); + } + + mc.renderEngine.bindTexture(defaultLocation); + } + + @Override + public void preMouseClicked(int xAxis, int yAxis, int button) {} + + @Override + public void mouseClicked(int xAxis, int yAxis, int button) + { + if(button == 0) + { + if(xAxis >= -21 && xAxis <= -3 && yAxis >= 38 && yAxis <= 56) + { + MekanismGenerators.packetHandler.sendToServer(new GeneratorsGuiMessage(Coord4D.get(tileEntity), 12)); + SoundHandler.playSound("gui.button.press"); + } + } + } +} diff --git a/src/main/java/mekanism/generators/client/gui/GuiHeatTab.java b/src/main/java/mekanism/generators/client/gui/GuiHeatTab.java new file mode 100644 index 000000000..e6cb80ff2 --- /dev/null +++ b/src/main/java/mekanism/generators/client/gui/GuiHeatTab.java @@ -0,0 +1,84 @@ +package mekanism.generators.client.gui; + +import mekanism.api.Coord4D; +import mekanism.client.gui.GuiElement; +import mekanism.client.gui.IGuiWrapper; +import mekanism.client.sound.SoundHandler; +import mekanism.common.Mekanism; +import mekanism.common.network.PacketSimpleGui.SimpleGuiMessage; +import mekanism.common.util.MekanismUtils; +import mekanism.common.util.MekanismUtils.ResourceType; +import mekanism.generators.common.MekanismGenerators; +import mekanism.generators.common.network.PacketGeneratorsGui.GeneratorsGuiMessage; + +import net.minecraft.tileentity.TileEntity; +import net.minecraft.util.ResourceLocation; +import codechicken.lib.vec.Rectangle4i; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; + +@SideOnly(Side.CLIENT) +public class GuiHeatTab extends GuiElement +{ + TileEntity tileEntity; + + public GuiHeatTab(IGuiWrapper gui, TileEntity tile, ResourceLocation def) + { + super(MekanismUtils.getResource(ResourceType.GUI_ELEMENT, "GuiHeatTab.png"), gui, def); + + tileEntity = tile; + } + + @Override + public Rectangle4i getBounds(int guiWidth, int guiHeight) + { + return new Rectangle4i(guiWidth - 26, guiHeight + 6, 26, 26); + } + + @Override + public void renderBackground(int xAxis, int yAxis, int guiWidth, int guiHeight) + { + mc.renderEngine.bindTexture(RESOURCE); + + guiObj.drawTexturedRect(guiWidth - 26, guiHeight + 6, 0, 0, 26, 26); + + if(xAxis >= -21 && xAxis <= -3 && yAxis >= 10 && yAxis <= 28) + { + guiObj.drawTexturedRect(guiWidth - 21, guiHeight + 10, 26, 0, 18, 18); + } + else { + guiObj.drawTexturedRect(guiWidth - 21, guiHeight + 10, 26, 18, 18, 18); + } + + mc.renderEngine.bindTexture(defaultLocation); + } + + @Override + public void renderForeground(int xAxis, int yAxis) + { + mc.renderEngine.bindTexture(RESOURCE); + + if(xAxis >= -21 && xAxis <= -3 && yAxis >= 10 && yAxis <= 28) + { + displayTooltip(MekanismUtils.localize("gui.heat"), xAxis, yAxis); + } + + mc.renderEngine.bindTexture(defaultLocation); + } + + @Override + public void preMouseClicked(int xAxis, int yAxis, int button) {} + + @Override + public void mouseClicked(int xAxis, int yAxis, int button) + { + if(button == 0) + { + if(xAxis >= -21 && xAxis <= -3 && yAxis >= 10 && yAxis <= 28) + { + MekanismGenerators.packetHandler.sendToServer(new GeneratorsGuiMessage(Coord4D.get(tileEntity), 11)); + SoundHandler.playSound("gui.button.press"); + } + } + } +} diff --git a/src/main/java/mekanism/generators/client/gui/GuiReactorController.java b/src/main/java/mekanism/generators/client/gui/GuiReactorController.java index 4b1312306..9700acffc 100644 --- a/src/main/java/mekanism/generators/client/gui/GuiReactorController.java +++ b/src/main/java/mekanism/generators/client/gui/GuiReactorController.java @@ -1,7 +1,9 @@ package mekanism.generators.client.gui; +import java.util.ArrayList; import java.util.List; +import mekanism.api.Coord4D; import mekanism.api.ListUtils; import mekanism.api.gas.GasTank; import mekanism.client.gui.GuiEnergyInfo; @@ -17,6 +19,9 @@ import mekanism.client.gui.GuiNumberGauge.INumberInfoHandler; import mekanism.client.gui.GuiPowerBar; import mekanism.client.gui.GuiSlot; import mekanism.client.gui.GuiSlot.SlotType; +import mekanism.client.sound.SoundHandler; +import mekanism.common.Mekanism; +import mekanism.common.network.PacketTileEntity.TileEntityMessage; import mekanism.common.util.MekanismUtils; import mekanism.common.util.MekanismUtils.ResourceType; import mekanism.generators.common.inventory.container.ContainerReactorController; @@ -48,101 +53,10 @@ public class GuiReactorController extends GuiMekanism "Storing: " + MekanismUtils.getEnergyDisplay(tileEntity.getEnergy()), "Max Output: " + MekanismUtils.getEnergyDisplay(tileEntity.getMaxOutput()) + "/t"); } - }, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"))); - guiElements.add(new GuiGasGauge(new IGasInfoHandler() - { - @Override - public GasTank getTank() - { - return tentity.deuteriumTank; - } - }, Type.SMALL, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 124, 6)); - guiElements.add(new GuiGasGauge(new IGasInfoHandler() - { - @Override - public GasTank getTank() - { - return tentity.tritiumTank; - } - }, Type.SMALL, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 124, 36)); - guiElements.add(new GuiGasGauge(new IGasInfoHandler() - { - @Override - public GasTank getTank() - { - return tentity.fuelTank; - } - }, Type.STANDARD, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 144, 6)); - guiElements.add(new GuiFluidGauge(new IFluidInfoHandler() - { - @Override - public FluidTank getTank() - { - return tentity.waterTank; - } - }, Type.SMALL, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 78, 46)); - guiElements.add(new GuiFluidGauge(new IFluidInfoHandler() - { - @Override - public FluidTank getTank() - { - return tentity.steamTank; - } - }, Type.SMALL, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 98, 46)); - guiElements.add(new GuiNumberGauge(new INumberInfoHandler() - { - @Override - public IIcon getIcon() - { - return BlockStaticLiquid.getLiquidIcon("lava_still"); - } - - @Override - public double getLevel() - { - return tileEntity.getPlasmaTemp(); - } - - @Override - public double getMaxLevel() - { - return 5E8; - } - - @Override - public String getText(double level) - { - return "Plasma: " + (int)(level+23) + "C"; - } - }, Type.STANDARD, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall"), 124, 76)); - guiElements.add(new GuiNumberGauge(new INumberInfoHandler() - { - @Override - public IIcon getIcon() - { - return BlockStaticLiquid.getLiquidIcon("lava_still"); - } - - @Override - public double getLevel() - { - return tileEntity.getCaseTemp(); - } - - @Override - public double getMaxLevel() - { - return 5E8; - } - - @Override - public String getText(double level) - { - return "Case: " + (int)(level+23) + "C"; - } - }, Type.STANDARD, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 144, 76)); - guiElements.add(new GuiPowerBar(this, tileEntity, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 164, 15)); - guiElements.add(new GuiSlot(SlotType.NORMAL, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 98, 26)); + }, this, MekanismUtils.getResource(ResourceType.GUI, "GuiBlank.png"))); + guiElements.add(new GuiSlot(SlotType.NORMAL, this, MekanismUtils.getResource(ResourceType.GUI, "GuiBlank.png"), 79, 38)); + guiElements.add(new GuiHeatTab(this, tileEntity, MekanismUtils.getResource(ResourceType.GUI, "GuiBlank.png"))); + guiElements.add(new GuiFuelTab(this, tileEntity, MekanismUtils.getResource(ResourceType.GUI, "GuiBlank.png"))); } @Override @@ -164,7 +78,7 @@ public class GuiReactorController extends GuiMekanism @Override protected void drawGuiContainerBackgroundLayer(float partialTick, int mouseX, int mouseY) { - mc.renderEngine.bindTexture(MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png")); + mc.renderEngine.bindTexture(MekanismUtils.getResource(ResourceType.GUI, "GuiBlank.png")); GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); int guiWidth = (width - xSize) / 2; int guiHeight = (height - ySize) / 2; @@ -172,4 +86,25 @@ public class GuiReactorController extends GuiMekanism super.drawGuiContainerBackgroundLayer(partialTick, mouseX, mouseY); } + + @Override + protected void mouseClicked(int x, int y, int button) + { + super.mouseClicked(x, y, button); + + if(button == 0) + { + int xAxis = (x - (width - xSize) / 2); + int yAxis = (y - (height - ySize) / 2); + + if(xAxis >= 48 && xAxis <= 128 && yAxis >= 5 && yAxis <= 17) + { + ArrayList data = new ArrayList(); + data.add(0); + + Mekanism.packetHandler.sendToServer(new TileEntityMessage(Coord4D.get(tileEntity), data)); + SoundHandler.playSound("gui.button.press"); + } + } + } } diff --git a/src/main/java/mekanism/generators/client/gui/GuiReactorFuel.java b/src/main/java/mekanism/generators/client/gui/GuiReactorFuel.java new file mode 100644 index 000000000..ac3e6e956 --- /dev/null +++ b/src/main/java/mekanism/generators/client/gui/GuiReactorFuel.java @@ -0,0 +1,117 @@ +package mekanism.generators.client.gui; + +import java.util.List; + +import mekanism.api.ListUtils; +import mekanism.api.gas.GasTank; +import mekanism.client.gui.GuiEnergyInfo; +import mekanism.client.gui.GuiEnergyInfo.IInfoHandler; +import mekanism.client.gui.GuiFluidGauge; +import mekanism.client.gui.GuiFluidGauge.IFluidInfoHandler; +import mekanism.client.gui.GuiGasGauge; +import mekanism.client.gui.GuiGasGauge.IGasInfoHandler; +import mekanism.client.gui.GuiGauge.Type; +import mekanism.client.gui.GuiMekanism; +import mekanism.client.gui.GuiNumberGauge; +import mekanism.client.gui.GuiNumberGauge.INumberInfoHandler; +import mekanism.client.gui.GuiPowerBar; +import mekanism.client.gui.GuiProgress; +import mekanism.client.gui.GuiProgress.IProgressInfoHandler; +import mekanism.client.gui.GuiProgress.ProgressBar; +import mekanism.client.gui.GuiSlot; +import mekanism.client.gui.GuiSlot.SlotType; +import mekanism.common.inventory.container.ContainerNull; +import mekanism.common.util.MekanismUtils; +import mekanism.common.util.MekanismUtils.ResourceType; +import mekanism.generators.common.inventory.container.ContainerReactorController; +import mekanism.generators.common.tile.reactor.TileEntityReactorController; + +import net.minecraft.block.BlockStaticLiquid; +import net.minecraft.entity.player.InventoryPlayer; +import net.minecraft.util.IIcon; +import net.minecraftforge.fluids.FluidTank; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; +import org.lwjgl.opengl.GL11; + +@SideOnly(Side.CLIENT) +public class GuiReactorFuel extends GuiMekanism +{ + public TileEntityReactorController tileEntity; + + public GuiReactorFuel(InventoryPlayer inventory, final TileEntityReactorController tentity) + { + super(new ContainerNull(inventory.player, tentity)); + tileEntity = tentity; + guiElements.add(new GuiEnergyInfo(new IInfoHandler() + { + @Override + public List getInfo() + { + return ListUtils.asList( + "Storing: " + MekanismUtils.getEnergyDisplay(tileEntity.getEnergy()), + "Max Output: " + MekanismUtils.getEnergyDisplay(tileEntity.getMaxOutput()) + "/t"); + } + }, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"))); + guiElements.add(new GuiGasGauge(new IGasInfoHandler() + { + @Override + public GasTank getTank() + { + return tentity.deuteriumTank; + } + }, Type.SMALL, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 25, 64)); + guiElements.add(new GuiGasGauge(new IGasInfoHandler() + { + @Override + public GasTank getTank() + { + return tentity.fuelTank; + } + }, Type.STANDARD, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 79, 50)); + guiElements.add(new GuiGasGauge(new IGasInfoHandler() + { + @Override + public GasTank getTank() + { + return tentity.tritiumTank; + } + }, Type.SMALL, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 133, 64)); + guiElements.add(new GuiProgress(new IProgressInfoHandler() + { + @Override + public double getProgress() + { + return tileEntity.getActive() ? 1 : 0; + } + }, ProgressBar.SMALL_RIGHT, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 45, 75)); + guiElements.add(new GuiProgress(new IProgressInfoHandler() + { + @Override + public double getProgress() + { + return tileEntity.getActive() ? 1 : 0; + } + }, ProgressBar.SMALL_LEFT, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 99, 75)); + } + + @Override + protected void drawGuiContainerForegroundLayer(int mouseX, int mouseY) + { + super.drawGuiContainerForegroundLayer(mouseX, mouseY); + + fontRendererObj.drawString(tileEntity.getInventoryName(), 6, 6, 0x404040); + } + + @Override + protected void drawGuiContainerBackgroundLayer(float partialTick, int mouseX, int mouseY) + { + mc.renderEngine.bindTexture(MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png")); + GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); + int guiWidth = (width - xSize) / 2; + int guiHeight = (height - ySize) / 2; + drawTexturedModalRect(guiWidth, guiHeight, 0, 0, xSize, ySize); + + super.drawGuiContainerBackgroundLayer(partialTick, mouseX, mouseY); + } +} diff --git a/src/main/java/mekanism/generators/client/gui/GuiReactorHeat.java b/src/main/java/mekanism/generators/client/gui/GuiReactorHeat.java new file mode 100644 index 000000000..c23ca7b3c --- /dev/null +++ b/src/main/java/mekanism/generators/client/gui/GuiReactorHeat.java @@ -0,0 +1,180 @@ +package mekanism.generators.client.gui; + +import java.util.List; + +import mekanism.api.ListUtils; +import mekanism.api.energy.IStrictEnergyStorage; +import mekanism.api.gas.GasTank; +import mekanism.client.gui.GuiEnergyGauge; +import mekanism.client.gui.GuiEnergyGauge.IEnergyInfoHandler; +import mekanism.client.gui.GuiEnergyInfo; +import mekanism.client.gui.GuiEnergyInfo.IInfoHandler; +import mekanism.client.gui.GuiFluidGauge; +import mekanism.client.gui.GuiFluidGauge.IFluidInfoHandler; +import mekanism.client.gui.GuiGasGauge; +import mekanism.client.gui.GuiGasGauge.IGasInfoHandler; +import mekanism.client.gui.GuiGauge.Type; +import mekanism.client.gui.GuiMekanism; +import mekanism.client.gui.GuiNumberGauge; +import mekanism.client.gui.GuiNumberGauge.INumberInfoHandler; +import mekanism.client.gui.GuiPowerBar; +import mekanism.client.gui.GuiProgress; +import mekanism.client.gui.GuiProgress.IProgressInfoHandler; +import mekanism.client.gui.GuiProgress.ProgressBar; +import mekanism.client.gui.GuiSlot; +import mekanism.client.gui.GuiSlot.SlotType; +import mekanism.common.inventory.container.ContainerNull; +import mekanism.common.util.MekanismUtils; +import mekanism.common.util.MekanismUtils.ResourceType; +import mekanism.generators.common.inventory.container.ContainerReactorController; +import mekanism.generators.common.tile.reactor.TileEntityReactorController; + +import net.minecraft.block.BlockStaticLiquid; +import net.minecraft.entity.player.InventoryPlayer; +import net.minecraft.util.IIcon; +import net.minecraftforge.fluids.FluidTank; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; +import org.lwjgl.opengl.GL11; + +@SideOnly(Side.CLIENT) +public class GuiReactorHeat extends GuiMekanism +{ + public TileEntityReactorController tileEntity; + + public GuiReactorHeat(InventoryPlayer inventory, final TileEntityReactorController tentity) + { + super(new ContainerNull(inventory.player, tentity)); + tileEntity = tentity; + guiElements.add(new GuiEnergyInfo(new IInfoHandler() + { + @Override + public List getInfo() + { + return ListUtils.asList( + "Storing: " + MekanismUtils.getEnergyDisplay(tileEntity.getEnergy()), + "Max Output: " + MekanismUtils.getEnergyDisplay(tileEntity.getMaxOutput()) + "/t"); + } + }, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"))); + guiElements.add(new GuiNumberGauge(new INumberInfoHandler() + { + @Override + public IIcon getIcon() + { + return BlockStaticLiquid.getLiquidIcon("lava_still"); + } + + @Override + public double getLevel() + { + return tileEntity.getPlasmaTemp(); + } + + @Override + public double getMaxLevel() + { + return 5E8; + } + + @Override + public String getText(double level) + { + return "Plasma: " + (int)(level+23) + "C"; + } + }, Type.STANDARD, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 7, 50)); + guiElements.add(new GuiProgress(new IProgressInfoHandler() + { + @Override + public double getProgress() + { + return tileEntity.getPlasmaTemp() > tileEntity.getCaseTemp() ? 1 : 0; + } + }, ProgressBar.SMALL_RIGHT, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 27, 75)); + guiElements.add(new GuiNumberGauge(new INumberInfoHandler() + { + @Override + public IIcon getIcon() + { + return BlockStaticLiquid.getLiquidIcon("lava_still"); + } + + @Override + public double getLevel() + { + return tileEntity.getCaseTemp(); + } + + @Override + public double getMaxLevel() + { + return 5E8; + } + + @Override + public String getText(double level) + { + return "Case: " + (int)(level+23) + "C"; + } + }, Type.STANDARD, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 61, 50)); + guiElements.add(new GuiProgress(new IProgressInfoHandler() + { + @Override + public double getProgress() + { + return tileEntity.getCaseTemp() > 0 ? 1 : 0; + } + }, ProgressBar.SMALL_RIGHT, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 81, 60)); + guiElements.add(new GuiProgress(new IProgressInfoHandler() + { + @Override + public double getProgress() + { + return (tileEntity.getCaseTemp() > 0 && tileEntity.waterTank.getFluidAmount() > 0 && tileEntity.steamTank.getFluidAmount() < tileEntity.steamTank.getCapacity()) ? 1 : 0; + } + }, ProgressBar.SMALL_RIGHT, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 81, 90)); + guiElements.add(new GuiFluidGauge(new IFluidInfoHandler() + { + @Override + public FluidTank getTank() + { + return tentity.waterTank; + } + }, Type.SMALL, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 115, 84)); + guiElements.add(new GuiFluidGauge(new IFluidInfoHandler() + { + @Override + public FluidTank getTank() + { + return tentity.steamTank; + } + }, Type.SMALL, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 151, 84)); + guiElements.add(new GuiEnergyGauge(new IEnergyInfoHandler() + { + @Override + public IStrictEnergyStorage getEnergyStorage() + { + return tileEntity; + } + }, Type.SMALL, this, MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png"), 115, 46)); + } + + @Override + protected void drawGuiContainerForegroundLayer(int mouseX, int mouseY) + { + super.drawGuiContainerForegroundLayer(mouseX, mouseY); + + fontRendererObj.drawString(tileEntity.getInventoryName(), 6, 6, 0x404040); + } + + @Override + protected void drawGuiContainerBackgroundLayer(float partialTick, int mouseX, int mouseY) + { + mc.renderEngine.bindTexture(MekanismUtils.getResource(ResourceType.GUI, "GuiTall.png")); + GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); + int guiWidth = (width - xSize) / 2; + int guiHeight = (height - ySize) / 2; + drawTexturedModalRect(guiWidth, guiHeight, 0, 0, xSize, ySize); + + super.drawGuiContainerBackgroundLayer(partialTick, mouseX, mouseY); + } +} diff --git a/src/main/java/mekanism/generators/common/GeneratorsCommonProxy.java b/src/main/java/mekanism/generators/common/GeneratorsCommonProxy.java index 2b316f330..e7b4ac667 100644 --- a/src/main/java/mekanism/generators/common/GeneratorsCommonProxy.java +++ b/src/main/java/mekanism/generators/common/GeneratorsCommonProxy.java @@ -1,6 +1,7 @@ package mekanism.generators.common; import mekanism.common.Mekanism; +import mekanism.common.inventory.container.ContainerNull; import mekanism.generators.common.inventory.container.ContainerBioGenerator; import mekanism.generators.common.inventory.container.ContainerHeatGenerator; import mekanism.generators.common.inventory.container.ContainerGasGenerator; @@ -124,6 +125,9 @@ public class GeneratorsCommonProxy case 10: return new ContainerReactorController(player.inventory, (TileEntityReactorController)tileEntity); case 11: + case 12: + return new ContainerNull(player, (TileEntityReactorController)tileEntity); + case 13: return new ContainerNeutronCapture(player.inventory, (TileEntityReactorNeutronCapture)tileEntity); } diff --git a/src/main/java/mekanism/generators/common/GeneratorsPacketHandler.java b/src/main/java/mekanism/generators/common/GeneratorsPacketHandler.java new file mode 100644 index 000000000..c69fe425f --- /dev/null +++ b/src/main/java/mekanism/generators/common/GeneratorsPacketHandler.java @@ -0,0 +1,183 @@ +package mekanism.generators.common; + +import io.netty.buffer.ByteBuf; + +import java.util.ArrayList; +import java.util.List; + +import mekanism.common.Mekanism; +import mekanism.generators.common.network.PacketGeneratorsGui; +import mekanism.generators.common.network.PacketGeneratorsGui.GeneratorsGuiMessage; + +import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.entity.player.EntityPlayerMP; +import net.minecraft.server.MinecraftServer; +import net.minecraft.util.AxisAlignedBB; +import net.minecraft.util.Vec3; +import cpw.mods.fml.common.network.NetworkRegistry; +import cpw.mods.fml.common.network.simpleimpl.IMessage; +import cpw.mods.fml.common.network.simpleimpl.MessageContext; +import cpw.mods.fml.common.network.simpleimpl.SimpleNetworkWrapper; +import cpw.mods.fml.relauncher.Side; + +/** + * Mekanism packet handler. As always, use packets sparingly! + * @author AidanBrady + * + */ +public class GeneratorsPacketHandler +{ + public SimpleNetworkWrapper netHandler = NetworkRegistry.INSTANCE.newSimpleChannel("MEKGEN"); + + public void initialize() + { + netHandler.registerMessage(PacketGeneratorsGui.class, GeneratorsGuiMessage.class, 0, Side.SERVER); + netHandler.registerMessage(PacketGeneratorsGui.class, GeneratorsGuiMessage.class, 0, Side.CLIENT); + } + + /** + * Encodes an Object[] of data into a DataOutputStream. + * @param dataValues - an Object[] of data to encode + * @param output - the output stream to write to + */ + public static void encode(Object[] dataValues, ByteBuf output) + { + try { + for(Object data : dataValues) + { + if(data instanceof Integer) + { + output.writeInt((Integer)data); + } + else if(data instanceof Boolean) + { + output.writeBoolean((Boolean)data); + } + else if(data instanceof Double) + { + output.writeDouble((Double)data); + } + else if(data instanceof Float) + { + output.writeFloat((Float)data); + } + else if(data instanceof String) + { + writeString(output, (String)data); + } + else if(data instanceof Byte) + { + output.writeByte((Byte)data); + } + else if(data instanceof int[]) + { + for(int i : (int[])data) + { + output.writeInt(i); + } + } + else if(data instanceof byte[]) + { + for(byte b : (byte[])data) + { + output.writeByte(b); + } + } + else if(data instanceof ArrayList) + { + encode(((ArrayList)data).toArray(), output); + } + } + } catch(Exception e) { + Mekanism.logger.error("Error while encoding packet data."); + e.printStackTrace(); + } + } + + public static void writeString(ByteBuf output, String s) + { + output.writeInt(s.getBytes().length); + output.writeBytes(s.getBytes()); + } + + public static String readString(ByteBuf input) + { + return new String(input.readBytes(input.readInt()).array()); + } + + public static EntityPlayer getPlayer(MessageContext context) + { + return Mekanism.proxy.getPlayer(context); + } + + /** + * Send this message to everyone. + * @param message - the message to send + */ + public void sendToAll(IMessage message) + { + netHandler.sendToAll(message); + } + + /** + * Send this message to the specified player. + * @param message - the message to send + * @param player - the player to send it to + */ + public void sendTo(IMessage message, EntityPlayerMP player) + { + netHandler.sendTo(message, player); + } + + /** + * Send this message to everyone within a certain range of a point. + * + * @param message - the message to send + * @param point - the TargetPoint around which to send + */ + public void sendToAllAround(IMessage message, NetworkRegistry.TargetPoint point) + { + netHandler.sendToAllAround(message, point); + } + + /** + * Send this message to everyone within the supplied dimension. + * @param message - the message to send + * @param dimensionId - the dimension id to target + */ + public void sendToDimension(IMessage message, int dimensionId) + { + netHandler.sendToDimension(message, dimensionId); + } + + /** + * Send this message to the server. + * @param message - the message to send + */ + public void sendToServer(IMessage message) + { + netHandler.sendToServer(message); + } + + /** + * Send this message to all players within a defined AABB cuboid. + * @param message - the message to send + * @param cuboid - the AABB cuboid to send the packet in + * @param dimId - the dimension the cuboid is in + */ + public void sendToCuboid(IMessage message, AxisAlignedBB cuboid, int dimId) + { + MinecraftServer server = MinecraftServer.getServer(); + + if(server != null && cuboid != null) + { + for(EntityPlayerMP player : (List)server.getConfigurationManager().playerEntityList) + { + if(player.dimension == dimId && cuboid.isVecInside(Vec3.createVectorHelper(player.posX, player.posY, player.posZ))) + { + sendTo(message, player); + } + } + } + } +} diff --git a/src/main/java/mekanism/generators/common/MekanismGenerators.java b/src/main/java/mekanism/generators/common/MekanismGenerators.java index fd3b4d8b1..aba5f887e 100644 --- a/src/main/java/mekanism/generators/common/MekanismGenerators.java +++ b/src/main/java/mekanism/generators/common/MekanismGenerators.java @@ -42,6 +42,9 @@ import cpw.mods.fml.common.registry.GameRegistry; @Mod(modid = "MekanismGenerators", name = "MekanismGenerators", version = "8.0.0", dependencies = "required-after:Mekanism", guiFactory = "mekanism.generators.client.gui.GeneratorsGuiFactory") public class MekanismGenerators implements IModule { + /** Mekanism Generators Packet Pipeline */ + public static GeneratorsPacketHandler packetHandler = new GeneratorsPacketHandler(); + @SidedProxy(clientSide = "mekanism.generators.client.GeneratorsClientProxy", serverSide = "mekanism.generators.common.GeneratorsCommonProxy") public static GeneratorsCommonProxy proxy; @@ -90,6 +93,8 @@ public class MekanismGenerators implements IModule { //Add this module to the core list Mekanism.modulesLoaded.add(this); + + packetHandler.initialize(); //Set up the GUI handler NetworkRegistry.INSTANCE.registerGuiHandler(this, new GeneratorsGuiHandler()); diff --git a/src/main/java/mekanism/generators/common/block/BlockReactor.java b/src/main/java/mekanism/generators/common/block/BlockReactor.java index 71e5fbb11..e65a0002e 100644 --- a/src/main/java/mekanism/generators/common/block/BlockReactor.java +++ b/src/main/java/mekanism/generators/common/block/BlockReactor.java @@ -260,7 +260,7 @@ public class BlockReactor extends BlockContainer CONTROLLER(MekanismGenerators.Reactor, 0, "ReactorController", 10, TileEntityReactorController.class), FRAME(MekanismGenerators.Reactor, 1, "ReactorFrame", -1, TileEntityReactorFrame.class), LASER_FOCUS_MATRIX(MekanismGenerators.Reactor, 2, "ReactorLaserFocusMatrix", -1, TileEntityReactorLaserFocusMatrix.class), - NEUTRON_CAPTURE(MekanismGenerators.Reactor, 3, "ReactorNeutronCapturePlate", 11, TileEntityReactorNeutronCapture.class), + NEUTRON_CAPTURE(MekanismGenerators.Reactor, 3, "ReactorNeutronCapturePlate", 13, TileEntityReactorNeutronCapture.class), PORT(MekanismGenerators.Reactor, 4, "ReactorInOutPort", -1, TileEntityReactorPort.class), GLASS(MekanismGenerators.ReactorGlass, 0, "ReactorGlass", -1, TileEntityReactorGlass.class); diff --git a/src/main/java/mekanism/generators/common/inventory/container/ContainerReactorController.java b/src/main/java/mekanism/generators/common/inventory/container/ContainerReactorController.java index 91808e4b8..89fc4bce5 100644 --- a/src/main/java/mekanism/generators/common/inventory/container/ContainerReactorController.java +++ b/src/main/java/mekanism/generators/common/inventory/container/ContainerReactorController.java @@ -18,9 +18,17 @@ public class ContainerReactorController extends Container public ContainerReactorController(InventoryPlayer inventory, TileEntityReactorController tentity) { tileEntity = tentity; - addSlotToContainer(new Slot(tentity, 0, 99, 27)); + addSlotToContainer(new Slot(tentity, 0, 80, 39)); 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)); diff --git a/src/main/java/mekanism/generators/common/network/PacketGeneratorsGui.java b/src/main/java/mekanism/generators/common/network/PacketGeneratorsGui.java new file mode 100644 index 000000000..e12e3bff0 --- /dev/null +++ b/src/main/java/mekanism/generators/common/network/PacketGeneratorsGui.java @@ -0,0 +1,114 @@ +package mekanism.generators.common.network; + +import io.netty.buffer.ByteBuf; +import mekanism.api.Coord4D; +import mekanism.generators.common.GeneratorsPacketHandler; +import mekanism.common.tile.TileEntityBasicBlock; +import mekanism.generators.common.MekanismGenerators; +import mekanism.generators.common.network.PacketGeneratorsGui.GeneratorsGuiMessage; + +import net.minecraft.client.gui.GuiScreen; +import net.minecraft.entity.player.EntityPlayer; +import net.minecraft.entity.player.EntityPlayerMP; +import net.minecraft.world.World; +import cpw.mods.fml.common.FMLCommonHandler; +import cpw.mods.fml.common.network.simpleimpl.IMessage; +import cpw.mods.fml.common.network.simpleimpl.IMessageHandler; +import cpw.mods.fml.common.network.simpleimpl.MessageContext; +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; + +public class PacketGeneratorsGui implements IMessageHandler +{ + @Override + public IMessage onMessage(GeneratorsGuiMessage message, MessageContext context) + { + EntityPlayer player = GeneratorsPacketHandler.getPlayer(context); + + if(!player.worldObj.isRemote) + { + World worldServer = FMLCommonHandler.instance().getMinecraftServerInstance().worldServerForDimension(message.coord4D.dimensionId); + + if(worldServer != null && message.coord4D.getTileEntity(worldServer) instanceof TileEntityBasicBlock) + { + if(message.guiId == -1) + { + return null; + } + + GeneratorsGuiMessage.openServerGui(message.guiId, (EntityPlayerMP)player, player.worldObj, message.coord4D); + } + } + else { + FMLCommonHandler.instance().showGuiScreen(GeneratorsGuiMessage.getGui(message.guiId, player, player.worldObj, message.coord4D)); + player.openContainer.windowId = message.windowId; + } + + return null; + } + + public static class GeneratorsGuiMessage implements IMessage + { + public Coord4D coord4D; + + public int guiId; + + public int windowId; + + public GeneratorsGuiMessage() {} + + public GeneratorsGuiMessage(Coord4D coord, int gui) + { + coord4D = coord; + guiId = gui; + } + + public GeneratorsGuiMessage(Coord4D coord, int gui, int id) + { + this(coord, gui); + windowId = id; + } + + public static void openServerGui(int id, EntityPlayerMP playerMP, World world, Coord4D obj) + { + playerMP.closeContainer(); + playerMP.getNextWindowId(); + + int window = playerMP.currentWindowId; + + MekanismGenerators.packetHandler.sendTo(new GeneratorsGuiMessage(obj, id, window), playerMP); + + playerMP.openContainer = MekanismGenerators.proxy.getServerGui(id, playerMP, world, obj.xCoord, obj.yCoord, obj.zCoord); + playerMP.openContainer.windowId = window; + playerMP.openContainer.addCraftingToCrafters(playerMP); + } + + @SideOnly(Side.CLIENT) + public static GuiScreen getGui(int id, EntityPlayer player, World world, Coord4D obj) + { + return (GuiScreen)MekanismGenerators.proxy.getClientGui(id, player, world, obj.xCoord, obj.yCoord, obj.zCoord); + } + + @Override + public void toBytes(ByteBuf dataStream) + { + dataStream.writeInt(coord4D.xCoord); + dataStream.writeInt(coord4D.yCoord); + dataStream.writeInt(coord4D.zCoord); + + dataStream.writeInt(coord4D.dimensionId); + + dataStream.writeInt(guiId); + dataStream.writeInt(windowId); + } + + @Override + public void fromBytes(ByteBuf dataStream) + { + coord4D = new Coord4D(dataStream.readInt(), dataStream.readInt(), dataStream.readInt(), dataStream.readInt()); + + guiId = dataStream.readInt(); + windowId = dataStream.readInt(); + } + } +} diff --git a/src/main/java/mekanism/generators/common/tile/reactor/TileEntityReactorController.java b/src/main/java/mekanism/generators/common/tile/reactor/TileEntityReactorController.java index 161cc1e8d..4b9aacf54 100644 --- a/src/main/java/mekanism/generators/common/tile/reactor/TileEntityReactorController.java +++ b/src/main/java/mekanism/generators/common/tile/reactor/TileEntityReactorController.java @@ -109,7 +109,20 @@ public class TileEntityReactorController extends TileEntityReactorBlock implemen @Override public void handlePacketData(ByteBuf dataStream) { + if(!worldObj.isRemote) + { + int type = dataStream.readInt(); + + if(type == 0) + { + formMultiblock(); + } + + return; + } + super.handlePacketData(dataStream); + boolean formed = dataStream.readBoolean(); if(formed) { diff --git a/src/main/resources/assets/mekanism/gui/GuiTall.png b/src/main/resources/assets/mekanism/gui/GuiTall.png index f1edcc4d357100ef755e88e0131f73fd9e1134dc..5e44ebf6c411d2872a16561ba66c5f451b51c341 100644 GIT binary patch delta 248 zcmZqS+sL~im?cGqnOUYVHAt3$fyvI(#WAGf*4t~|d`^lYE(iA=o4fbwM%B0oX}-Tc zM_smL9ofOG9`Y_Nfj_lrtMfU_z4c~0w}dKfIC1oGy7}I6`)jTC4a*tkJkJ!}7nQB+ zX>{y^aKs1Z4?i3yPh{1aynt02h`A>lv6_L{i~^GlSB)7qWRz-oVByae#jZ YW0;*Px69hyzZrnQ)78&qol`;+0C?nDU;qFB delta 341 zcmdnU+rqaYn5AA!Oh>%&w-Gx71JguL7srr_TW{|e<~18gv^_i@>c?iC{!r}1^+c9J zv+}N6dXh~`+n!Wj^RS=P952b{Rk!7UsfhQ5a>eNEZ}#FlGra{H{r2V5txLOYrhctY zy}_RG#`n9cK3vLL>pAJM#T*u^ISe^<0t^le42%pc3}D9O`>gVlC$P#+ZeV4fY{aSo zq_xp#A>#$zw-?Jlue7Ue%$&7p-D=BcHn!;!Y}Q}xnF{_hpNp8L`g+%_w{`StX57~gxMk57*5dtvX+u53q$QC;dR6ZyJFrEGOaEZI XKBx1(y0}LN0}yz+`njxgN@xNA7LUIRZp5g41!Yb!hzJInxh1yO9>tdLJk2bDk4FU z0FfqyBDokiYADh{5=tOSKnRhRgqjck#Ds-u0~;|0jho96Y*toKTa(95o7O`<)n{G> zw*>5I2s0tIth-AonK6(h2j=PQOsbIEwz?+Z_M81RiSUZyn(Rdmqkpy9x$%RvPoR^+5qiFS5*A9T7?a+czERKCgzu8>&|ICD@7jU9p*MMbMG$l_0>sr2pCYG0KaPn&tIkRH(anHc7& z)it;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L8?|yiIX)R9{hpcx`LNf(q&I?Zxsni$-Oqg8Xi{%D~UWW z1*;TB9Bsy#Lhq=0{_wE()D~qA?3w3lFZ*crZxKJ> zq=Aui^c_@XWo1WOo0)*t)djb(pg^?fd90XIwiF!zh5`=_d}FRh2YSyg3; zL~=o`N8A%+P<>>a^E#>2?{pgkT3*CO`ch(r>|`xn$@e3w<0B&U;3ZiyfaY~@CLTp0 zH=Pu!j}Qcgl&{dh=b90qqFCajND>~kSofgmf{>m)5=jhtdzgZi0^C2u$=7&LxE1Z3 oju>U)q~?6=_b2E7RQTq6@w}l5OR~Pm{Pz*9EN@#>U-$g`f8gq{2mk;8 literal 0 HcmV?d00001 diff --git a/src/main/resources/assets/mekanism/gui/elements/GuiHeatTab.png b/src/main/resources/assets/mekanism/gui/elements/GuiHeatTab.png new file mode 100644 index 0000000000000000000000000000000000000000..ca54790d665541919a89398ea940f53c5ad08e9c GIT binary patch literal 2598 zcmds1i8I@Y7ym|)7Ny6Qx~eT*gpFFXG%74wLaL3TRYzCVv5vTpI-;vfvC0y(?owBj zI)ZhERY!_Cf)Gc7O4>#!AqiQs`uj6}@0j=IGxKKNXWpAn((PL}kBiBP0RV8^(!vY{ z0HDJb1RNDTEKWg{9sqD;+uPLiwxy}*`P)Hg4{zVc01!b*#g3wXczkvM-p>B`_Lx4{ z7L?MH1dmJqrTJmHs7ZMHQ1k5}k2$xwmoHgsa|`vP+0BC4E#>Qhv_-gst+!V#`v&$Ar80EZWy$_Z!JcnaI!W8?6+0K?u5zH#*NZ5jp^4! z+kE&C;T7pRhS%rB^hoK?sFl;1=|myt9W^N6Y-F1xznE(R+)7b zK3A3kLbBedW<7e4g<6DE)A1`Go-GVG2}X68&DlFwKtA!W{xa>hw@~z{e2P%OxH+UK zcc-McttIY?)ybkTc#r;|?kg5>y&B0s&3W6^s&b`hA?A7K;D36?^)dhC$r&k3m5&bV zO4+#$KZboS5-v>K9!XG8NdDJr(*5<(?YQQuak=NaP4PYR7J;uAW~CVY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!u*@heE!~|7YPBZmRxz(JcO3usv?KCQuS)UPSS&yPVr)n3{@#3K3>95? zMqhC^ubjBN{R%`|W&pLi;xEh9RaI3Ph^N7KzHIY0Hv^?p`Z^%MT7c-c2mT9fdYG=j zmHzy7t(>8^_SJ`xpP%pb)69+pZLN}k+>uE!_h0NVzz_;{waPxxXy+}lK!CH5F-e#0 zi&0;lpQbfd9bA^U0`!E60UO~QRs*ehg%G7Y<`H>&Uy7^(C@3nfvgTS2zJ9|jLt18# ku!zw^sr!GmqGtk-ir!ZQ?zj5q-#J>E-!iNH<>BxD0fyPshX4Qo literal 0 HcmV?d00001 diff --git a/src/main/resources/assets/mekanism/gui/elements/GuiProgress.png b/src/main/resources/assets/mekanism/gui/elements/GuiProgress.png index 72359f0f62cb88ad68b43b1e36aafea23d431e2f..3cef60021eab18220ba2bbedb4487d801ad87bae 100644 GIT binary patch literal 5055 zcmaJ_2UJs8x4sEgn#>Fc(vc!XAZS3OhE7015JL$N9Ex;ML^=c=_*SmM!d+ypf``mBuZ(oa|f~O>Xw9Q}`YWJXe$!`=*#%O~s&i z$FkpR6x*!bqP~-M(`qNpRD-=xf_?G5d}(~1cFxUlHo=^Lm#lXd!r+4Qh`g$>4U;i( zLtCO|yw;bwst)PshY#lqIg;M3D29l%)%!K@x4l$Rs(I?Td(gG5yuD{<_v8uOg!not zYH{lGvj_nGJYKl&a4FyCz)@3EljqSmD;*2Zi{!wyYG!ZQf2E0CXKHfN1N8dcD<=}% zRu&hHKbRLBkhhg@MGK8p;0?1~`C>=|las{;iPCL8)(+P%)2P2$xv8RJeMCGmh`oZr z$!JHj`Qt7L<3+3!G|U)yklQ9Z*0Zhyu~*Dq&J`=S;=|MI6C^N^j3%ZDL1z8p0bG9o zf+fSi3+@9(nc9>XwNrD?+RX^%o;YFu7ya zkE=5_Wri5vCMCs9E9hsMl)9ts?Ch@JxmUEDS5t$oaPN5ZKBHz5G%q(dmpv5AXm^$t z6H;M-)0J#yW)7<|{%FbiIwnR}$#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