From c32369a8f549d8f67dc7a27a88250e13a4298791 Mon Sep 17 00:00:00 2001 From: Dream-Master Date: Tue, 3 Nov 2015 12:06:55 +0100 Subject: Adding Colant Cells to Gt Mixer Add Caesium Burn value Add Block Harvet Level (copy from Gt 5.09. code) --- src/main/java/gregtech/common/blocks/GT_TileEntity_Ores.java | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'src/main/java/gregtech/common/blocks') diff --git a/src/main/java/gregtech/common/blocks/GT_TileEntity_Ores.java b/src/main/java/gregtech/common/blocks/GT_TileEntity_Ores.java index c8706776b2..a17590e575 100644 --- a/src/main/java/gregtech/common/blocks/GT_TileEntity_Ores.java +++ b/src/main/java/gregtech/common/blocks/GT_TileEntity_Ores.java @@ -1,5 +1,6 @@ package gregtech.common.blocks; +import gregtech.GT_Mod; import gregtech.api.GregTech_API; import gregtech.api.enums.GT_Values; import gregtech.api.enums.Materials; @@ -32,7 +33,12 @@ public class GT_TileEntity_Ores public static byte getHarvestData(short aMetaData) { Materials aMaterial = GregTech_API.sGeneratedMaterials[(aMetaData % 1000)]; - return aMaterial == null ? 0 : (byte) Math.max((aMetaData % 16000 / 1000 == 3) || (aMetaData % 16000 / 1000 == 4) ? 3 : 0, Math.min(7, aMaterial.mToolQuality - (aMetaData < 16000 ? 0 : 1))); + byte tByte = aMaterial == null ? 0 : (byte) Math.max((aMetaData % 16000 / 1000 == 3) || (aMetaData % 16000 / 1000 == 4) ? 3 : 0, Math.min(7, aMaterial.mToolQuality - (aMetaData < 16000 ? 0 : 1))); + if(GT_Mod.gregtechproxy.mChangeHarvestLevels ){ + tByte = aMaterial == null ? 0 : (byte) Math.max((aMetaData % 16000 / 1000 == 3) || (aMetaData % 16000 / 1000 == 4) ? GT_Mod.gregtechproxy.mGraniteHavestLevel : 0, Math.min(GT_Mod.gregtechproxy.mMaxHarvestLevel, GT_Mod.gregtechproxy.mHarvestLevel[aMaterial.mMetaItemSubID] - (aMetaData < 16000 ? 0 : 1))); + } + return tByte; + } public static boolean setOreBlock(World aWorld, int aX, int aY, int aZ, int aMetaData) { -- cgit From a2d27ad80e3af7eac1ed65dca82ea3bb36b00bc9 Mon Sep 17 00:00:00 2001 From: Technus Date: Sat, 16 Apr 2016 20:07:04 +0200 Subject: Update GT_Item_Casings1.java --- src/main/java/gregtech/common/blocks/GT_Item_Casings1.java | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/main/java/gregtech/common/blocks') diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Casings1.java b/src/main/java/gregtech/common/blocks/GT_Item_Casings1.java index a02124706e..c635698dfa 100644 --- a/src/main/java/gregtech/common/blocks/GT_Item_Casings1.java +++ b/src/main/java/gregtech/common/blocks/GT_Item_Casings1.java @@ -23,6 +23,9 @@ public class GT_Item_Casings1 break; case 14: aList.add(this.mCoil03Tooltip); + break; + case 15: + aList.add(this.mCoil04Tooltip); } } } -- cgit From 76c555d62c36ff60f47c50eca93b682476838a87 Mon Sep 17 00:00:00 2001 From: Technus Date: Sat, 16 Apr 2016 20:10:23 +0200 Subject: Update GT_Item_Casings_Abstract.java --- src/main/java/gregtech/common/blocks/GT_Item_Casings_Abstract.java | 1 + 1 file changed, 1 insertion(+) (limited to 'src/main/java/gregtech/common/blocks') diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Casings_Abstract.java b/src/main/java/gregtech/common/blocks/GT_Item_Casings_Abstract.java index 0ff5b904b7..a2f26cd617 100644 --- a/src/main/java/gregtech/common/blocks/GT_Item_Casings_Abstract.java +++ b/src/main/java/gregtech/common/blocks/GT_Item_Casings_Abstract.java @@ -16,6 +16,7 @@ public abstract class GT_Item_Casings_Abstract protected final String mCoil01Tooltip = GT_LanguageManager.addStringLocalization("gt.coil01tooltip", "Base Heating Capacity = 1800 Kelvin"); protected final String mCoil02Tooltip = GT_LanguageManager.addStringLocalization("gt.coil02tooltip", "Base Heating Capacity = 2700 Kelvin"); protected final String mCoil03Tooltip = GT_LanguageManager.addStringLocalization("gt.coil03tooltip", "Base Heating Capacity = 3600 Kelvin"); + protected final String mCoil04Tooltip = GT_LanguageManager.addStringLocalization("gt.coil04tooltip", "Base Heating Capacity = 9000 Kelvin"); protected final String mBlastProofTooltip = GT_LanguageManager.addStringLocalization("gt.blastprooftooltip", "This Block is Blast Proof"); public GT_Item_Casings_Abstract(Block par1) { super(par1); -- cgit From 78c691d7545324107411339fa094bedd81d4529f Mon Sep 17 00:00:00 2001 From: Dream-Master Date: Wed, 25 May 2016 21:43:52 +0200 Subject: Adding the New Turbines from Gt 5.09 and some Assembler recipe --- .../gregtech/common/blocks/GT_Block_Casings4.java | 140 +++++++++++++++------ 1 file changed, 102 insertions(+), 38 deletions(-) (limited to 'src/main/java/gregtech/common/blocks') diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Casings4.java b/src/main/java/gregtech/common/blocks/GT_Block_Casings4.java index 3705ce2204..1afe7f5e15 100644 --- a/src/main/java/gregtech/common/blocks/GT_Block_Casings4.java +++ b/src/main/java/gregtech/common/blocks/GT_Block_Casings4.java @@ -33,6 +33,9 @@ public class GT_Block_Casings4 GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".7.name", "Fusion Coil"); GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".8.name", "Fusion Casing MK II"); GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".9.name", "Turbine Casing"); + GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".10.name", "Stainless Steel Turbine Casing"); + GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".11.name", "Titanium Turbine Casing"); + GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".12.name", "Tungstensteel Turbine Casing"); ItemList.Casing_RobustTungstenSteel.set(new ItemStack(this, 1, 0)); ItemList.Casing_CleanStainlessSteel.set(new ItemStack(this, 1, 1)); @@ -42,6 +45,9 @@ public class GT_Block_Casings4 ItemList.Casing_Fusion_Coil.set(new ItemStack(this, 1, 7)); ItemList.Casing_Fusion2.set(new ItemStack(this, 1, 8)); ItemList.Casing_Turbine.set(new ItemStack(this, 1, 9)); + ItemList.Casing_Turbine1.set(new ItemStack(this, 1, 10)); + ItemList.Casing_Turbine2.set(new ItemStack(this, 1, 11)); + ItemList.Casing_Turbine3.set(new ItemStack(this, 1, 12)); } public IIcon getIcon(int aSide, int aMeta) { @@ -67,9 +73,9 @@ public class GT_Block_Casings4 case 9: return Textures.BlockIcons.MACHINE_CASING_TURBINE.getIcon(); case 10: - return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); + return Textures.BlockIcons.MACHINE_CASING_CLEAN_STAINLESSSTEEL.getIcon(); case 11: - return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); + return Textures.BlockIcons.MACHINE_CASING_STABLE_TITANIUM.getIcon(); case 12: return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); case 13: @@ -82,118 +88,176 @@ public class GT_Block_Casings4 return Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon(); } + public IIcon getTurbineCasing(int meta, int iconIndex, boolean active) { + switch (meta) { + case 9: + return active ? Textures.BlockIcons.TURBINE_ACTIVE[iconIndex].getIcon() : Textures.BlockIcons.TURBINE[iconIndex].getIcon(); + case 10: + return active ? Textures.BlockIcons.TURBINE_ACTIVE1[iconIndex].getIcon() : Textures.BlockIcons.TURBINE1[iconIndex].getIcon(); + case 11: + return active ? Textures.BlockIcons.TURBINE_ACTIVE2[iconIndex].getIcon() : Textures.BlockIcons.TURBINE2[iconIndex].getIcon(); + case 12: + return active ? Textures.BlockIcons.TURBINE_ACTIVE3[iconIndex].getIcon() : Textures.BlockIcons.TURBINE3[iconIndex].getIcon(); + default: + return active ? Textures.BlockIcons.TURBINE_ACTIVE[iconIndex].getIcon() : Textures.BlockIcons.TURBINE[iconIndex].getIcon(); + } + } + @SideOnly(Side.CLIENT) public IIcon getIcon(IBlockAccess aWorld, int xCoord, int yCoord, int zCoord, int aSide) { int tMeta = aWorld.getBlockMetadata(xCoord, yCoord, zCoord); - if (((tMeta != 6) && (tMeta != 8) && (tMeta != 9)) || (!mConnectedMachineTextures)) { + if ((tMeta != 6) && (tMeta != 8) && (tMeta != 9) && (tMeta != 10) && (tMeta != 11) && (tMeta != 12) || (!mConnectedMachineTextures)) { return getIcon(aSide, tMeta); } int tStartIndex = tMeta == 6 ? 1 : 13; - if (tMeta == 9) { + if ((tMeta == 9) || (tMeta == 10) || (tMeta == 11) || (tMeta == 12)) { if ((aSide == 2) || (aSide == 3)) { TileEntity tTileEntity; IMetaTileEntity tMetaTileEntity; if ((null != (tTileEntity = aWorld.getTileEntity(xCoord + (aSide == 3 ? 1 : -1), yCoord - 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[0].getIcon(); + return getTurbineCasing(tMeta, 0, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[0].getIcon(); } - return Textures.BlockIcons.TURBINE[0].getIcon(); + return getTurbineCasing(tMeta, 0, false); + //return Textures.BlockIcons.TURBINE[0].getIcon(); } if ((null != (tTileEntity = aWorld.getTileEntity(xCoord + (aSide == 3 ? 1 : -1), yCoord, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[3].getIcon(); + return getTurbineCasing(tMeta, 3, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[3].getIcon(); } - return Textures.BlockIcons.TURBINE[3].getIcon(); + return getTurbineCasing(tMeta, 3, false); + //return Textures.BlockIcons.TURBINE[3].getIcon(); } if ((null != (tTileEntity = aWorld.getTileEntity(xCoord + (aSide == 3 ? 1 : -1), yCoord + 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[6].getIcon(); + return getTurbineCasing(tMeta, 6, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[6].getIcon(); } - return Textures.BlockIcons.TURBINE[6].getIcon(); + return getTurbineCasing(tMeta, 6, false); + //return Textures.BlockIcons.TURBINE[6].getIcon(); } if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord - 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[1].getIcon(); + return getTurbineCasing(tMeta, 1, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[1].getIcon(); } - return Textures.BlockIcons.TURBINE[1].getIcon(); + return getTurbineCasing(tMeta, 1, false); + //return Textures.BlockIcons.TURBINE[1].getIcon(); } if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord + 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[7].getIcon(); + return getTurbineCasing(tMeta, 7, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[7].getIcon(); } - return Textures.BlockIcons.TURBINE[7].getIcon(); + return getTurbineCasing(tMeta, 7, false); + //return Textures.BlockIcons.TURBINE[7].getIcon(); } if ((null != (tTileEntity = aWorld.getTileEntity(xCoord + (aSide == 2 ? 1 : -1), yCoord + 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[8].getIcon(); + return getTurbineCasing(tMeta, 8, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[8].getIcon(); } - return Textures.BlockIcons.TURBINE[8].getIcon(); + return getTurbineCasing(tMeta, 8, false); + //return Textures.BlockIcons.TURBINE[8].getIcon(); } if ((null != (tTileEntity = aWorld.getTileEntity(xCoord + (aSide == 2 ? 1 : -1), yCoord, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[5].getIcon(); + return getTurbineCasing(tMeta, 5, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[5].getIcon(); } - return Textures.BlockIcons.TURBINE[5].getIcon(); + return getTurbineCasing(tMeta, 5, false); + //return Textures.BlockIcons.TURBINE[5].getIcon(); } if ((null != (tTileEntity = aWorld.getTileEntity(xCoord + (aSide == 2 ? 1 : -1), yCoord - 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[2].getIcon(); + return getTurbineCasing(tMeta, 2, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[2].getIcon(); } - return Textures.BlockIcons.TURBINE[2].getIcon(); + return getTurbineCasing(tMeta, 2, false); + //return Textures.BlockIcons.TURBINE[2].getIcon(); } } else if ((aSide == 4) || (aSide == 5)) { TileEntity tTileEntity; Object tMetaTileEntity; if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord - 1, zCoord + (aSide == 4 ? 1 : -1)))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[0].getIcon(); + return getTurbineCasing(tMeta, 0, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[0].getIcon(); } - return Textures.BlockIcons.TURBINE[0].getIcon(); + return getTurbineCasing(tMeta, 0, false); + //return Textures.BlockIcons.TURBINE[0].getIcon(); } if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord, zCoord + (aSide == 4 ? 1 : -1)))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[3].getIcon(); + return getTurbineCasing(tMeta, 3, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[3].getIcon(); } - return Textures.BlockIcons.TURBINE[3].getIcon(); + return getTurbineCasing(tMeta, 3, false); + //return Textures.BlockIcons.TURBINE[3].getIcon(); } if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord + 1, zCoord + (aSide == 4 ? 1 : -1)))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[6].getIcon(); + return getTurbineCasing(tMeta, 6, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[6].getIcon(); } - return Textures.BlockIcons.TURBINE[6].getIcon(); + return getTurbineCasing(tMeta, 6, false); + //return Textures.BlockIcons.TURBINE[6].getIcon(); } if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord - 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[1].getIcon(); + return getTurbineCasing(tMeta, 1, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[1].getIcon(); } - return Textures.BlockIcons.TURBINE[1].getIcon(); + return getTurbineCasing(tMeta, 1, false); + //return Textures.BlockIcons.TURBINE[1].getIcon(); } if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord + 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[7].getIcon(); + return getTurbineCasing(tMeta, 7, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[7].getIcon(); } - return Textures.BlockIcons.TURBINE[7].getIcon(); + return getTurbineCasing(tMeta, 7, false); + //return Textures.BlockIcons.TURBINE[7].getIcon(); } if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord + 1, zCoord + (aSide == 5 ? 1 : -1)))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[8].getIcon(); + return getTurbineCasing(tMeta, 8, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[8].getIcon(); } - return Textures.BlockIcons.TURBINE[8].getIcon(); + return getTurbineCasing(tMeta, 8, false); + //return Textures.BlockIcons.TURBINE[8].getIcon(); } if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord, zCoord + (aSide == 5 ? 1 : -1)))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[5].getIcon(); + return getTurbineCasing(tMeta, 5, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[5].getIcon(); } - return Textures.BlockIcons.TURBINE[5].getIcon(); + return getTurbineCasing(tMeta, 5, false); + //return Textures.BlockIcons.TURBINE[5].getIcon(); } if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord - 1, zCoord + (aSide == 5 ? 1 : -1)))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { if (((IGregTechTileEntity) tTileEntity).isActive()) { - return Textures.BlockIcons.TURBINE_ACTIVE[2].getIcon(); + return getTurbineCasing(tMeta, 2, true); + //return Textures.BlockIcons.TURBINE_ACTIVE[2].getIcon(); } - return Textures.BlockIcons.TURBINE[2].getIcon(); + return getTurbineCasing(tMeta, 2, false); + //return Textures.BlockIcons.TURBINE[2].getIcon(); } } - return Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon(); + switch (tMeta) { + case 9: + return Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon(); + case 10: + return Textures.BlockIcons.MACHINE_CASING_CLEAN_STAINLESSSTEEL.getIcon(); + case 11: + return Textures.BlockIcons.MACHINE_CASING_STABLE_TITANIUM.getIcon(); + case 12: + return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); + default: + return Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon(); + } } boolean[] tConnectedSides = {(aWorld.getBlock(xCoord, yCoord - 1, zCoord) == this) && (aWorld.getBlockMetadata(xCoord, yCoord - 1, zCoord) == tMeta), (aWorld.getBlock(xCoord, yCoord + 1, zCoord) == this) && (aWorld.getBlockMetadata(xCoord, yCoord + 1, zCoord) == tMeta), (aWorld.getBlock(xCoord + 1, yCoord, zCoord) == this) && (aWorld.getBlockMetadata(xCoord + 1, yCoord, zCoord) == tMeta), (aWorld.getBlock(xCoord, yCoord, zCoord + 1) == this) && (aWorld.getBlockMetadata(xCoord, yCoord, zCoord + 1) == tMeta), (aWorld.getBlock(xCoord - 1, yCoord, zCoord) == this) && (aWorld.getBlockMetadata(xCoord - 1, yCoord, zCoord) == tMeta), (aWorld.getBlock(xCoord, yCoord, zCoord - 1) == this) && (aWorld.getBlockMetadata(xCoord, yCoord, zCoord - 1) == tMeta)}; switch (aSide) { @@ -441,4 +505,4 @@ public class GT_Block_Casings4 } return Textures.BlockIcons.CONNECTED_HULLS[(tStartIndex + 7)].getIcon(); } -} \ No newline at end of file +} -- cgit From b09b54435f9427332854558c42bd2c902825cbfe Mon Sep 17 00:00:00 2001 From: Dream-Master Date: Tue, 21 Jun 2016 18:42:02 +0200 Subject: remove all --- .../gregtech/common/blocks/GT_Block_Casings1.java | 82 ---- .../gregtech/common/blocks/GT_Block_Casings2.java | 95 ---- .../gregtech/common/blocks/GT_Block_Casings3.java | 88 ---- .../gregtech/common/blocks/GT_Block_Casings4.java | 508 --------------------- .../common/blocks/GT_Block_Casings_Abstract.java | 121 ----- .../gregtech/common/blocks/GT_Block_Concretes.java | 93 ---- .../gregtech/common/blocks/GT_Block_Granites.java | 72 --- .../gregtech/common/blocks/GT_Block_Machines.java | 499 -------------------- .../java/gregtech/common/blocks/GT_Block_Ores.java | 249 ---------- .../common/blocks/GT_Block_Stones_Abstract.java | 149 ------ .../gregtech/common/blocks/GT_Item_Casings1.java | 31 -- .../gregtech/common/blocks/GT_Item_Casings2.java | 22 - .../gregtech/common/blocks/GT_Item_Casings3.java | 10 - .../gregtech/common/blocks/GT_Item_Casings4.java | 10 - .../common/blocks/GT_Item_Casings_Abstract.java | 41 -- .../gregtech/common/blocks/GT_Item_Concretes.java | 22 - .../gregtech/common/blocks/GT_Item_Granites.java | 10 - .../gregtech/common/blocks/GT_Item_Machines.java | 146 ------ .../java/gregtech/common/blocks/GT_Item_Ores.java | 45 -- .../common/blocks/GT_Item_Stones_Abstract.java | 37 -- .../common/blocks/GT_Material_Casings.java | 18 - .../common/blocks/GT_Material_Machines.java | 18 - .../gregtech/common/blocks/GT_Packet_Ores.java | 60 --- .../gregtech/common/blocks/GT_TileEntity_Ores.java | 228 --------- 24 files changed, 2654 deletions(-) delete mode 100644 src/main/java/gregtech/common/blocks/GT_Block_Casings1.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Block_Casings2.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Block_Casings3.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Block_Casings4.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Block_Casings_Abstract.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Block_Concretes.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Block_Granites.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Block_Machines.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Block_Ores.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Block_Stones_Abstract.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Item_Casings1.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Item_Casings2.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Item_Casings3.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Item_Casings4.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Item_Casings_Abstract.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Item_Concretes.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Item_Granites.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Item_Machines.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Item_Ores.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Item_Stones_Abstract.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Material_Casings.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Material_Machines.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_Packet_Ores.java delete mode 100644 src/main/java/gregtech/common/blocks/GT_TileEntity_Ores.java (limited to 'src/main/java/gregtech/common/blocks') diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Casings1.java b/src/main/java/gregtech/common/blocks/GT_Block_Casings1.java deleted file mode 100644 index bcacbf8939..0000000000 --- a/src/main/java/gregtech/common/blocks/GT_Block_Casings1.java +++ /dev/null @@ -1,82 +0,0 @@ -package gregtech.common.blocks; - -import gregtech.api.enums.ItemList; -import gregtech.api.enums.Textures; -import gregtech.api.objects.GT_CopiedBlockTexture; -import gregtech.api.util.GT_LanguageManager; -import net.minecraft.item.ItemStack; -import net.minecraft.util.IIcon; -import net.minecraft.world.IBlockAccess; - -public class GT_Block_Casings1 - extends GT_Block_Casings_Abstract { - public GT_Block_Casings1() { - super(GT_Item_Casings1.class, "gt.blockcasings", GT_Material_Casings.INSTANCE); - for (byte i = 0; i < 16; i = (byte) (i + 1)) { - Textures.BlockIcons.CASING_BLOCKS[i] = new GT_CopiedBlockTexture(this, 6, i); - } - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".0.name", "ULV Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".1.name", "LV Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".2.name", "MV Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".3.name", "HV Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".4.name", "EV Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".5.name", "IV Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".6.name", "LuV Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".7.name", "ZPM Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".8.name", "UV Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".9.name", "MAX Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".10.name", "Bronze Plated Bricks"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".11.name", "Heat Proof Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".12.name", "Cupronickel Coil Block"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".13.name", "Kanthal Coil Block"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".14.name", "Nichrome Coil Block"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".15.name", "Superconducting Coil Block"); - ItemList.Casing_ULV.set(new ItemStack(this, 1, 0)); - ItemList.Casing_LV.set(new ItemStack(this, 1, 1)); - ItemList.Casing_MV.set(new ItemStack(this, 1, 2)); - ItemList.Casing_HV.set(new ItemStack(this, 1, 3)); - ItemList.Casing_EV.set(new ItemStack(this, 1, 4)); - ItemList.Casing_IV.set(new ItemStack(this, 1, 5)); - ItemList.Casing_LuV.set(new ItemStack(this, 1, 6)); - ItemList.Casing_ZPM.set(new ItemStack(this, 1, 7)); - ItemList.Casing_UV.set(new ItemStack(this, 1, 8)); - ItemList.Casing_MAX.set(new ItemStack(this, 1, 9)); - ItemList.Casing_BronzePlatedBricks.set(new ItemStack(this, 1, 10)); - ItemList.Casing_HeatProof.set(new ItemStack(this, 1, 11)); - ItemList.Casing_Coil_Cupronickel.set(new ItemStack(this, 1, 12)); - ItemList.Casing_Coil_Kanthal.set(new ItemStack(this, 1, 13)); - ItemList.Casing_Coil_Nichrome.set(new ItemStack(this, 1, 14)); - ItemList.Casing_Coil_Superconductor.set(new ItemStack(this, 1, 15)); - } - - public IIcon getIcon(int aSide, int aMeta) { - if ((aMeta >= 0) && (aMeta < 16)) { - switch (aMeta) { - case 10: - return Textures.BlockIcons.MACHINE_BRONZEPLATEDBRICKS.getIcon(); - case 11: - return Textures.BlockIcons.MACHINE_HEATPROOFCASING.getIcon(); - case 12: - return Textures.BlockIcons.MACHINE_COIL_CUPRONICKEL.getIcon(); - case 13: - return Textures.BlockIcons.MACHINE_COIL_KANTHAL.getIcon(); - case 14: - return Textures.BlockIcons.MACHINE_COIL_NICHROME.getIcon(); - case 15: - return Textures.BlockIcons.MACHINE_COIL_SUPERCONDUCTOR.getIcon(); - } - if (aSide == 0) { - return Textures.BlockIcons.MACHINECASINGS_BOTTOM[aMeta].getIcon(); - } - if (aSide == 1) { - return Textures.BlockIcons.MACHINECASINGS_TOP[aMeta].getIcon(); - } - return Textures.BlockIcons.MACHINECASINGS_SIDE[aMeta].getIcon(); - } - return Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon(); - } - - public int colorMultiplier(IBlockAccess aWorld, int aX, int aY, int aZ) { - return aWorld.getBlockMetadata(aX, aY, aZ) > 9 ? super.colorMultiplier(aWorld, aX, aY, aZ) : gregtech.api.enums.Dyes.MACHINE_METAL.mRGBa[0] << 16 | gregtech.api.enums.Dyes.MACHINE_METAL.mRGBa[1] << 8 | gregtech.api.enums.Dyes.MACHINE_METAL.mRGBa[2]; - } -} diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Casings2.java b/src/main/java/gregtech/common/blocks/GT_Block_Casings2.java deleted file mode 100644 index c9eec65b97..0000000000 --- a/src/main/java/gregtech/common/blocks/GT_Block_Casings2.java +++ /dev/null @@ -1,95 +0,0 @@ -package gregtech.common.blocks; - -import gregtech.api.enums.ItemList; -import gregtech.api.enums.Textures; -import gregtech.api.objects.GT_CopiedBlockTexture; -import gregtech.api.util.GT_LanguageManager; -import net.minecraft.entity.Entity; -import net.minecraft.init.Blocks; -import net.minecraft.item.ItemStack; -import net.minecraft.util.IIcon; -import net.minecraft.world.World; - -public class GT_Block_Casings2 - extends GT_Block_Casings_Abstract { - public GT_Block_Casings2() { - super(GT_Item_Casings2.class, "gt.blockcasings2", GT_Material_Casings.INSTANCE); - for (byte i = 0; i < 16; i = (byte) (i + 1)) { - Textures.BlockIcons.CASING_BLOCKS[(i + 16)] = new GT_CopiedBlockTexture(this, 6, i); - } - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".0.name", "Solid Steel Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".1.name", "Frost Proof Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".2.name", "Bronze Gear Box Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".3.name", "Steel Gear Box Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".4.name", "Titanium Gear Box Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".5.name", "Tungstensteel Gear Box Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".6.name", "Processor Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".7.name", "Data Drive Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".8.name", "Containment Field Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".9.name", "Assembler Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".10.name", "Pump Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".11.name", "Motor Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".12.name", "Bronze Pipe Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".13.name", "Steel Pipe Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".14.name", "Titanium Pipe Machine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".15.name", "Tungstensteel Pipe Machine Casing"); - ItemList.Casing_SolidSteel.set(new ItemStack(this, 1, 0)); - ItemList.Casing_FrostProof.set(new ItemStack(this, 1, 1)); - ItemList.Casing_Gearbox_Bronze.set(new ItemStack(this, 1, 2)); - ItemList.Casing_Gearbox_Steel.set(new ItemStack(this, 1, 3)); - ItemList.Casing_Gearbox_Titanium.set(new ItemStack(this, 1, 4)); - ItemList.Casing_Gearbox_TungstenSteel.set(new ItemStack(this, 1, 5)); - ItemList.Casing_Processor.set(new ItemStack(this, 1, 6)); - ItemList.Casing_DataDrive.set(new ItemStack(this, 1, 7)); - ItemList.Casing_ContainmentField.set(new ItemStack(this, 1, 8)); - ItemList.Casing_Assembler.set(new ItemStack(this, 1, 9)); - ItemList.Casing_Pump.set(new ItemStack(this, 1, 10)); - ItemList.Casing_Motor.set(new ItemStack(this, 1, 11)); - ItemList.Casing_Pipe_Bronze.set(new ItemStack(this, 1, 12)); - ItemList.Casing_Pipe_Steel.set(new ItemStack(this, 1, 13)); - ItemList.Casing_Pipe_Titanium.set(new ItemStack(this, 1, 14)); - ItemList.Casing_Pipe_TungstenSteel.set(new ItemStack(this, 1, 15)); - } - - public IIcon getIcon(int aSide, int aMeta) { - switch (aMeta) { - case 0: - return Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon(); - case 1: - return Textures.BlockIcons.MACHINE_CASING_FROST_PROOF.getIcon(); - case 2: - return Textures.BlockIcons.MACHINE_CASING_GEARBOX_BRONZE.getIcon(); - case 3: - return Textures.BlockIcons.MACHINE_CASING_GEARBOX_STEEL.getIcon(); - case 4: - return Textures.BlockIcons.MACHINE_CASING_GEARBOX_TITANIUM.getIcon(); - case 5: - return Textures.BlockIcons.MACHINE_CASING_GEARBOX_TUNGSTENSTEEL.getIcon(); - case 6: - return Textures.BlockIcons.MACHINE_CASING_PROCESSOR.getIcon(); - case 7: - return Textures.BlockIcons.MACHINE_CASING_DATA_DRIVE.getIcon(); - case 8: - return Textures.BlockIcons.MACHINE_CASING_CONTAINMENT_FIELD.getIcon(); - case 9: - return Textures.BlockIcons.MACHINE_CASING_ASSEMBLER.getIcon(); - case 10: - return Textures.BlockIcons.MACHINE_CASING_PUMP.getIcon(); - case 11: - return Textures.BlockIcons.MACHINE_CASING_MOTOR.getIcon(); - case 12: - return Textures.BlockIcons.MACHINE_CASING_PIPE_BRONZE.getIcon(); - case 13: - return Textures.BlockIcons.MACHINE_CASING_PIPE_STEEL.getIcon(); - case 14: - return Textures.BlockIcons.MACHINE_CASING_PIPE_TITANIUM.getIcon(); - case 15: - return Textures.BlockIcons.MACHINE_CASING_PIPE_TUNGSTENSTEEL.getIcon(); - } - return Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon(); - } - - public float getExplosionResistance(Entity aTNT, World aWorld, int aX, int aY, int aZ, double eX, double eY, double eZ) { - return aWorld.getBlockMetadata(aX, aY, aZ) == 8 ? Blocks.bedrock.getExplosionResistance(aTNT) : super.getExplosionResistance(aTNT, aWorld, aX, aY, aZ, eX, eY, eZ); - } -} diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Casings3.java b/src/main/java/gregtech/common/blocks/GT_Block_Casings3.java deleted file mode 100644 index a01e08ddb8..0000000000 --- a/src/main/java/gregtech/common/blocks/GT_Block_Casings3.java +++ /dev/null @@ -1,88 +0,0 @@ -package gregtech.common.blocks; - -import gregtech.api.enums.ItemList; -import gregtech.api.enums.Textures; -import gregtech.api.objects.GT_CopiedBlockTexture; -import gregtech.api.util.GT_LanguageManager; -import net.minecraft.item.ItemStack; -import net.minecraft.util.IIcon; - -public class GT_Block_Casings3 - extends GT_Block_Casings_Abstract { - public GT_Block_Casings3() { - super(GT_Item_Casings3.class, "gt.blockcasings3", GT_Material_Casings.INSTANCE); - for (byte i = 0; i < 16; i = (byte) (i + 1)) { - Textures.BlockIcons.CASING_BLOCKS[(i + 32)] = new GT_CopiedBlockTexture(this, 6, i); - } - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".0.name", "Yellow Stripes Block"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".1.name", "Yellow Stripes Block"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".2.name", "Radioactive Hazard Sign Block"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".3.name", "Bio Hazard Sign Block"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".4.name", "Explosion Hazard Sign Block"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".5.name", "Fire Hazard Sign Block"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".6.name", "Acid Hazard Sign Block"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".7.name", "Magic Hazard Sign Block"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".8.name", "Frost Hazard Sign Block"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".9.name", "Noise Hazard Sign Block"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".10.name", "Grate Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".11.name", "Vent Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".12.name", "Radiation Proof Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".13.name", "Bronze Firebox Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".14.name", "Steel Firebox Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".15.name", "Tungstensteel Firebox Casing"); - ItemList.Casing_Stripes_A.set(new ItemStack(this, 1, 0)); - ItemList.Casing_Stripes_B.set(new ItemStack(this, 1, 1)); - ItemList.Casing_RadioactiveHazard.set(new ItemStack(this, 1, 2)); - ItemList.Casing_BioHazard.set(new ItemStack(this, 1, 3)); - ItemList.Casing_ExplosionHazard.set(new ItemStack(this, 1, 4)); - ItemList.Casing_FireHazard.set(new ItemStack(this, 1, 5)); - ItemList.Casing_AcidHazard.set(new ItemStack(this, 1, 6)); - ItemList.Casing_MagicHazard.set(new ItemStack(this, 1, 7)); - ItemList.Casing_FrostHazard.set(new ItemStack(this, 1, 8)); - ItemList.Casing_NoiseHazard.set(new ItemStack(this, 1, 9)); - ItemList.Casing_Grate.set(new ItemStack(this, 1, 10)); - ItemList.Casing_Vent.set(new ItemStack(this, 1, 11)); - ItemList.Casing_RadiationProof.set(new ItemStack(this, 1, 12)); - ItemList.Casing_Firebox_Bronze.set(new ItemStack(this, 1, 13)); - ItemList.Casing_Firebox_Steel.set(new ItemStack(this, 1, 14)); - ItemList.Casing_Firebox_TungstenSteel.set(new ItemStack(this, 1, 15)); - } - - public IIcon getIcon(int aSide, int aMeta) { - switch (aMeta) { - case 0: - return Textures.BlockIcons.MACHINE_CASING_STRIPES_A.getIcon(); - case 1: - return Textures.BlockIcons.MACHINE_CASING_STRIPES_B.getIcon(); - case 2: - return Textures.BlockIcons.MACHINE_CASING_RADIOACTIVEHAZARD.getIcon(); - case 3: - return Textures.BlockIcons.MACHINE_CASING_BIOHAZARD.getIcon(); - case 4: - return Textures.BlockIcons.MACHINE_CASING_EXPLOSIONHAZARD.getIcon(); - case 5: - return Textures.BlockIcons.MACHINE_CASING_FIREHAZARD.getIcon(); - case 6: - return Textures.BlockIcons.MACHINE_CASING_ACIDHAZARD.getIcon(); - case 7: - return Textures.BlockIcons.MACHINE_CASING_MAGICHAZARD.getIcon(); - case 8: - return Textures.BlockIcons.MACHINE_CASING_FROSTHAZARD.getIcon(); - case 9: - return Textures.BlockIcons.MACHINE_CASING_NOISEHAZARD.getIcon(); - case 10: - return Textures.BlockIcons.MACHINE_CASING_GRATE.getIcon(); - case 11: - return Textures.BlockIcons.MACHINE_CASING_VENT.getIcon(); - case 12: - return Textures.BlockIcons.MACHINE_CASING_RADIATIONPROOF.getIcon(); - case 13: - return aSide > 1 ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_BRONZE.getIcon() : Textures.BlockIcons.MACHINE_BRONZEPLATEDBRICKS.getIcon(); - case 14: - return aSide > 1 ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_STEEL.getIcon() : Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon(); - case 15: - return aSide > 1 ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_TUNGSTENSTEEL.getIcon() : Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); - } - return Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon(); - } -} diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Casings4.java b/src/main/java/gregtech/common/blocks/GT_Block_Casings4.java deleted file mode 100644 index 1afe7f5e15..0000000000 --- a/src/main/java/gregtech/common/blocks/GT_Block_Casings4.java +++ /dev/null @@ -1,508 +0,0 @@ -package gregtech.common.blocks; - -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; -import gregtech.api.enums.ItemList; -import gregtech.api.enums.Textures; -import gregtech.api.interfaces.metatileentity.IMetaTileEntity; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; -import gregtech.api.objects.GT_CopiedBlockTexture; -import gregtech.api.util.GT_LanguageManager; -import gregtech.common.tileentities.machines.multi.GT_MetaTileEntity_LargeTurbine; -import net.minecraft.item.ItemStack; -import net.minecraft.tileentity.TileEntity; -import net.minecraft.util.IIcon; -import net.minecraft.world.IBlockAccess; - -public class GT_Block_Casings4 - extends GT_Block_Casings_Abstract { - public static boolean mConnectedMachineTextures = true; - - public GT_Block_Casings4() { - super(GT_Item_Casings4.class, "gt.blockcasings4", GT_Material_Casings.INSTANCE); - for (byte i = 0; i < 16; i = (byte) (i + 1)) { - Textures.BlockIcons.CASING_BLOCKS[(i + 48)] = new GT_CopiedBlockTexture(this, 6, i); - } - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".0.name", "Robust Tungstensteel Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".1.name", "Clean Stainless Steel Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".2.name", "Stable Titanium Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".3.name", "Titanium Firebox Casing"); -// GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".4.name", "Fusion Casing"); -// GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".5.name", "Fusion Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".6.name", "Fusion Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".7.name", "Fusion Coil"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".8.name", "Fusion Casing MK II"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".9.name", "Turbine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".10.name", "Stainless Steel Turbine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".11.name", "Titanium Turbine Casing"); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".12.name", "Tungstensteel Turbine Casing"); - - ItemList.Casing_RobustTungstenSteel.set(new ItemStack(this, 1, 0)); - ItemList.Casing_CleanStainlessSteel.set(new ItemStack(this, 1, 1)); - ItemList.Casing_StableTitanium.set(new ItemStack(this, 1, 2)); - ItemList.Casing_Firebox_Titanium.set(new ItemStack(this, 1, 3)); - ItemList.Casing_Fusion.set(new ItemStack(this, 1, 6)); - ItemList.Casing_Fusion_Coil.set(new ItemStack(this, 1, 7)); - ItemList.Casing_Fusion2.set(new ItemStack(this, 1, 8)); - ItemList.Casing_Turbine.set(new ItemStack(this, 1, 9)); - ItemList.Casing_Turbine1.set(new ItemStack(this, 1, 10)); - ItemList.Casing_Turbine2.set(new ItemStack(this, 1, 11)); - ItemList.Casing_Turbine3.set(new ItemStack(this, 1, 12)); - } - - public IIcon getIcon(int aSide, int aMeta) { - switch (aMeta) { - case 0: - return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); - case 1: - return Textures.BlockIcons.MACHINE_CASING_CLEAN_STAINLESSSTEEL.getIcon(); - case 2: - return Textures.BlockIcons.MACHINE_CASING_STABLE_TITANIUM.getIcon(); - case 3: - return aSide > 1 ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_TITANIUM.getIcon() : Textures.BlockIcons.MACHINE_CASING_STABLE_TITANIUM.getIcon(); - case 4: - return Textures.BlockIcons.MACHINE_CASING_FUSION_GLASS_YELLOW.getIcon(); - case 5: - return Textures.BlockIcons.MACHINE_CASING_FUSION_GLASS.getIcon(); - case 6: - return Textures.BlockIcons.MACHINE_CASING_FUSION.getIcon(); - case 7: - return Textures.BlockIcons.MACHINE_CASING_FUSION_COIL.getIcon(); - case 8: - return Textures.BlockIcons.MACHINE_CASING_FUSION_2.getIcon(); - case 9: - return Textures.BlockIcons.MACHINE_CASING_TURBINE.getIcon(); - case 10: - return Textures.BlockIcons.MACHINE_CASING_CLEAN_STAINLESSSTEEL.getIcon(); - case 11: - return Textures.BlockIcons.MACHINE_CASING_STABLE_TITANIUM.getIcon(); - case 12: - return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); - case 13: - return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); - case 14: - return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); - case 15: - return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); - } - return Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon(); - } - - public IIcon getTurbineCasing(int meta, int iconIndex, boolean active) { - switch (meta) { - case 9: - return active ? Textures.BlockIcons.TURBINE_ACTIVE[iconIndex].getIcon() : Textures.BlockIcons.TURBINE[iconIndex].getIcon(); - case 10: - return active ? Textures.BlockIcons.TURBINE_ACTIVE1[iconIndex].getIcon() : Textures.BlockIcons.TURBINE1[iconIndex].getIcon(); - case 11: - return active ? Textures.BlockIcons.TURBINE_ACTIVE2[iconIndex].getIcon() : Textures.BlockIcons.TURBINE2[iconIndex].getIcon(); - case 12: - return active ? Textures.BlockIcons.TURBINE_ACTIVE3[iconIndex].getIcon() : Textures.BlockIcons.TURBINE3[iconIndex].getIcon(); - default: - return active ? Textures.BlockIcons.TURBINE_ACTIVE[iconIndex].getIcon() : Textures.BlockIcons.TURBINE[iconIndex].getIcon(); - } - } - - @SideOnly(Side.CLIENT) - public IIcon getIcon(IBlockAccess aWorld, int xCoord, int yCoord, int zCoord, int aSide) { - int tMeta = aWorld.getBlockMetadata(xCoord, yCoord, zCoord); - if ((tMeta != 6) && (tMeta != 8) && (tMeta != 9) && (tMeta != 10) && (tMeta != 11) && (tMeta != 12) || (!mConnectedMachineTextures)) { - return getIcon(aSide, tMeta); - } - int tStartIndex = tMeta == 6 ? 1 : 13; - if ((tMeta == 9) || (tMeta == 10) || (tMeta == 11) || (tMeta == 12)) { - if ((aSide == 2) || (aSide == 3)) { - TileEntity tTileEntity; - IMetaTileEntity tMetaTileEntity; - if ((null != (tTileEntity = aWorld.getTileEntity(xCoord + (aSide == 3 ? 1 : -1), yCoord - 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { - if (((IGregTechTileEntity) tTileEntity).isActive()) { - return getTurbineCasing(tMeta, 0, true); - //return Textures.BlockIcons.TURBINE_ACTIVE[0].getIcon(); - } - return getTurbineCasing(tMeta, 0, false); - //return Textures.BlockIcons.TURBINE[0].getIcon(); - } - if ((null != (tTileEntity = aWorld.getTileEntity(xCoord + (aSide == 3 ? 1 : -1), yCoord, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { - if (((IGregTechTileEntity) tTileEntity).isActive()) { - return getTurbineCasing(tMeta, 3, true); - //return Textures.BlockIcons.TURBINE_ACTIVE[3].getIcon(); - } - return getTurbineCasing(tMeta, 3, false); - //return Textures.BlockIcons.TURBINE[3].getIcon(); - } - if ((null != (tTileEntity = aWorld.getTileEntity(xCoord + (aSide == 3 ? 1 : -1), yCoord + 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { - if (((IGregTechTileEntity) tTileEntity).isActive()) { - return getTurbineCasing(tMeta, 6, true); - //return Textures.BlockIcons.TURBINE_ACTIVE[6].getIcon(); - } - return getTurbineCasing(tMeta, 6, false); - //return Textures.BlockIcons.TURBINE[6].getIcon(); - } - if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord - 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { - if (((IGregTechTileEntity) tTileEntity).isActive()) { - return getTurbineCasing(tMeta, 1, true); - //return Textures.BlockIcons.TURBINE_ACTIVE[1].getIcon(); - } - return getTurbineCasing(tMeta, 1, false); - //return Textures.BlockIcons.TURBINE[1].getIcon(); - } - if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord + 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { - if (((IGregTechTileEntity) tTileEntity).isActive()) { - return getTurbineCasing(tMeta, 7, true); - //return Textures.BlockIcons.TURBINE_ACTIVE[7].getIcon(); - } - return getTurbineCasing(tMeta, 7, false); - //return Textures.BlockIcons.TURBINE[7].getIcon(); - } - if ((null != (tTileEntity = aWorld.getTileEntity(xCoord + (aSide == 2 ? 1 : -1), yCoord + 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { - if (((IGregTechTileEntity) tTileEntity).isActive()) { - return getTurbineCasing(tMeta, 8, true); - //return Textures.BlockIcons.TURBINE_ACTIVE[8].getIcon(); - } - return getTurbineCasing(tMeta, 8, false); - //return Textures.BlockIcons.TURBINE[8].getIcon(); - } - if ((null != (tTileEntity = aWorld.getTileEntity(xCoord + (aSide == 2 ? 1 : -1), yCoord, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { - if (((IGregTechTileEntity) tTileEntity).isActive()) { - return getTurbineCasing(tMeta, 5, true); - //return Textures.BlockIcons.TURBINE_ACTIVE[5].getIcon(); - } - return getTurbineCasing(tMeta, 5, false); - //return Textures.BlockIcons.TURBINE[5].getIcon(); - } - if ((null != (tTileEntity = aWorld.getTileEntity(xCoord + (aSide == 2 ? 1 : -1), yCoord - 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { - if (((IGregTechTileEntity) tTileEntity).isActive()) { - return getTurbineCasing(tMeta, 2, true); - //return Textures.BlockIcons.TURBINE_ACTIVE[2].getIcon(); - } - return getTurbineCasing(tMeta, 2, false); - //return Textures.BlockIcons.TURBINE[2].getIcon(); - } - } else if ((aSide == 4) || (aSide == 5)) { - TileEntity tTileEntity; - Object tMetaTileEntity; - if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord - 1, zCoord + (aSide == 4 ? 1 : -1)))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { - if (((IGregTechTileEntity) tTileEntity).isActive()) { - return getTurbineCasing(tMeta, 0, true); - //return Textures.BlockIcons.TURBINE_ACTIVE[0].getIcon(); - } - return getTurbineCasing(tMeta, 0, false); - //return Textures.BlockIcons.TURBINE[0].getIcon(); - } - if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord, zCoord + (aSide == 4 ? 1 : -1)))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { - if (((IGregTechTileEntity) tTileEntity).isActive()) { - return getTurbineCasing(tMeta, 3, true); - //return Textures.BlockIcons.TURBINE_ACTIVE[3].getIcon(); - } - return getTurbineCasing(tMeta, 3, false); - //return Textures.BlockIcons.TURBINE[3].getIcon(); - } - if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord + 1, zCoord + (aSide == 4 ? 1 : -1)))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { - if (((IGregTechTileEntity) tTileEntity).isActive()) { - return getTurbineCasing(tMeta, 6, true); - //return Textures.BlockIcons.TURBINE_ACTIVE[6].getIcon(); - } - return getTurbineCasing(tMeta, 6, false); - //return Textures.BlockIcons.TURBINE[6].getIcon(); - } - if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord - 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { - if (((IGregTechTileEntity) tTileEntity).isActive()) { - return getTurbineCasing(tMeta, 1, true); - //return Textures.BlockIcons.TURBINE_ACTIVE[1].getIcon(); - } - return getTurbineCasing(tMeta, 1, false); - //return Textures.BlockIcons.TURBINE[1].getIcon(); - } - if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord + 1, zCoord))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity) tTileEntity).getFrontFacing() == aSide) && (null != (tMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity())) && ((tMetaTileEntity instanceof GT_MetaTileEntity_LargeTurbine))) { - if (((IGregTechTileEntity) tTileEntity).isActive()) { - return getTurbineCasing(tMeta, 7, true); - //return Textures.BlockIcons.TURBINE_ACTIVE[7].getIcon(); - } - return getTurbineCasing(tMeta, 7, false); - //return Textures.BlockIcons.TURBINE[7].getIcon(); - } - if ((null != (tTileEntity = aWorld.getTileEntity(xCoord, yCoord + 1, zCoord + (aSide == 5 ? 1 : -1)))) && ((tTileEntity instanceof IGregTechTileEntity)) && (((IGregT