diff --git a/build.gradle b/build.gradle index afe56bbc7..96f2c62bc 100644 --- a/build.gradle +++ b/build.gradle @@ -125,7 +125,7 @@ dependencies { compile "com.github.azanor:baubles:1.1.3.0:deobf@jar" compile name: "CraftTweaker", version: "1.8.8-3.0.0", classifier: "Dev" // shade 'IC2-Classic-API-STANDALONE:IC2-Classic-API-STANDALONE:1.1.0.19-5:api' - deobfCompile 'RebornCore:RebornCore-1.8.9:1.4.4.+:universal' + deobfCompile 'RebornCore:RebornCore-1.8.9:1.4.5.+:universal' deobfCompile "mezz.jei:jei_1.8.9:2.27.+" deobfCompile 'MCMultiPart:MCMultiPart:1.0.8:universal' diff --git a/src/main/java/techreborn/parts/EnumCableType.java b/src/main/java/techreborn/parts/EnumCableType.java index 660fdeaf4..15c9dc1ec 100644 --- a/src/main/java/techreborn/parts/EnumCableType.java +++ b/src/main/java/techreborn/parts/EnumCableType.java @@ -1,17 +1,18 @@ package techreborn.parts; import net.minecraft.util.IStringSerializable; +import reborncore.api.power.EnumPowerTier; import techreborn.parts.types.*; public enum EnumCableType implements IStringSerializable { - COPPER("copper", "techreborn:blocks/cables/copper_cable", 128, 12.0, true, CopperCable.class), - TIN("tin", "techreborn:blocks/cables/tin_cable", 32, 12.0, true, TinCable.class), - GOLD("gold", "techreborn:blocks/cables/gold_cable", 512, 12.0, true, GoldCable.class), - HV("hv", "techreborn:blocks/cables/hv_cable", 2048, 12.0, true, HVCable.class), - GLASSFIBER("glassfiber", "techreborn:blocks/cables/glass_fiber_cable", 8192, 12.0, false, GlassFiberCable.class), - ICOPPER("insulatedcopper", "techreborn:blocks/cables/copper_insulated_cable", 128, 10.0, false, InsulatedCopperCable.class), - IGOLD("insulatedgold", "techreborn:blocks/cables/gold_insulated_cable", 512, 10.0, false, InsulatedGoldCable.class), - IHV("insulatedhv", "techreborn:blocks/cables/hv_insulated_cable", 2048, 10.0, false, InsulatedHVCable.class); + COPPER("copper", "techreborn:blocks/cables/copper_cable", 128, 12.0, true, CopperCable.class, EnumPowerTier.LOW), + TIN("tin", "techreborn:blocks/cables/tin_cable", 32, 12.0, true, TinCable.class, EnumPowerTier.MEDIUM), + GOLD("gold", "techreborn:blocks/cables/gold_cable", 512, 12.0, true, GoldCable.class, EnumPowerTier.MEDIUM), + HV("hv", "techreborn:blocks/cables/hv_cable", 2048, 12.0, true, HVCable.class, EnumPowerTier.HIGH), + GLASSFIBER("glassfiber", "techreborn:blocks/cables/glass_fiber_cable", 8192, 12.0, false, GlassFiberCable.class, EnumPowerTier.HIGH), + ICOPPER("insulatedcopper", "techreborn:blocks/cables/copper_insulated_cable", 128, 10.0, false, InsulatedCopperCable.class, EnumPowerTier.LOW), + IGOLD("insulatedgold", "techreborn:blocks/cables/gold_insulated_cable", 512, 10.0, false, InsulatedGoldCable.class, EnumPowerTier.HIGH), + IHV("insulatedhv", "techreborn:blocks/cables/hv_insulated_cable", 2048, 10.0, false, InsulatedHVCable.class, EnumPowerTier.HIGH); private String friendlyName; public String textureName = "minecraft:blocks/iron_block"; @@ -19,14 +20,16 @@ public enum EnumCableType implements IStringSerializable { public double cableThickness = 3.0; public boolean canKill = false; public Class cableClass; + public EnumPowerTier tier; - EnumCableType(String friendlyName, String textureName, int transferRate, double cableThickness, boolean canKill, Class cableClass) { + EnumCableType(String friendlyName, String textureName, int transferRate, double cableThickness, boolean canKill, Class cableClass, EnumPowerTier tier) { this.friendlyName = friendlyName; this.textureName = textureName; this.transferRate = transferRate; this.cableThickness = cableThickness / 2; this.canKill = canKill; this.cableClass = cableClass; + this.tier = tier; } @Override diff --git a/src/main/java/techreborn/parts/ItemCables.java b/src/main/java/techreborn/parts/ItemCables.java index 5b68748c3..353c4defe 100644 --- a/src/main/java/techreborn/parts/ItemCables.java +++ b/src/main/java/techreborn/parts/ItemCables.java @@ -84,5 +84,6 @@ public class ItemCables extends ItemMultiPart implements ITexturedItem { if (type.canKill) { tooltip.add(EnumChatFormatting.RED + "Damages entity's!"); } + tooltip.add(EnumChatFormatting.GREEN + "Tier: " + EnumChatFormatting.LIGHT_PURPLE + type.tier); } } \ No newline at end of file diff --git a/src/main/java/techreborn/power/TRPowerNet.java b/src/main/java/techreborn/power/TRPowerNet.java index 75d79f398..4d488f72d 100644 --- a/src/main/java/techreborn/power/TRPowerNet.java +++ b/src/main/java/techreborn/power/TRPowerNet.java @@ -1,11 +1,11 @@ package techreborn.power; +import net.minecraft.entity.item.EntityTNTPrimed; +import net.minecraft.tileentity.TileEntity; import net.minecraft.util.EnumFacing; import net.minecraftforge.common.MinecraftForge; import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; import reborncore.api.power.IEnergyInterfaceTile; -import reborncore.common.powerSystem.TilePowerAcceptor; -import techreborn.events.TRTickHandler; import techreborn.parts.CableMultipart; import techreborn.parts.EnumCableType; @@ -13,226 +13,224 @@ import java.util.ArrayList; import java.util.List; public class TRPowerNet { - int tick = 0; - private ArrayList cables = new ArrayList(); - public ArrayList endpoints = new ArrayList(); - private int energy = 0; - EnumCableType cableType; + int tick = 0; + private ArrayList cables = new ArrayList(); + public ArrayList endpoints = new ArrayList(); + private int energy = 0; + EnumCableType cableType; - public TRPowerNet(EnumCableType cableType) { - this.cableType = cableType; - MinecraftForge.EVENT_BUS.register(this); - } + public TRPowerNet(EnumCableType cableType) { + this.cableType = cableType; + MinecraftForge.EVENT_BUS.register(this); + } - public int getIOLimit() { - return cableType.transferRate; - } + public int getIOLimit() { + return cableType.transferRate; + } - @SubscribeEvent - public void tick(PowerTickEvent evt) { - if(tick < 20){ - tick ++; - return; - } - if(tick % 80 == 0){ - List oldCables = new ArrayList<>(); - for(CableMultipart cableMultipart : cables){ - if(cableMultipart.getWorld() == null || cableMultipart.getPos() == null){ - oldCables.add(cableMultipart); - } - CableMultipart mp = cableMultipart.getPartFromWorld(cableMultipart.getWorld(), cableMultipart.getPos(), null); - if(mp == null){ - oldCables.add(cableMultipart); - } - } - cables.removeAll(oldCables); - } - if (!cables.isEmpty()) { - ArrayList collectibles = new ArrayList(); - ArrayList insertibles = new ArrayList(); - for (int i = 0; i < endpoints.size(); i++) { - EnergyHandler ei = endpoints.get(i); - if (ei.isCollectible()) { - collectibles.add(ei); - } - if (ei.isInsertible()) { - insertibles.add(ei); - } - } + @SubscribeEvent + public void tick(PowerTickEvent evt) { + if (tick < 20) { + tick++; + return; + } + if (tick % 80 == 0) { + List oldCables = new ArrayList<>(); + for (CableMultipart cableMultipart : cables) { + if (cableMultipart.getWorld() == null || cableMultipart.getPos() == null) { + oldCables.add(cableMultipart); + } + CableMultipart mp = cableMultipart.getPartFromWorld(cableMultipart.getWorld(), cableMultipart.getPos(), null); + if (mp == null) { + oldCables.add(cableMultipart); + } + } + cables.removeAll(oldCables); + } + if (!cables.isEmpty()) { + ArrayList collectibles = new ArrayList(); + ArrayList insertibles = new ArrayList(); + for (int i = 0; i < endpoints.size(); i++) { + EnergyHandler ei = endpoints.get(i); + if (ei.isCollectible()) { + collectibles.add(ei); + } + if (ei.isInsertible()) { + insertibles.add(ei); + } + } - for(EnergyHandler handler : collectibles){ - energy += handler.collectEnergy(cableType.transferRate); - } + for (EnergyHandler handler : collectibles) { + energy += handler.collectEnergy(cableType.transferRate); + } - for(EnergyHandler handler : insertibles){ - energy -= handler.addEnergy(Math.min(energy, cableType.transferRate)); - } - } else { - MinecraftForge.EVENT_BUS.unregister(this); - } - tick ++; - } + for (EnergyHandler handler : insertibles) { + energy -= handler.addEnergy(Math.min(energy, cableType.transferRate)); + } + } else { + MinecraftForge.EVENT_BUS.unregister(this); + } + tick++; + } - public void addElement(CableMultipart te) { - if (!cables.contains(te)) { - cables.add(te); - } - } + public void addElement(CableMultipart te) { + if (!cables.contains(te)) { + cables.add(te); + } + } - public void removeElement(CableMultipart te) { - cables.remove(te); - this.rebuild(); - } + public void removeElement(CableMultipart te) { + cables.remove(te); + this.rebuild(); + } - private void rebuild() { - for (int i = 0; i < cables.size(); i++) { - CableMultipart te = cables.get(i); - te.setNetwork(null); - te.findAndJoinNetwork(te.getWorld(), te.getPos()); - } - this.clear(true); - MinecraftForge.EVENT_BUS.unregister(this); - } + private void rebuild() { + for (int i = 0; i < cables.size(); i++) { + CableMultipart te = cables.get(i); + te.setNetwork(null); + te.findAndJoinNetwork(te.getWorld(), te.getPos()); + } + this.clear(true); + MinecraftForge.EVENT_BUS.unregister(this); + } - public void addConnection(IEnergyInterfaceTile ih, EnumFacing dir) { - if (ih instanceof CableMultipart) - return; - EnergyHandler has = this.getHandleFrom(ih); - if (has == null) { - endpoints.add(new EnergyHandler(ih, cableType, dir)); - } else { - has.side = dir; - } - } + public void addConnection(IEnergyInterfaceTile ih, EnumFacing dir) { + if (ih instanceof CableMultipart) + return; + EnergyHandler has = this.getHandleFrom(ih); + if (has == null) { + endpoints.add(new EnergyHandler(ih, cableType, dir)); + } else { + has.side = dir; + } + } - public void merge(TRPowerNet n) { - if (n != this) { - ArrayList li = new ArrayList(); - for (int i = 0; i < n.cables.size(); i++) { - CableMultipart wire = n.cables.get(i); - li.add(wire); - } - for (int i = 0; i < n.endpoints.size(); i++) { - EnergyHandler ei = n.endpoints.get(i); - EnergyHandler has = this.getHandleFrom(ei.tile); - if (has == null) { - endpoints.add(ei); - } - } - n.clear(false); - for (int i = 0; i < li.size(); i++) { - CableMultipart wire = li.get(i); - wire.setNetwork(this); - } - MinecraftForge.EVENT_BUS.unregister(n); - } - } + public void merge(TRPowerNet n) { + if (n != this) { + ArrayList li = new ArrayList(); + for (int i = 0; i < n.cables.size(); i++) { + CableMultipart wire = n.cables.get(i); + li.add(wire); + } + for (int i = 0; i < n.endpoints.size(); i++) { + EnergyHandler ei = n.endpoints.get(i); + EnergyHandler has = this.getHandleFrom(ei.tile); + if (has == null) { + endpoints.add(ei); + } + } + n.clear(false); + for (int i = 0; i < li.size(); i++) { + CableMultipart wire = li.get(i); + wire.setNetwork(this); + } + MinecraftForge.EVENT_BUS.unregister(n); + } + } - private EnergyHandler getHandleFrom(IEnergyInterfaceTile tile) { - for (int i = 0; i < endpoints.size(); i++) { - EnergyHandler ei = endpoints.get(i); - if (ei.contains(tile)) - return ei; - } - return null; - } + private EnergyHandler getHandleFrom(IEnergyInterfaceTile tile) { + for (int i = 0; i < endpoints.size(); i++) { + EnergyHandler ei = endpoints.get(i); + if (ei.contains(tile)) + return ei; + } + return null; + } - private void clear(boolean clearTiles) { - if (clearTiles) { - for (int i = 0; i < cables.size(); i++) { - cables.get(i).resetNetwork(); - } - } + private void clear(boolean clearTiles) { + if (clearTiles) { + for (int i = 0; i < cables.size(); i++) { + cables.get(i).resetNetwork(); + } + } - cables.clear(); - endpoints.clear(); - energy = 0; + cables.clear(); + endpoints.clear(); + energy = 0; - MinecraftForge.EVENT_BUS.unregister(this); - } + MinecraftForge.EVENT_BUS.unregister(this); + } - @Override - public String toString() { - return cables.size() + ": " + endpoints.toString(); - } + @Override + public String toString() { + return cables.size() + ": " + endpoints.toString(); + } - public int addEnergy(int maxAdd, boolean simulate) { - if (energy >= this.getIOLimit()) - return 0; - maxAdd = Math.min(this.getIOLimit(), maxAdd); - if (!simulate) - energy += maxAdd; - return maxAdd; - } + public int addEnergy(int maxAdd, boolean simulate) { + if (energy >= this.getIOLimit()) + return 0; + maxAdd = Math.min(this.getIOLimit(), maxAdd); + if (!simulate) + energy += maxAdd; + return maxAdd; + } - private static class EnergyHandler { - private final IEnergyInterfaceTile tile; - private EnumFacing side ; - private final EnumCableType type; + private static class EnergyHandler { + private final IEnergyInterfaceTile tile; + private EnumFacing side; + private final EnumCableType type; - private EnergyHandler(IEnergyInterfaceTile ih, EnumCableType type, EnumFacing dir) { - tile = ih; - this.type = type; - this.side = dir; - } + private EnergyHandler(IEnergyInterfaceTile ih, EnumCableType type, EnumFacing dir) { + tile = ih; + this.type = type; + this.side = dir; + } - public boolean isInsertible() { - return this.getTotalInsertible() > 0; - } + public boolean isInsertible() { + return this.getTotalInsertible() > 0; + } - public boolean isCollectible() { - return this.getTotalCollectible() > 0; - } + public boolean isCollectible() { + return this.getTotalCollectible() > 0; + } - public boolean contains(IEnergyInterfaceTile tile) { - return tile == this.tile; - } + public boolean contains(IEnergyInterfaceTile tile) { + return tile == this.tile; + } - public int collectEnergy(int max) { - int total = 0; - if (tile.canProvideEnergy(EnumFacing.NORTH)) { - int collect = (int) Math.min(max, tile.getMaxOutput()); - total = (int) tile.useEnergy(collect, false); - } - return total; - } + public int collectEnergy(int max) { + int total = 0; + if (tile.canProvideEnergy(EnumFacing.NORTH)) { + int collect = (int) Math.min(max, tile.getMaxOutput()); + total = (int) tile.useEnergy(collect, false); + } + return total; + } - public int addEnergy(int max) { - int total = 0; - if (tile.canAcceptEnergy(EnumFacing.NORTH)) { - if(type.transferRate > tile.getMaxInput()){ - if(tile instanceof TilePowerAcceptor){ - ((TilePowerAcceptor) tile).getWorld().createExplosion(null, ((TilePowerAcceptor) tile).getPos().getX(), ((TilePowerAcceptor) tile).getPos().getY(), ((TilePowerAcceptor) tile).getPos().getZ(), 5F, true); - } - return 0; - } - int add = max - total; - total += tile.addEnergy(add, false); - } + public int addEnergy(int max) { + int total = 0; + if (tile.canAcceptEnergy(EnumFacing.NORTH)) { + if (type.tier.ordinal() > tile.getTier().ordinal()) { + if (tile instanceof TileEntity) { + ((TileEntity) tile).getWorld().createExplosion(new EntityTNTPrimed(((TileEntity) tile).getWorld()), ((TileEntity) tile).getPos().getX(), ((TileEntity) tile).getPos().getY(), ((TileEntity) tile).getPos().getZ(), 2.5F, true); + } + return 0; + } + int add = max - total; + total += tile.addEnergy(add, false); + } + return total; + } - System.out.println("Provided " + total); - return total; - } + public int getTotalCollectible() { + if (tile.canProvideEnergy(EnumFacing.NORTH)) { + return (int) Math.min(tile.getMaxOutput(), tile.getEnergy()); + } + return 0; + } - public int getTotalCollectible() { - if (tile.canProvideEnergy(EnumFacing.NORTH)) { - return (int) Math.min(tile.getMaxOutput(), tile.getEnergy()); - } - return 0; - } + public int getTotalInsertible() { + int total = 0; + if (tile.canAcceptEnergy(EnumFacing.NORTH)) { + total += tile.addEnergy(type.transferRate, true); + } - public int getTotalInsertible() { - int total = 0; - if (tile.canAcceptEnergy(EnumFacing.NORTH)) { - total += tile.addEnergy(type.transferRate, true); - } + return total; + } - return total; - } - - @Override - public String toString() { - return tile + " @ " + side; - } - } + @Override + public String toString() { + return tile + " @ " + side; + } + } } diff --git a/src/main/java/techreborn/tiles/TileAesu.java b/src/main/java/techreborn/tiles/TileAesu.java index e798de58c..d8ef8ced4 100644 --- a/src/main/java/techreborn/tiles/TileAesu.java +++ b/src/main/java/techreborn/tiles/TileAesu.java @@ -5,6 +5,7 @@ import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import techreborn.config.ConfigTechReborn; @@ -151,4 +152,9 @@ public class TileAesu extends TilePowerAcceptor implements IWrenchable { public double getMaxInput() { return 4096 * 2; } + + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.EXTREME; + } } diff --git a/src/main/java/techreborn/tiles/TileAlloySmelter.java b/src/main/java/techreborn/tiles/TileAlloySmelter.java index c522cab09..642ffb52e 100644 --- a/src/main/java/techreborn/tiles/TileAlloySmelter.java +++ b/src/main/java/techreborn/tiles/TileAlloySmelter.java @@ -8,6 +8,7 @@ import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import techreborn.api.recipe.RecipeCrafter; @@ -191,6 +192,11 @@ public class TileAlloySmelter extends TilePowerAcceptor implements IWrenchable, return 32; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } + @Override public void openInventory(EntityPlayer player) { inventory.openInventory(player); diff --git a/src/main/java/techreborn/tiles/TileAssemblingMachine.java b/src/main/java/techreborn/tiles/TileAssemblingMachine.java index 2c0cc5d90..e60394aaa 100644 --- a/src/main/java/techreborn/tiles/TileAssemblingMachine.java +++ b/src/main/java/techreborn/tiles/TileAssemblingMachine.java @@ -8,6 +8,7 @@ import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import techreborn.api.recipe.RecipeCrafter; @@ -186,6 +187,11 @@ public class TileAssemblingMachine extends TilePowerAcceptor implements IWrencha return 128; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } + @Override public void openInventory(EntityPlayer player) { inventory.openInventory(player); diff --git a/src/main/java/techreborn/tiles/TileBlastFurnace.java b/src/main/java/techreborn/tiles/TileBlastFurnace.java index fe215597e..3e08e52b2 100644 --- a/src/main/java/techreborn/tiles/TileBlastFurnace.java +++ b/src/main/java/techreborn/tiles/TileBlastFurnace.java @@ -13,6 +13,7 @@ import net.minecraft.tileentity.TileEntity; import net.minecraft.util.BlockPos; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.misc.Location; import reborncore.common.multiblock.IMultiblockPart; import reborncore.common.powerSystem.TilePowerAcceptor; @@ -260,6 +261,11 @@ public class TileBlastFurnace extends TilePowerAcceptor implements IWrenchable, return 128; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.HIGH; + } + @Override public String getName() { return inventory.getName(); diff --git a/src/main/java/techreborn/tiles/TileCentrifuge.java b/src/main/java/techreborn/tiles/TileCentrifuge.java index d6a958824..87797da47 100644 --- a/src/main/java/techreborn/tiles/TileCentrifuge.java +++ b/src/main/java/techreborn/tiles/TileCentrifuge.java @@ -11,6 +11,7 @@ import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; import reborncore.api.IListInfoProvider; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import techreborn.api.recipe.RecipeCrafter; @@ -191,6 +192,11 @@ public class TileCentrifuge extends TilePowerAcceptor implements IWrenchable, II return 32; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } + @Override public void openInventory(EntityPlayer player) { inventory.openInventory(player); diff --git a/src/main/java/techreborn/tiles/TileChargeBench.java b/src/main/java/techreborn/tiles/TileChargeBench.java index f26b51967..48e0e8c9b 100644 --- a/src/main/java/techreborn/tiles/TileChargeBench.java +++ b/src/main/java/techreborn/tiles/TileChargeBench.java @@ -8,6 +8,7 @@ import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.api.power.IEnergyInterfaceItem; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; @@ -174,6 +175,11 @@ public class TileChargeBench extends TilePowerAcceptor implements IWrenchable, I return 512; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.MEDIUM; + } + @Override public void openInventory(EntityPlayer player) { inventory.openInventory(player); diff --git a/src/main/java/techreborn/tiles/TileChemicalReactor.java b/src/main/java/techreborn/tiles/TileChemicalReactor.java index 372910c5d..2e9ecaf4c 100644 --- a/src/main/java/techreborn/tiles/TileChemicalReactor.java +++ b/src/main/java/techreborn/tiles/TileChemicalReactor.java @@ -8,6 +8,7 @@ import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import techreborn.api.recipe.RecipeCrafter; @@ -185,6 +186,11 @@ public class TileChemicalReactor extends TilePowerAcceptor implements IWrenchabl return 128; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } + @Override public void openInventory(EntityPlayer player) { inventory.openInventory(player); diff --git a/src/main/java/techreborn/tiles/TileChunkLoader.java b/src/main/java/techreborn/tiles/TileChunkLoader.java index 3d5a21d4c..73a1c4dde 100644 --- a/src/main/java/techreborn/tiles/TileChunkLoader.java +++ b/src/main/java/techreborn/tiles/TileChunkLoader.java @@ -6,6 +6,7 @@ import net.minecraft.inventory.IInventory; import net.minecraft.item.ItemStack; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import techreborn.init.ModBlocks; @@ -121,6 +122,11 @@ public class TileChunkLoader extends TilePowerAcceptor implements IWrenchable, I return 32; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.MEDIUM; + } + @Override public void openInventory(EntityPlayer player) { inventory.openInventory(player); diff --git a/src/main/java/techreborn/tiles/TileImplosionCompressor.java b/src/main/java/techreborn/tiles/TileImplosionCompressor.java index bb7dc4e13..386495092 100644 --- a/src/main/java/techreborn/tiles/TileImplosionCompressor.java +++ b/src/main/java/techreborn/tiles/TileImplosionCompressor.java @@ -10,6 +10,7 @@ import net.minecraft.tileentity.TileEntity; import net.minecraft.util.BlockPos; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.misc.Location; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; @@ -254,4 +255,9 @@ public class TileImplosionCompressor extends TilePowerAcceptor implements IWrenc public double getMaxInput() { return 64; } + + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } } diff --git a/src/main/java/techreborn/tiles/TileIndustrialElectrolyzer.java b/src/main/java/techreborn/tiles/TileIndustrialElectrolyzer.java index c5b75bcae..b514cd41d 100644 --- a/src/main/java/techreborn/tiles/TileIndustrialElectrolyzer.java +++ b/src/main/java/techreborn/tiles/TileIndustrialElectrolyzer.java @@ -8,6 +8,7 @@ import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import techreborn.api.recipe.RecipeCrafter; @@ -232,4 +233,9 @@ public class TileIndustrialElectrolyzer extends TilePowerAcceptor implements IWr public double getMaxInput() { return 128; } + + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } } diff --git a/src/main/java/techreborn/tiles/TileIndustrialGrinder.java b/src/main/java/techreborn/tiles/TileIndustrialGrinder.java index ceb842fa2..cc584f515 100644 --- a/src/main/java/techreborn/tiles/TileIndustrialGrinder.java +++ b/src/main/java/techreborn/tiles/TileIndustrialGrinder.java @@ -15,6 +15,7 @@ import net.minecraftforge.fluids.FluidRegistry; import net.minecraftforge.fluids.FluidStack; import net.minecraftforge.fluids.FluidTankInfo; import net.minecraftforge.fluids.IFluidHandler; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.FluidUtils; import reborncore.common.util.Inventory; @@ -311,4 +312,9 @@ public class TileIndustrialGrinder extends TilePowerAcceptor implements IWrencha public double getMaxInput() { return 32; } + + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } } diff --git a/src/main/java/techreborn/tiles/TileIndustrialSawmill.java b/src/main/java/techreborn/tiles/TileIndustrialSawmill.java index 47a7cd706..2d306c15e 100644 --- a/src/main/java/techreborn/tiles/TileIndustrialSawmill.java +++ b/src/main/java/techreborn/tiles/TileIndustrialSawmill.java @@ -16,6 +16,7 @@ import net.minecraftforge.fluids.FluidStack; import net.minecraftforge.fluids.FluidTankInfo; import net.minecraftforge.fluids.IFluidHandler; import reborncore.api.IListInfoProvider; +import reborncore.api.power.EnumPowerTier; import reborncore.common.misc.Location; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.FluidUtils; @@ -309,4 +310,9 @@ public class TileIndustrialSawmill extends TilePowerAcceptor implements IWrencha public double getMaxInput() { return 64; } + + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } } diff --git a/src/main/java/techreborn/tiles/TileMatterFabricator.java b/src/main/java/techreborn/tiles/TileMatterFabricator.java index c123797c3..8bcdaef89 100644 --- a/src/main/java/techreborn/tiles/TileMatterFabricator.java +++ b/src/main/java/techreborn/tiles/TileMatterFabricator.java @@ -9,6 +9,7 @@ import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import reborncore.common.util.ItemUtils; @@ -284,4 +285,9 @@ public class TileMatterFabricator extends TilePowerAcceptor implements IWrenchab public double getMaxInput() { return 4096; } + + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.EXTREME; + } } diff --git a/src/main/java/techreborn/tiles/TilePlayerDectector.java b/src/main/java/techreborn/tiles/TilePlayerDectector.java index eaacede65..d49ad62fa 100644 --- a/src/main/java/techreborn/tiles/TilePlayerDectector.java +++ b/src/main/java/techreborn/tiles/TilePlayerDectector.java @@ -5,6 +5,7 @@ import java.util.Iterator; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; +import reborncore.api.power.EnumPowerTier; import reborncore.common.blocks.BlockMachineBase; import reborncore.common.powerSystem.TilePowerAcceptor; @@ -43,6 +44,11 @@ public class TilePlayerDectector extends TilePowerAcceptor { return 32; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } + @Override public void updateEntity() { super.updateEntity(); diff --git a/src/main/java/techreborn/tiles/TileRollingMachine.java b/src/main/java/techreborn/tiles/TileRollingMachine.java index 69e56d18d..a4461b3ca 100644 --- a/src/main/java/techreborn/tiles/TileRollingMachine.java +++ b/src/main/java/techreborn/tiles/TileRollingMachine.java @@ -9,6 +9,7 @@ import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import reborncore.common.util.ItemUtils; @@ -55,6 +56,11 @@ public class TileRollingMachine extends TilePowerAcceptor implements IWrenchable return 64; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } + private static class RollingTileContainer extends Container { @Override diff --git a/src/main/java/techreborn/tiles/TileVacuumFreezer.java b/src/main/java/techreborn/tiles/TileVacuumFreezer.java index 01227a621..355008c61 100644 --- a/src/main/java/techreborn/tiles/TileVacuumFreezer.java +++ b/src/main/java/techreborn/tiles/TileVacuumFreezer.java @@ -9,6 +9,7 @@ import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.BlockPos; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import techreborn.api.recipe.RecipeCrafter; @@ -68,6 +69,11 @@ public class TileVacuumFreezer extends TilePowerAcceptor implements IWrenchable, return 128; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.MEDIUM; + } + @Override public boolean wrenchCanSetFacing(EntityPlayer entityPlayer, EnumFacing side) { return false; diff --git a/src/main/java/techreborn/tiles/fusionReactor/TileEntityFusionController.java b/src/main/java/techreborn/tiles/fusionReactor/TileEntityFusionController.java index 109387b7d..fcac55063 100644 --- a/src/main/java/techreborn/tiles/fusionReactor/TileEntityFusionController.java +++ b/src/main/java/techreborn/tiles/fusionReactor/TileEntityFusionController.java @@ -7,6 +7,7 @@ import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.BlockPos; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import reborncore.common.util.ItemUtils; @@ -74,6 +75,11 @@ public class TileEntityFusionController extends TilePowerAcceptor implements IIn return 8192; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.EXTREME; + } + @Override public void readFromNBT(NBTTagCompound tagCompound) { super.readFromNBT(tagCompound); diff --git a/src/main/java/techreborn/tiles/generator/TileDieselGenerator.java b/src/main/java/techreborn/tiles/generator/TileDieselGenerator.java index 4c9e11dab..2395e93a2 100644 --- a/src/main/java/techreborn/tiles/generator/TileDieselGenerator.java +++ b/src/main/java/techreborn/tiles/generator/TileDieselGenerator.java @@ -16,6 +16,7 @@ import net.minecraftforge.fluids.FluidStack; import net.minecraftforge.fluids.FluidTankInfo; import net.minecraftforge.fluids.IFluidHandler; import reborncore.api.fuel.FluidPowerManager; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.FluidUtils; import reborncore.common.util.Inventory; @@ -222,6 +223,11 @@ public class TileDieselGenerator extends TilePowerAcceptor implements IWrenchabl return 0; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } + @Override public void openInventory(EntityPlayer player) { inventory.openInventory(player); diff --git a/src/main/java/techreborn/tiles/generator/TileDragonEggSiphoner.java b/src/main/java/techreborn/tiles/generator/TileDragonEggSiphoner.java index 6efcba5a7..5094ec88f 100644 --- a/src/main/java/techreborn/tiles/generator/TileDragonEggSiphoner.java +++ b/src/main/java/techreborn/tiles/generator/TileDragonEggSiphoner.java @@ -9,6 +9,7 @@ import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.BlockPos; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import techreborn.config.ConfigTechReborn; @@ -189,4 +190,9 @@ public class TileDragonEggSiphoner extends TilePowerAcceptor implements IWrencha public double getMaxInput() { return 0; } + + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.HIGH; + } } diff --git a/src/main/java/techreborn/tiles/generator/TileGasTurbine.java b/src/main/java/techreborn/tiles/generator/TileGasTurbine.java index 9148be421..ac0342c57 100644 --- a/src/main/java/techreborn/tiles/generator/TileGasTurbine.java +++ b/src/main/java/techreborn/tiles/generator/TileGasTurbine.java @@ -19,6 +19,7 @@ import net.minecraftforge.fluids.FluidRegistry; import net.minecraftforge.fluids.FluidStack; import net.minecraftforge.fluids.FluidTankInfo; import net.minecraftforge.fluids.IFluidHandler; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.FluidUtils; import reborncore.common.util.Inventory; @@ -285,4 +286,9 @@ public class TileGasTurbine extends TilePowerAcceptor implements IWrenchable, public double getMaxInput() { return 0; } + + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.MEDIUM; + } } diff --git a/src/main/java/techreborn/tiles/generator/TileGenerator.java b/src/main/java/techreborn/tiles/generator/TileGenerator.java index 5424d0a0e..7f4f66927 100644 --- a/src/main/java/techreborn/tiles/generator/TileGenerator.java +++ b/src/main/java/techreborn/tiles/generator/TileGenerator.java @@ -9,6 +9,7 @@ import net.minecraft.nbt.NBTTagCompound; import net.minecraft.tileentity.TileEntityFurnace; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.blocks.BlockMachineBase; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; @@ -164,6 +165,11 @@ public class TileGenerator extends TilePowerAcceptor implements IWrenchable, IIn return 0; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } + @Override public void openInventory(EntityPlayer player) { inventory.openInventory(player); diff --git a/src/main/java/techreborn/tiles/generator/TileHeatGenerator.java b/src/main/java/techreborn/tiles/generator/TileHeatGenerator.java index 60b3adfd5..8a325b514 100644 --- a/src/main/java/techreborn/tiles/generator/TileHeatGenerator.java +++ b/src/main/java/techreborn/tiles/generator/TileHeatGenerator.java @@ -6,6 +6,7 @@ import net.minecraft.init.Blocks; import net.minecraft.item.ItemStack; import net.minecraft.util.BlockPos; import net.minecraft.util.EnumFacing; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import techreborn.config.ConfigTechReborn; import techreborn.init.ModBlocks; @@ -96,6 +97,11 @@ public class TileHeatGenerator extends TilePowerAcceptor implements IWrenchable return 0; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } + // @Override // public void addWailaInfo(List info) // { diff --git a/src/main/java/techreborn/tiles/generator/TileSemifluidGenerator.java b/src/main/java/techreborn/tiles/generator/TileSemifluidGenerator.java index fdf5eedf6..a093dac6b 100644 --- a/src/main/java/techreborn/tiles/generator/TileSemifluidGenerator.java +++ b/src/main/java/techreborn/tiles/generator/TileSemifluidGenerator.java @@ -19,6 +19,7 @@ import net.minecraftforge.fluids.FluidRegistry; import net.minecraftforge.fluids.FluidStack; import net.minecraftforge.fluids.FluidTankInfo; import net.minecraftforge.fluids.IFluidHandler; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.FluidUtils; import reborncore.common.util.Inventory; @@ -290,4 +291,9 @@ public class TileSemifluidGenerator extends TilePowerAcceptor implements IWrench public double getMaxInput() { return 0; } + + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } } diff --git a/src/main/java/techreborn/tiles/generator/TileSolarPanel.java b/src/main/java/techreborn/tiles/generator/TileSolarPanel.java index cfde38603..28e517ee7 100644 --- a/src/main/java/techreborn/tiles/generator/TileSolarPanel.java +++ b/src/main/java/techreborn/tiles/generator/TileSolarPanel.java @@ -3,6 +3,7 @@ package techreborn.tiles.generator; import java.util.List; import net.minecraft.util.EnumFacing; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import techreborn.blocks.generator.BlockSolarPanel; @@ -76,4 +77,9 @@ public class TileSolarPanel extends TilePowerAcceptor { public double getMaxInput() { return 0; } + + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } } diff --git a/src/main/java/techreborn/tiles/generator/TileThermalGenerator.java b/src/main/java/techreborn/tiles/generator/TileThermalGenerator.java index 2225836df..72c2d74bd 100644 --- a/src/main/java/techreborn/tiles/generator/TileThermalGenerator.java +++ b/src/main/java/techreborn/tiles/generator/TileThermalGenerator.java @@ -18,6 +18,7 @@ import net.minecraftforge.fluids.FluidRegistry; import net.minecraftforge.fluids.FluidStack; import net.minecraftforge.fluids.FluidTankInfo; import net.minecraftforge.fluids.IFluidHandler; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.FluidUtils; import reborncore.common.util.Inventory; @@ -269,4 +270,9 @@ public class TileThermalGenerator extends TilePowerAcceptor implements IWrenchab public double getMaxInput() { return 0; } + + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } } diff --git a/src/main/java/techreborn/tiles/generator/TileWaterMill.java b/src/main/java/techreborn/tiles/generator/TileWaterMill.java index 2222d3dcc..76f6400be 100644 --- a/src/main/java/techreborn/tiles/generator/TileWaterMill.java +++ b/src/main/java/techreborn/tiles/generator/TileWaterMill.java @@ -2,6 +2,7 @@ package techreborn.tiles.generator; import net.minecraft.init.Blocks; import net.minecraft.util.EnumFacing; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; /** @@ -60,4 +61,9 @@ public class TileWaterMill extends TilePowerAcceptor { public double getMaxInput() { return 0; } + + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } } diff --git a/src/main/java/techreborn/tiles/generator/TileWindMill.java b/src/main/java/techreborn/tiles/generator/TileWindMill.java index 9dade18be..7796b0503 100644 --- a/src/main/java/techreborn/tiles/generator/TileWindMill.java +++ b/src/main/java/techreborn/tiles/generator/TileWindMill.java @@ -1,6 +1,7 @@ package techreborn.tiles.generator; import net.minecraft.util.EnumFacing; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; /** @@ -50,4 +51,9 @@ public class TileWindMill extends TilePowerAcceptor { public double getMaxInput() { return 0; } + + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } } diff --git a/src/main/java/techreborn/tiles/idsu/TileIDSU.java b/src/main/java/techreborn/tiles/idsu/TileIDSU.java index d962583a3..0080210df 100644 --- a/src/main/java/techreborn/tiles/idsu/TileIDSU.java +++ b/src/main/java/techreborn/tiles/idsu/TileIDSU.java @@ -6,6 +6,7 @@ import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import techreborn.config.ConfigTechReborn; import techreborn.init.ModBlocks; @@ -67,6 +68,11 @@ public class TileIDSU extends TilePowerAcceptor { return maxStorage; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.EXTREME; + } + public int tier; public int output; public double maxStorage; diff --git a/src/main/java/techreborn/tiles/lesu/TileLesu.java b/src/main/java/techreborn/tiles/lesu/TileLesu.java index b4e6f568d..47546af83 100644 --- a/src/main/java/techreborn/tiles/lesu/TileLesu.java +++ b/src/main/java/techreborn/tiles/lesu/TileLesu.java @@ -5,6 +5,7 @@ import java.util.ArrayList; import net.minecraft.util.BlockPos; import net.minecraft.util.EnumFacing; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import techreborn.config.ConfigTechReborn; @@ -101,4 +102,9 @@ public class TileLesu extends TilePowerAcceptor {//TODO wrench public double getMaxInput() { return 8192; } + + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.EXTREME; + } } diff --git a/src/main/java/techreborn/tiles/teir1/TileCompressor.java b/src/main/java/techreborn/tiles/teir1/TileCompressor.java index dea952dce..15a78626b 100644 --- a/src/main/java/techreborn/tiles/teir1/TileCompressor.java +++ b/src/main/java/techreborn/tiles/teir1/TileCompressor.java @@ -8,6 +8,7 @@ import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import techreborn.api.recipe.RecipeCrafter; @@ -175,6 +176,11 @@ public class TileCompressor extends TilePowerAcceptor implements IWrenchable, II return 32; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } + @Override public void openInventory(EntityPlayer player) { inventory.openInventory(player); diff --git a/src/main/java/techreborn/tiles/teir1/TileElectricFurnace.java b/src/main/java/techreborn/tiles/teir1/TileElectricFurnace.java index 8490b306c..249e60a9e 100644 --- a/src/main/java/techreborn/tiles/teir1/TileElectricFurnace.java +++ b/src/main/java/techreborn/tiles/teir1/TileElectricFurnace.java @@ -10,6 +10,7 @@ import net.minecraft.item.crafting.FurnaceRecipes; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.blocks.BlockMachineBase; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; @@ -275,6 +276,11 @@ public class TileElectricFurnace extends TilePowerAcceptor implements IWrenchabl return 32; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } + @Override public void openInventory(EntityPlayer player) { inventory.openInventory(player); diff --git a/src/main/java/techreborn/tiles/teir1/TileExtractor.java b/src/main/java/techreborn/tiles/teir1/TileExtractor.java index c37fa537c..2568323e0 100644 --- a/src/main/java/techreborn/tiles/teir1/TileExtractor.java +++ b/src/main/java/techreborn/tiles/teir1/TileExtractor.java @@ -8,6 +8,7 @@ import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import techreborn.api.recipe.RecipeCrafter; @@ -175,6 +176,11 @@ public class TileExtractor extends TilePowerAcceptor implements IWrenchable, IIn return 32; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } + @Override public void openInventory(EntityPlayer player) { inventory.openInventory(player); diff --git a/src/main/java/techreborn/tiles/teir1/TileGrinder.java b/src/main/java/techreborn/tiles/teir1/TileGrinder.java index b93fdb6ce..abf2500ad 100644 --- a/src/main/java/techreborn/tiles/teir1/TileGrinder.java +++ b/src/main/java/techreborn/tiles/teir1/TileGrinder.java @@ -8,6 +8,7 @@ import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; import techreborn.api.recipe.RecipeCrafter; @@ -174,6 +175,11 @@ public class TileGrinder extends TilePowerAcceptor implements IWrenchable, IInve return 32; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.LOW; + } + @Override public void openInventory(EntityPlayer player) { inventory.openInventory(player); diff --git a/src/main/java/techreborn/tiles/teir1/TileRecycler.java b/src/main/java/techreborn/tiles/teir1/TileRecycler.java index 74fc80454..1c343dab7 100644 --- a/src/main/java/techreborn/tiles/teir1/TileRecycler.java +++ b/src/main/java/techreborn/tiles/teir1/TileRecycler.java @@ -12,6 +12,7 @@ import net.minecraft.item.crafting.FurnaceRecipes; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.util.EnumFacing; import net.minecraft.util.IChatComponent; +import reborncore.api.power.EnumPowerTier; import reborncore.common.blocks.BlockMachineBase; import reborncore.common.powerSystem.TilePowerAcceptor; import reborncore.common.util.Inventory; @@ -269,6 +270,11 @@ public class TileRecycler extends TilePowerAcceptor implements IWrenchable, IInv return 32; } + @Override + public EnumPowerTier getTier() { + return EnumPowerTier.MEDIUM; + } + @Override public void openInventory(EntityPlayer player) { inventory.openInventory(player);