diff options
author | aerospark <lukefay12@gmail.com> | 2015-06-23 15:29:05 -0700 |
---|---|---|
committer | aerospark <lukefay12@gmail.com> | 2015-06-23 15:29:05 -0700 |
commit | a1504799f44ba2debdfef06317f24e7f9c1129d6 (patch) | |
tree | 53e53ff64d2902c639951bd1d41f942ee171f836 /main/java/gregtech/common/blocks | |
parent | b803f59de5a66fcb4ef53e117b912fbbc2841392 (diff) | |
download | GT5-Unofficial-a1504799f44ba2debdfef06317f24e7f9c1129d6.tar.gz GT5-Unofficial-a1504799f44ba2debdfef06317f24e7f9c1129d6.tar.bz2 GT5-Unofficial-a1504799f44ba2debdfef06317f24e7f9c1129d6.zip |
strip linenumbers
Diffstat (limited to 'main/java/gregtech/common/blocks')
24 files changed, 2461 insertions, 2461 deletions
diff --git a/main/java/gregtech/common/blocks/GT_Block_Casings1.java b/main/java/gregtech/common/blocks/GT_Block_Casings1.java index eea1784635..a24aee847f 100644 --- a/main/java/gregtech/common/blocks/GT_Block_Casings1.java +++ b/main/java/gregtech/common/blocks/GT_Block_Casings1.java @@ -1,93 +1,93 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import gregtech.api.enums.ItemList;
+package gregtech.common.blocks;
+
+import gregtech.api.enums.ItemList;
import gregtech.api.enums.Textures;
-/* 4: */ import gregtech.api.enums.Textures.BlockIcons;
-/* 5: */ import gregtech.api.interfaces.IIconContainer;
-/* 6: */ import gregtech.api.objects.GT_CopiedBlockTexture;
-/* 7: */ import gregtech.api.util.GT_LanguageManager;
-/* 8: */ import net.minecraft.item.ItemStack;
-/* 9: */ import net.minecraft.util.IIcon;
-/* 10: */ import net.minecraft.world.IBlockAccess;
-/* 11: */
-/* 12: */ public class GT_Block_Casings1
-/* 13: */ extends GT_Block_Casings_Abstract
-/* 14: */ {
-/* 15: */ public GT_Block_Casings1()
-/* 16: */ {
-/* 17:14 */ super(GT_Item_Casings1.class, "gt.blockcasings", GT_Material_Casings.INSTANCE);
-/* 18:15 */ for (byte i = 0; i < 16; i = (byte)(i + 1)) {
-/* 19:15 */ Textures.BlockIcons.CASING_BLOCKS[i] = new GT_CopiedBlockTexture(this, 6, i);
-/* 20: */ }
-/* 21:16 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".0.name", "ULV Machine Casing");
-/* 22:17 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".1.name", "LV Machine Casing");
-/* 23:18 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".2.name", "MV Machine Casing");
-/* 24:19 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".3.name", "HV Machine Casing");
-/* 25:20 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".4.name", "EV Machine Casing");
-/* 26:21 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".5.name", "IV Machine Casing");
-/* 27:22 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".6.name", "LuV Machine Casing");
-/* 28:23 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".7.name", "ZPM Machine Casing");
-/* 29:24 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".8.name", "UV Machine Casing");
-/* 30:25 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".9.name", "MAX Machine Casing");
-/* 31:26 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".10.name", "Bronze Plated Bricks");
-/* 32:27 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".11.name", "Heat Proof Machine Casing");
-/* 33:28 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".12.name", "Cupronickel Coil Block");
-/* 34:29 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".13.name", "Kanthal Coil Block");
-/* 35:30 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".14.name", "Nichrome Coil Block");
-/* 36:31 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".15.name", "Superconducting Coil Block");
-/* 37:32 */ ItemList.Casing_ULV.set(new ItemStack(this, 1, 0));
-/* 38:33 */ ItemList.Casing_LV.set(new ItemStack(this, 1, 1));
-/* 39:34 */ ItemList.Casing_MV.set(new ItemStack(this, 1, 2));
-/* 40:35 */ ItemList.Casing_HV.set(new ItemStack(this, 1, 3));
-/* 41:36 */ ItemList.Casing_EV.set(new ItemStack(this, 1, 4));
-/* 42:37 */ ItemList.Casing_IV.set(new ItemStack(this, 1, 5));
-/* 43:38 */ ItemList.Casing_LuV.set(new ItemStack(this, 1, 6));
-/* 44:39 */ ItemList.Casing_ZPM.set(new ItemStack(this, 1, 7));
-/* 45:40 */ ItemList.Casing_UV.set(new ItemStack(this, 1, 8));
-/* 46:41 */ ItemList.Casing_MAX.set(new ItemStack(this, 1, 9));
-/* 47:42 */ ItemList.Casing_BronzePlatedBricks.set(new ItemStack(this, 1, 10));
-/* 48:43 */ ItemList.Casing_HeatProof.set(new ItemStack(this, 1, 11));
-/* 49:44 */ ItemList.Casing_Coil_Cupronickel.set(new ItemStack(this, 1, 12));
-/* 50:45 */ ItemList.Casing_Coil_Kanthal.set(new ItemStack(this, 1, 13));
-/* 51:46 */ ItemList.Casing_Coil_Nichrome.set(new ItemStack(this, 1, 14));
-/* 52:47 */ ItemList.Casing_Coil_Superconductor.set(new ItemStack(this, 1, 15));
-/* 53: */ }
-/* 54: */
-/* 55: */ public IIcon getIcon(int aSide, int aMeta)
-/* 56: */ {
-/* 57:52 */ if ((aMeta >= 0) && (aMeta < 16))
-/* 58: */ {
-/* 59:53 */ switch (aMeta)
-/* 60: */ {
-/* 61: */ case 10:
-/* 62:54 */ return Textures.BlockIcons.MACHINE_BRONZEPLATEDBRICKS.getIcon();
-/* 63: */ case 11:
-/* 64:55 */ return Textures.BlockIcons.MACHINE_HEATPROOFCASING.getIcon();
-/* 65: */ case 12:
-/* 66:56 */ return Textures.BlockIcons.MACHINE_COIL_CUPRONICKEL.getIcon();
-/* 67: */ case 13:
-/* 68:57 */ return Textures.BlockIcons.MACHINE_COIL_KANTHAL.getIcon();
-/* 69: */ case 14:
-/* 70:58 */ return Textures.BlockIcons.MACHINE_COIL_NICHROME.getIcon();
-/* 71: */ case 15:
-/* 72:59 */ return Textures.BlockIcons.MACHINE_COIL_SUPERCONDUCTOR.getIcon();
-/* 73: */ }
-/* 74:61 */ if (aSide == 0) {
-/* 75:61 */ return Textures.BlockIcons.MACHINECASINGS_BOTTOM[aMeta].getIcon();
-/* 76: */ }
-/* 77:62 */ if (aSide == 1) {
-/* 78:62 */ return Textures.BlockIcons.MACHINECASINGS_TOP[aMeta].getIcon();
-/* 79: */ }
-/* 80:63 */ return Textures.BlockIcons.MACHINECASINGS_SIDE[aMeta].getIcon();
-/* 81: */ }
-/* 82:66 */ return Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon();
-/* 83: */ }
-/* 84: */
-/* 85: */ public int colorMultiplier(IBlockAccess aWorld, int aX, int aY, int aZ)
-/* 86: */ {
-/* 87:71 */ 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];
-/* 88: */ }
-/* 89: */ }
+import gregtech.api.enums.Textures.BlockIcons;
+import gregtech.api.interfaces.IIconContainer;
+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];
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Block_Casings2.java b/main/java/gregtech/common/blocks/GT_Block_Casings2.java index 88adea04b2..73d049be37 100644 --- a/main/java/gregtech/common/blocks/GT_Block_Casings2.java +++ b/main/java/gregtech/common/blocks/GT_Block_Casings2.java @@ -1,105 +1,105 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import gregtech.api.enums.ItemList;
+package gregtech.common.blocks;
+
+import gregtech.api.enums.ItemList;
import gregtech.api.enums.Textures;
-/* 4: */ import gregtech.api.enums.Textures.BlockIcons;
-/* 5: */ import gregtech.api.objects.GT_CopiedBlockTexture;
-/* 6: */ import gregtech.api.util.GT_LanguageManager;
-/* 7: */ import net.minecraft.block.Block;
-/* 8: */ import net.minecraft.entity.Entity;
-/* 9: */ import net.minecraft.init.Blocks;
-/* 10: */ import net.minecraft.item.ItemStack;
-/* 11: */ import net.minecraft.util.IIcon;
-/* 12: */ import net.minecraft.world.World;
-/* 13: */
-/* 14: */ public class GT_Block_Casings2
-/* 15: */ extends GT_Block_Casings_Abstract
-/* 16: */ {
-/* 17: */ public GT_Block_Casings2()
-/* 18: */ {
-/* 19:15 */ super(GT_Item_Casings2.class, "gt.blockcasings2", GT_Material_Casings.INSTANCE);
-/* 20:16 */ for (byte i = 0; i < 16; i = (byte)(i + 1)) {
-/* 21:16 */ Textures.BlockIcons.CASING_BLOCKS[(i + 16)] = new GT_CopiedBlockTexture(this, 6, i);
-/* 22: */ }
-/* 23:17 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".0.name", "Solid Steel Machine Casing");
-/* 24:18 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".1.name", "Frost Proof Machine Casing");
-/* 25:19 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".2.name", "Bronze Gear Box Casing");
-/* 26:20 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".3.name", "Steel Gear Box Casing");
-/* 27:21 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".4.name", "Titanium Gear Box Casing");
-/* 28:22 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".5.name", "Tungstensteel Gear Box Casing");
-/* 29:23 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".6.name", "Processor Machine Casing");
-/* 30:24 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".7.name", "Data Drive Machine Casing");
-/* 31:25 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".8.name", "Containment Field Machine Casing");
-/* 32:26 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".9.name", "Assembler Machine Casing");
-/* 33:27 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".10.name", "Pump Machine Casing");
-/* 34:28 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".11.name", "Motor Machine Casing");
-/* 35:29 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".12.name", "Bronze Pipe Machine Casing");
-/* 36:30 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".13.name", "Steel Pipe Machine Casing");
-/* 37:31 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".14.name", "Titanium Pipe Machine Casing");
-/* 38:32 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".15.name", "Tungstensteel Pipe Machine Casing");
-/* 39:33 */ ItemList.Casing_SolidSteel.set(new ItemStack(this, 1, 0));
-/* 40:34 */ ItemList.Casing_FrostProof.set(new ItemStack(this, 1, 1));
-/* 41:35 */ ItemList.Casing_Gearbox_Bronze.set(new ItemStack(this, 1, 2));
-/* 42:36 */ ItemList.Casing_Gearbox_Steel.set(new ItemStack(this, 1, 3));
-/* 43:37 */ ItemList.Casing_Gearbox_Titanium.set(new ItemStack(this, 1, 4));
-/* 44:38 */ ItemList.Casing_Gearbox_TungstenSteel.set(new ItemStack(this, 1, 5));
-/* 45:39 */ ItemList.Casing_Processor.set(new ItemStack(this, 1, 6));
-/* 46:40 */ ItemList.Casing_DataDrive.set(new ItemStack(this, 1, 7));
-/* 47:41 */ ItemList.Casing_ContainmentField.set(new ItemStack(this, 1, 8));
-/* 48:42 */ ItemList.Casing_Assembler.set(new ItemStack(this, 1, 9));
-/* 49:43 */ ItemList.Casing_Pump.set(new ItemStack(this, 1, 10));
-/* 50:44 */ ItemList.Casing_Motor.set(new ItemStack(this, 1, 11));
-/* 51:45 */ ItemList.Casing_Pipe_Bronze.set(new ItemStack(this, 1, 12));
-/* 52:46 */ ItemList.Casing_Pipe_Steel.set(new ItemStack(this, 1, 13));
-/* 53:47 */ ItemList.Casing_Pipe_Titanium.set(new ItemStack(this, 1, 14));
-/* 54:48 */ ItemList.Casing_Pipe_TungstenSteel.set(new ItemStack(this, 1, 15));
-/* 55: */ }
-/* 56: */
-/* 57: */ public IIcon getIcon(int aSide, int aMeta)
-/* 58: */ {
-/* 59:53 */ switch (aMeta)
-/* 60: */ {
-/* 61: */ case 0:
-/* 62:54 */ return Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon();
-/* 63: */ case 1:
-/* 64:55 */ return Textures.BlockIcons.MACHINE_CASING_FROST_PROOF.getIcon();
-/* 65: */ case 2:
-/* 66:56 */ return Textures.BlockIcons.MACHINE_CASING_GEARBOX_BRONZE.getIcon();
-/* 67: */ case 3:
-/* 68:57 */ return Textures.BlockIcons.MACHINE_CASING_GEARBOX_STEEL.getIcon();
-/* 69: */ case 4:
-/* 70:58 */ return Textures.BlockIcons.MACHINE_CASING_GEARBOX_TITANIUM.getIcon();
-/* 71: */ case 5:
-/* 72:59 */ return Textures.BlockIcons.MACHINE_CASING_GEARBOX_TUNGSTENSTEEL.getIcon();
-/* 73: */ case 6:
-/* 74:60 */ return Textures.BlockIcons.MACHINE_CASING_PROCESSOR.getIcon();
-/* 75: */ case 7:
-/* 76:61 */ return Textures.BlockIcons.MACHINE_CASING_DATA_DRIVE.getIcon();
-/* 77: */ case 8:
-/* 78:62 */ return Textures.BlockIcons.MACHINE_CASING_CONTAINMENT_FIELD.getIcon();
-/* 79: */ case 9:
-/* 80:63 */ return Textures.BlockIcons.MACHINE_CASING_ASSEMBLER.getIcon();
-/* 81: */ case 10:
-/* 82:64 */ return Textures.BlockIcons.MACHINE_CASING_PUMP.getIcon();
-/* 83: */ case 11:
-/* 84:65 */ return Textures.BlockIcons.MACHINE_CASING_MOTOR.getIcon();
-/* 85: */ case 12:
-/* 86:66 */ return Textures.BlockIcons.MACHINE_CASING_PIPE_BRONZE.getIcon();
-/* 87: */ case 13:
-/* 88:67 */ return Textures.BlockIcons.MACHINE_CASING_PIPE_STEEL.getIcon();
-/* 89: */ case 14:
-/* 90:68 */ return Textures.BlockIcons.MACHINE_CASING_PIPE_TITANIUM.getIcon();
-/* 91: */ case 15:
-/* 92:69 */ return Textures.BlockIcons.MACHINE_CASING_PIPE_TUNGSTENSTEEL.getIcon();
-/* 93: */ }
-/* 94:71 */ return Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon();
-/* 95: */ }
-/* 96: */
-/* 97: */ public float getExplosionResistance(Entity aTNT, World aWorld, int aX, int aY, int aZ, double eX, double eY, double eZ)
-/* 98: */ {
-/* 99:76 */ return aWorld.getBlockMetadata(aX, aY, aZ) == 8 ? Blocks.bedrock.getExplosionResistance(aTNT) : super.getExplosionResistance(aTNT, aWorld, aX, aY, aZ, eX, eY, eZ);
-/* :0: */ }
-/* :1: */ }
+import gregtech.api.enums.Textures.BlockIcons;
+import gregtech.api.objects.GT_CopiedBlockTexture;
+import gregtech.api.util.GT_LanguageManager;
+import net.minecraft.block.Block;
+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);
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Block_Casings3.java b/main/java/gregtech/common/blocks/GT_Block_Casings3.java index 8e1a9b0342..30e46a8c45 100644 --- a/main/java/gregtech/common/blocks/GT_Block_Casings3.java +++ b/main/java/gregtech/common/blocks/GT_Block_Casings3.java @@ -1,96 +1,96 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import gregtech.api.enums.ItemList;
+package gregtech.common.blocks;
+
+import gregtech.api.enums.ItemList;
import gregtech.api.enums.Textures;
-/* 4: */ import gregtech.api.enums.Textures.BlockIcons;
-/* 5: */ import gregtech.api.objects.GT_CopiedBlockTexture;
-/* 6: */ import gregtech.api.util.GT_LanguageManager;
-/* 7: */ import net.minecraft.item.ItemStack;
-/* 8: */ import net.minecraft.util.IIcon;
-/* 9: */
-/* 10: */ public class GT_Block_Casings3
-/* 11: */ extends GT_Block_Casings_Abstract
-/* 12: */ {
-/* 13: */ public GT_Block_Casings3()
-/* 14: */ {
-/* 15:12 */ super(GT_Item_Casings3.class, "gt.blockcasings3", GT_Material_Casings.INSTANCE);
-/* 16:13 */ for (byte i = 0; i < 16; i = (byte)(i + 1)) {
-/* 17:13 */ Textures.BlockIcons.CASING_BLOCKS[(i + 32)] = new GT_CopiedBlockTexture(this, 6, i);
-/* 18: */ }
-/* 19:14 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".0.name", "Yellow Stripes Block");
-/* 20:15 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".1.name", "Yellow Stripes Block");
-/* 21:16 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".2.name", "Radioactive Hazard Sign Block");
-/* 22:17 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".3.name", "Bio Hazard Sign Block");
-/* 23:18 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".4.name", "Explosion Hazard Sign Block");
-/* 24:19 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".5.name", "Fire Hazard Sign Block");
-/* 25:20 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".6.name", "Acid Hazard Sign Block");
-/* 26:21 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".7.name", "Magic Hazard Sign Block");
-/* 27:22 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".8.name", "Frost Hazard Sign Block");
-/* 28:23 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".9.name", "Noise Hazard Sign Block");
-/* 29:24 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".10.name", "Grate Casing");
-/* 30:25 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".11.name", "Vent Casing");
-/* 31:26 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".12.name", "Radiation Proof Casing");
-/* 32:27 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".13.name", "Bronze Firebox Casing");
-/* 33:28 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".14.name", "Steel Firebox Casing");
-/* 34:29 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".15.name", "Tungstensteel Firebox Casing");
-/* 35:30 */ ItemList.Casing_Stripes_A.set(new ItemStack(this, 1, 0));
-/* 36:31 */ ItemList.Casing_Stripes_B.set(new ItemStack(this, 1, 1));
-/* 37:32 */ ItemList.Casing_RadioactiveHazard.set(new ItemStack(this, 1, 2));
-/* 38:33 */ ItemList.Casing_BioHazard.set(new ItemStack(this, 1, 3));
-/* 39:34 */ ItemList.Casing_ExplosionHazard.set(new ItemStack(this, 1, 4));
-/* 40:35 */ ItemList.Casing_FireHazard.set(new ItemStack(this, 1, 5));
-/* 41:36 */ ItemList.Casing_AcidHazard.set(new ItemStack(this, 1, 6));
-/* 42:37 */ ItemList.Casing_MagicHazard.set(new ItemStack(this, 1, 7));
-/* 43:38 */ ItemList.Casing_FrostHazard.set(new ItemStack(this, 1, 8));
-/* 44:39 */ ItemList.Casing_NoiseHazard.set(new ItemStack(this, 1, 9));
-/* 45:40 */ ItemList.Casing_Grate.set(new ItemStack(this, 1, 10));
-/* 46:41 */ ItemList.Casing_Vent.set(new ItemStack(this, 1, 11));
-/* 47:42 */ ItemList.Casing_RadiationProof.set(new ItemStack(this, 1, 12));
-/* 48:43 */ ItemList.Casing_Firebox_Bronze.set(new ItemStack(this, 1, 13));
-/* 49:44 */ ItemList.Casing_Firebox_Steel.set(new ItemStack(this, 1, 14));
-/* 50:45 */ ItemList.Casing_Firebox_TungstenSteel.set(new ItemStack(this, 1, 15));
-/* 51: */ }
-/* 52: */
-/* 53: */ public IIcon getIcon(int aSide, int aMeta)
-/* 54: */ {
-/* 55:50 */ switch (aMeta)
-/* 56: */ {
-/* 57: */ case 0:
-/* 58:51 */ return Textures.BlockIcons.MACHINE_CASING_STRIPES_A.getIcon();
-/* 59: */ case 1:
-/* 60:52 */ return Textures.BlockIcons.MACHINE_CASING_STRIPES_B.getIcon();
-/* 61: */ case 2:
-/* 62:53 */ return Textures.BlockIcons.MACHINE_CASING_RADIOACTIVEHAZARD.getIcon();
-/* 63: */ case 3:
-/* 64:54 */ return Textures.BlockIcons.MACHINE_CASING_BIOHAZARD.getIcon();
-/* 65: */ case 4:
-/* 66:55 */ return Textures.BlockIcons.MACHINE_CASING_EXPLOSIONHAZARD.getIcon();
-/* 67: */ case 5:
-/* 68:56 */ return Textures.BlockIcons.MACHINE_CASING_FIREHAZARD.getIcon();
-/* 69: */ case 6:
-/* 70:57 */ return Textures.BlockIcons.MACHINE_CASING_ACIDHAZARD.getIcon();
-/* 71: */ case 7:
-/* 72:58 */ return Textures.BlockIcons.MACHINE_CASING_MAGICHAZARD.getIcon();
-/* 73: */ case 8:
-/* 74:59 */ return Textures.BlockIcons.MACHINE_CASING_FROSTHAZARD.getIcon();
-/* 75: */ case 9:
-/* 76:60 */ return Textures.BlockIcons.MACHINE_CASING_NOISEHAZARD.getIcon();
-/* 77: */ case 10:
-/* 78:61 */ return Textures.BlockIcons.MACHINE_CASING_GRATE.getIcon();
-/* 79: */ case 11:
-/* 80:62 */ return Textures.BlockIcons.MACHINE_CASING_VENT.getIcon();
-/* 81: */ case 12:
-/* 82:63 */ return Textures.BlockIcons.MACHINE_CASING_RADIATIONPROOF.getIcon();
-/* 83: */ case 13:
-/* 84:64 */ return aSide > 1 ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_BRONZE.getIcon() : Textures.BlockIcons.MACHINE_BRONZEPLATEDBRICKS.getIcon();
-/* 85: */ case 14:
-/* 86:65 */ return aSide > 1 ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_STEEL.getIcon() : Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon();
-/* 87: */ case 15:
-/* 88:66 */ return aSide > 1 ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_TUNGSTENSTEEL.getIcon() : Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon();
-/* 89: */ }
-/* 90:68 */ return Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon();
-/* 91: */ }
-/* 92: */ }
+import gregtech.api.enums.Textures.BlockIcons;
+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();
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Block_Casings4.java b/main/java/gregtech/common/blocks/GT_Block_Casings4.java index 12a470dc50..a0a3221d28 100644 --- a/main/java/gregtech/common/blocks/GT_Block_Casings4.java +++ b/main/java/gregtech/common/blocks/GT_Block_Casings4.java @@ -1,91 +1,91 @@ -/* 1: */ package gregtech.common.blocks; -/* 2: */ -/* 3: */ import cpw.mods.fml.relauncher.Side; +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; -/* 4: */ import gregtech.api.enums.Textures.BlockIcons; +import gregtech.api.enums.Textures.BlockIcons; import gregtech.api.interfaces.metatileentity.IMetaTileEntity; import gregtech.api.interfaces.tileentity.IGregTechTileEntity; -/* 5: */ import gregtech.api.objects.GT_CopiedBlockTexture; -/* 6: */ import gregtech.api.util.GT_LanguageManager; +import gregtech.api.objects.GT_CopiedBlockTexture; +import gregtech.api.util.GT_LanguageManager; import gregtech.common.tileentities.machines.multi.GT_MetaTileEntity_LargeTurbine; -/* 7: */ import net.minecraft.item.ItemStack; +import net.minecraft.item.ItemStack; import net.minecraft.tileentity.TileEntity; -/* 8: */ import net.minecraft.util.IIcon; +import net.minecraft.util.IIcon; import net.minecraft.world.IBlockAccess; -/* 9: */ -/* 10: */ public class GT_Block_Casings4 -/* 11: */ extends GT_Block_Casings_Abstract -/* 12: */ { + +public class GT_Block_Casings4 + extends GT_Block_Casings_Abstract +{ public static boolean mConnectedMachineTextures = true; -/* 13: */ public GT_Block_Casings4() -/* 14: */ { -/* 15:12 */ super(GT_Item_Casings4.class, "gt.blockcasings4", GT_Material_Casings.INSTANCE); -/* 16:13 */ for (byte i = 0; i < 16; i = (byte)(i + 1)) { -/* 17:13 */ Textures.BlockIcons.CASING_BLOCKS[(i + 48)] = new GT_CopiedBlockTexture(this, 6, i); -/* 18: */ } -/* 19:14 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".0.name", "Robust Tungstensteel Casing"); -/* 20:15 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".1.name", "Clean Stainless Steel Casing"); -/* 21:16 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".2.name", "Stable Titanium Casing"); -/* 22:17 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".3.name", "Titanium Firebox Casing"); -///* 23: */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".4.name", "Fusion Casing"); -///* 23: */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".5.name", "Fusion Casing"); -/* 23: */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".6.name", "Fusion Casing"); -/* 23: */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".7.name", "Fusion Coil"); -/* 24: */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".8.name", "Fusion Casing MK II"); -/* 25: */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".9.name", "Turbine Casing"); -/* 25: */ -/* 35:30 */ ItemList.Casing_RobustTungstenSteel.set(new ItemStack(this, 1, 0)); -/* 36:31 */ ItemList.Casing_CleanStainlessSteel.set(new ItemStack(this, 1, 1)); -/* 37:32 */ ItemList.Casing_StableTitanium.set(new ItemStack(this, 1, 2)); -/* 38:33 */ ItemList.Casing_Firebox_Titanium.set(new ItemStack(this, 1, 3)); + 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"); + + 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)); -/* 39: */ } -/* 40: */ -/* 41: */ public IIcon getIcon(int aSide, int aMeta) -/* 42: */ { -/* 43:50 */ switch (aMeta) -/* 44: */ { -/* 45: */ case 0: -/* 46:51 */ return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); -/* 47: */ case 1: -/* 48:52 */ return Textures.BlockIcons.MACHINE_CASING_CLEAN_STAINLESSSTEEL.getIcon(); -/* 49: */ case 2: -/* 50:53 */ return Textures.BlockIcons.MACHINE_CASING_STABLE_TITANIUM.getIcon(); -/* 51: */ case 3: -/* 52:54 */ return aSide > 1 ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_TITANIUM.getIcon() : Textures.BlockIcons.MACHINE_CASING_STABLE_TITANIUM.getIcon(); -/* 53: */ case 4: -/* 54:55 */ return Textures.BlockIcons.MACHINE_CASING_FUSION_GLASS_YELLOW.getIcon(); -/* 55: */ case 5: -/* 56:56 */ return Textures.BlockIcons.MACHINE_CASING_FUSION_GLASS.getIcon(); -/* 57: */ case 6: -/* 58:57 */ return Textures.BlockIcons.MACHINE_CASING_FUSION.getIcon(); -/* 59: */ case 7: -/* 60:58 */ return Textures.BlockIcons.MACHINE_CASING_FUSION_COIL.getIcon(); -/* 61: */ case 8: -/* 62:59 */ return Textures.BlockIcons.MACHINE_CASING_FUSION_2.getIcon(); -/* 63: */ case 9: -/* 64:60 */ return Textures.BlockIcons.MACHINE_CASING_TURBINE.getIcon(); -/* 65: */ case 10: -/* 66:61 */ return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); -/* 67: */ case 11: -/* 68:62 */ return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); -/* 69: */ case 12: -/* 70:63 */ return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); -/* 71: */ case 13: -/* 72:64 */ return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); -/* 73: */ case 14: -/* 74:65 */ return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); -/* 75: */ case 15: -/* 76:66 */ return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon(); -/* 77: */ } -/* 78:68 */ return Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon(); -/* 79: */ } + } + + 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_ROBUST_TUNGSTENSTEEL.getIcon(); + case 11: + return Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.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(); + } @SideOnly(Side.CLIENT) public IIcon getIcon(IBlockAccess aWorld, int xCoord, int yCoord, int zCoord, int aSide) diff --git a/main/java/gregtech/common/blocks/GT_Block_Casings_Abstract.java b/main/java/gregtech/common/blocks/GT_Block_Casings_Abstract.java index e34cd45d50..fa04e49024 100644 --- a/main/java/gregtech/common/blocks/GT_Block_Casings_Abstract.java +++ b/main/java/gregtech/common/blocks/GT_Block_Casings_Abstract.java @@ -1,143 +1,143 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import cpw.mods.fml.relauncher.Side;
-/* 4: */ import cpw.mods.fml.relauncher.SideOnly;
-/* 5: */ import gregtech.api.GregTech_API;
-/* 6: */ import gregtech.api.items.GT_Generic_Block;
-/* 7: */ import gregtech.api.util.GT_LanguageManager;
-/* 8: */ import java.util.List;
-/* 9: */ import java.util.Random;
-/* 10: */ import net.minecraft.block.Block;
-/* 11: */ import net.minecraft.block.material.Material;
-/* 12: */ import net.minecraft.client.renderer.texture.IIconRegister;
-/* 13: */ import net.minecraft.creativetab.CreativeTabs;
-/* 14: */ import net.minecraft.entity.Entity;
-/* 15: */ import net.minecraft.entity.EnumCreatureType;
-/* 16: */ import net.minecraft.init.Blocks;
-/* 17: */ import net.minecraft.item.Item;
-/* 18: */ import net.minecraft.item.ItemBlock;
-/* 19: */ import net.minecraft.item.ItemStack;
-/* 20: */ import net.minecraft.util.StatCollector;
-/* 21: */ import net.minecraft.world.IBlockAccess;
-/* 22: */ import net.minecraft.world.World;
-/* 23: */
-/* 24: */ public abstract class GT_Block_Casings_Abstract
-/* 25: */ extends GT_Generic_Block
-/* 26: */ {
-/* 27: */ public GT_Block_Casings_Abstract(Class<? extends ItemBlock> aItemClass, String aName, Material aMaterial)
-/* 28: */ {
-/* 29: 29 */ super(aItemClass, aName, aMaterial);
-/* 30: 30 */ setStepSound(soundTypeMetal);
-/* 31: 31 */ setCreativeTab(GregTech_API.TAB_GREGTECH);
-/* 32: 32 */ GregTech_API.registerMachineBlock(this, -1);
-/* 33: 33 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + 32767 + ".name", "Any Sub Block of this");
-/* 34: */ }
-/* 35: */
-/* 36: */ public String getHarvestTool(int aMeta)
-/* 37: */ {
-/* 38: 38 */ return "wrench";
-/* 39: */ }
-/* 40: */
-/* 41: */ public int getHarvestLevel(int aMeta)
-/* 42: */ {
-/* 43: 43 */ return 2;
-/* 44: */ }
-/* 45: */
-/* 46: */ public float getBlockHardness(World aWorld, int aX, int aY, int aZ)
-/* 47: */ {
-/* 48: 48 */ return Blocks.iron_block.getBlockHardness(aWorld, aX, aY, aZ);
-/* 49: */ }
-/* 50: */
-/* 51: */ public float getExplosionResistance(Entity aTNT)
-/* 52: */ {
-/* 53: 53 */ return Blocks.iron_block.getExplosionResistance(aTNT);
-/* 54: */ }
-/* 55: */
-/* 56: */ protected boolean canSilkHarvest()
-/* 57: */ {
-/* 58: 58 */ return false;
-/* 59: */ }
-/* 60: */
-/* 61: */ public void onBlockAdded(World aWorld, int aX, int aY, int aZ)
-/* 62: */ {
-/* 63: 61 */ if (GregTech_API.isMachineBlock(this, aWorld.getBlockMetadata(aX, aY, aZ))) {
-/* 64: 61 */ GregTech_API.causeMachineUpdate(aWorld, aX, aY, aZ);
-/* 65: */ }
-/* 66: */ }
-/* 67: */
-/* 68: */ public String getUnlocalizedName()
-/* 69: */ {
-/* 70: 62 */ return this.mUnlocalizedName;
-/* 71: */ }
-/* 72: */
-/* 73: */ public String getLocalizedName()
-/* 74: */ {
-/* 75: 63 */ return StatCollector.translateToLocal(this.mUnlocalizedName + ".name");
-/* 76: */ }
-/* 77: */
-/* 78: */ public boolean canBeReplacedByLeaves(IBlockAccess aWorld, int aX, int aY, int aZ)
-/* 79: */ {
-/* 80: 64 */ return false;
-/* 81: */ }
-/* 82: */
-/* 83: */ public boolean isNormalCube(IBlockAccess aWorld, int aX, int aY, int aZ)
-/* 84: */ {
-/* 85: 65 */ return true;
-/* 86: */ }
-/* 87: */
-/* 88: */ public boolean renderAsNormalBlock()
-/* 89: */ {
-/* 90: 66 */ return true;
-/* 91: */ }
-/* 92: */
-/* 93: */ public boolean isOpaqueCube()
-/* 94: */ {
-/* 95: 67 */ return true;
-/* 96: */ }
-/* 97: */
-/* 98: */ public void breakBlock(World aWorld, int aX, int aY, int aZ, Block aBlock, int aMetaData)
-/* 99: */ {
-/* 100: 71 */ if (GregTech_API.isMachineBlock(this, aWorld.getBlockMetadata(aX, aY, aZ))) {
-/* 101: 71 */ GregTech_API.causeMachineUpdate(aWorld, aX, aY, aZ);
-/* 102: */ }
-/* 103: */ }
-/* 104: */
-/* 105: */ public boolean canCreatureSpawn(EnumCreatureType type, IBlockAccess world, int x, int y, int z)
-/* 106: */ {
-/* 107: 76 */ return false;
-/* 108: */ }
-/* 109: */
-/* 110: */ public int damageDropped(int par1)
-/* 111: */ {
-/* 112: 81 */ return par1;
-/* 113: */ }
-/* 114: */
-/* 115: */ public int getDamageValue(World par1World, int par2, int par3, int par4)
-/* 116: */ {
-/* 117: 86 */ return par1World.getBlockMetadata(par2, par3, par4);
-/* 118: */ }
-/* 119: */
-/* 120: */ public int quantityDropped(Random par1Random)
-/* 121: */ {
-/* 122: 91 */ return 1;
-/* 123: */ }
-/* 124: */
-/* 125: */ public Item getItemDropped(int par1, Random par2Random, int par3)
-/* 126: */ {
-/* 127: 96 */ return Item.getItemFromBlock(this);
-/* 128: */ }
-/* 129: */
-/* 130: */ @SideOnly(Side.CLIENT)
-/* 131: */ public void registerBlockIcons(IIconRegister aIconRegister) {}
-/* 132: */
-/* 133: */ @SideOnly(Side.CLIENT)
-/* 134: */ public void getSubBlocks(Item aItem, CreativeTabs par2CreativeTabs, List aList)
-/* 135: */ {
-/* 136:107 */ for (int i = 0; i < 16; i++) {
-/* 137:107 */ aList.add(new ItemStack(aItem, 1, i));
-/* 138: */ }
-/* 139: */ }
-/* 140: */ }
+package gregtech.common.blocks;
+
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.GregTech_API;
+import gregtech.api.items.GT_Generic_Block;
+import gregtech.api.util.GT_LanguageManager;
+import java.util.List;
+import java.util.Random;
+import net.minecraft.block.Block;
+import net.minecraft.block.material.Material;
+import net.minecraft.client.renderer.texture.IIconRegister;
+import net.minecraft.creativetab.CreativeTabs;
+import net.minecraft.entity.Entity;
+import net.minecraft.entity.EnumCreatureType;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.Item;
+import net.minecraft.item.ItemBlock;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.StatCollector;
+import net.minecraft.world.IBlockAccess;
+import net.minecraft.world.World;
+
+public abstract class GT_Block_Casings_Abstract
+ extends GT_Generic_Block
+{
+ public GT_Block_Casings_Abstract(Class<? extends ItemBlock> aItemClass, String aName, Material aMaterial)
+ {
+ super(aItemClass, aName, aMaterial);
+ setStepSound(soundTypeMetal);
+ setCreativeTab(GregTech_API.TAB_GREGTECH);
+ GregTech_API.registerMachineBlock(this, -1);
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + 32767 + ".name", "Any Sub Block of this");
+ }
+
+ public String getHarvestTool(int aMeta)
+ {
+ return "wrench";
+ }
+
+ public int getHarvestLevel(int aMeta)
+ {
+ return 2;
+ }
+
+ public float getBlockHardness(World aWorld, int aX, int aY, int aZ)
+ {
+ return Blocks.iron_block.getBlockHardness(aWorld, aX, aY, aZ);
+ }
+
+ public float getExplosionResistance(Entity aTNT)
+ {
+ return Blocks.iron_block.getExplosionResistance(aTNT);
+ }
+
+ protected boolean canSilkHarvest()
+ {
+ return false;
+ }
+
+ public void onBlockAdded(World aWorld, int aX, int aY, int aZ)
+ {
+ if (GregTech_API.isMachineBlock(this, aWorld.getBlockMetadata(aX, aY, aZ))) {
+ GregTech_API.causeMachineUpdate(aWorld, aX, aY, aZ);
+ }
+ }
+
+ public String getUnlocalizedName()
+ {
+ return this.mUnlocalizedName;
+ }
+
+ public String getLocalizedName()
+ {
+ return StatCollector.translateToLocal(this.mUnlocalizedName + ".name");
+ }
+
+ public boolean canBeReplacedByLeaves(IBlockAccess aWorld, int aX, int aY, int aZ)
+ {
+ return false;
+ }
+
+ public boolean isNormalCube(IBlockAccess aWorld, int aX, int aY, int aZ)
+ {
+ return true;
+ }
+
+ public boolean renderAsNormalBlock()
+ {
+ return true;
+ }
+
+ public boolean isOpaqueCube()
+ {
+ return true;
+ }
+
+ public void breakBlock(World aWorld, int aX, int aY, int aZ, Block aBlock, int aMetaData)
+ {
+ if (GregTech_API.isMachineBlock(this, aWorld.getBlockMetadata(aX, aY, aZ))) {
+ GregTech_API.causeMachineUpdate(aWorld, aX, aY, aZ);
+ }
+ }
+
+ public boolean canCreatureSpawn(EnumCreatureType type, IBlockAccess world, int x, int y, int z)
+ {
+ return false;
+ }
+
+ public int damageDropped(int par1)
+ {
+ return par1;
+ }
+
+ public int getDamageValue(World par1World, int par2, int par3, int par4)
+ {
+ return par1World.getBlockMetadata(par2, par3, par4);
+ }
+
+ public int quantityDropped(Random par1Random)
+ {
+ return 1;
+ }
+
+ public Item getItemDropped(int par1, Random par2Random, int par3)
+ {
+ return Item.getItemFromBlock(this);
+ }
+
+ @SideOnly(Side.CLIENT)
+ public void registerBlockIcons(IIconRegister aIconRegister) {}
+
+ @SideOnly(Side.CLIENT)
+ public void getSubBlocks(Item aItem, CreativeTabs par2CreativeTabs, List aList)
+ {
+ for (int i = 0; i < 16; i++) {
+ aList.add(new ItemStack(aItem, 1, i));
+ }
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Block_Concretes.java b/main/java/gregtech/common/blocks/GT_Block_Concretes.java index 54c762f49a..d312719bc3 100644 --- a/main/java/gregtech/common/blocks/GT_Block_Concretes.java +++ b/main/java/gregtech/common/blocks/GT_Block_Concretes.java @@ -1,107 +1,107 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import gregtech.api.enums.Materials;
-/* 4: */ import gregtech.api.enums.OrePrefixes;
-/* 5: */ import gregtech.api.interfaces.IIconContainer;
-/* 6: */ import gregtech.api.util.GT_LanguageManager;
-/* 7: */ import gregtech.api.util.GT_OreDictUnificator;
-/* 8: */ import net.minecraft.block.Block;
-/* 9: */ import net.minecraft.block.BlockLiquid;
-/* 10: */ import net.minecraft.entity.Entity;
-/* 11: */ import net.minecraft.entity.EntityLivingBase;
-/* 12: */ import net.minecraft.init.Blocks;
-/* 13: */ import net.minecraft.item.ItemStack;
-/* 14: */ import net.minecraft.util.AxisAlignedBB;
-/* 15: */ import net.minecraft.util.IIcon;
-/* 16: */ import net.minecraft.world.World;
-/* 17: */ import net.minecraftforge.fluids.IFluidBlock;
-/* 18: */
-/* 19: */ public class GT_Block_Concretes
-/* 20: */ extends GT_Block_Stones_Abstract
-/* 21: */ {
-/* 22: */ public GT_Block_Concretes()
-/* 23: */ {
-/* 24:21 */ super(GT_Item_Concretes.class, "gt.blockconcretes");
-/* 25:22 */ setResistance(20.0F);
-/* 26:23 */ this.slipperiness = 0.9F;
-/* 27:24 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".0.name", "Dark Concrete");
-/* 28:25 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".1.name", "Dark Concrete Cobblestone");
-/* 29:26 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".2.name", "Mossy Dark Concrete Cobblestone");
-/* 30:27 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".3.name", "Dark Concrete Bricks");
-/* 31:28 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".4.name", "Cracked Dark Concrete Bricks");
-/* 32:29 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".5.name", "Mossy Dark Concrete Bricks");
-/* 33:30 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".6.name", "Chiseled Dark Concrete");
-/* 34:31 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".7.name", "Smooth Dark Concrete");
-/* 35:32 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".8.name", "Light Concrete");
-/* 36:33 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".9.name", "Light Concrete Cobblestone");
-/* 37:34 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".10.name", "Mossy Light Concrete Cobblestone");
-/* 38:35 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".11.name", "Light Concrete Bricks");
-/* 39:36 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".12.name", "Cracked Light Concrete Bricks");
-/* 40:37 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".13.name", "Mossy Light Concrete Bricks");
-/* 41:38 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".14.name", "Chiseled Light Concrete");
-/* 42:39 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".15.name", "Smooth Light Concrete");
-/* 43:40 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 0));
-/* 44:41 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 1));
-/* 45:42 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 2));
-/* 46:43 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 3));
-/* 47:44 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 4));
-/* 48:45 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 5));
-/* 49:46 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 6));
-/* 50:47 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 7));
-/* 51:48 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 8));
-/* 52:49 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 9));
-/* 53:50 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 10));
-/* 54:51 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 11));
-/* 55:52 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 12));
-/* 56:53 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 13));
-/* 57:54 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 14));
-/* 58:55 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 15));
-/* 59: */ }
-/* 60: */
-/* 61: */ public int getHarvestLevel(int aMeta)
-/* 62: */ {
-/* 63:60 */ return 1;
-/* 64: */ }
-/* 65: */
-/* 66: */ public float getBlockHardness(World aWorld, int aX, int aY, int aZ)
-/* 67: */ {
-/* 68:65 */ return this.blockHardness = Blocks.stone.getBlockHardness(aWorld, aX, aY, aZ);
-/* 69: */ }
-/* 70: */
-/* 71: */ public IIcon getIcon(int aSide, int aMeta)
-/* 72: */ {
-/* 73:68 */ if ((aMeta >= 0) && (aMeta < 16)) {
-/* 74:68 */ return gregtech.api.enums.Textures.BlockIcons.CONCRETES[aMeta].getIcon();
-/* 75: */ }
-/* 76:68 */ return gregtech.api.enums.Textures.BlockIcons.CONCRETES[0].getIcon();
-/* 77: */ }
-/* 78: */
-/* 79: */ public void onEntityCollidedWithBlock(World aWorld, int aX, int aY, int aZ, Entity aEntity)
-/* 80: */ {
-/* 81:72 */ Block tBlock = aWorld.getBlock(aX, aY + 1, aZ);
-/* 82:73 */ if (((aEntity instanceof EntityLivingBase)) && (!(tBlock instanceof IFluidBlock)) && (!(tBlock instanceof BlockLiquid)) && (aEntity.onGround) && (!aEntity.isInWater()) && (!aEntity.isWet())) {
-/* 83:74 */ if (aEntity.isSneaking())
-/* 84: */ {
-/* 85:75 */ aEntity.motionX *= 0.8999999761581421D;
-/* 86:76 */ aEntity.motionZ *= 0.8999999761581421D;
-/* 87: */ }
-/* 88: */ else
-/* 89: */ {
-/* 90:78 */ aEntity.motionX *= 1.100000023841858D;
-/* 91:79 */ aEntity.motionZ *= 1.100000023841858D;
-/* 92: */ }
-/* 93: */ }
-/* 94: */ }
-/* 95: */
-/* 96: */ public AxisAlignedBB getCollisionBoundingBoxFromPool(World aWorld, int aX, int aY, int aZ)
-/* 97: */ {
-/* 98:86 */ Block tBlock = aWorld.getBlock(aX, aY + 1, aZ);
-/* 99:87 */ if (((tBlock instanceof IFluidBlock)) || ((tBlock instanceof BlockLiquid))) {
-/* :0:87 */ return super.getCollisionBoundingBoxFromPool(aWorld, aX, aY, aZ);
-/* :1: */ }
-/* :2:88 */ return AxisAlignedBB.getBoundingBox(aX, aY, aZ, aX + 1, aY + 0.875D, aZ + 1);
-/* :3: */ }
-/* :4: */ }
+package gregtech.common.blocks;
+
+import gregtech.api.enums.Materials;
+import gregtech.api.enums.OrePrefixes;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_OreDictUnificator;
+import net.minecraft.block.Block;
+import net.minecraft.block.BlockLiquid;
+import net.minecraft.entity.Entity;
+import net.minecraft.entity.EntityLivingBase;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.AxisAlignedBB;
+import net.minecraft.util.IIcon;
+import net.minecraft.world.World;
+import net.minecraftforge.fluids.IFluidBlock;
+
+public class GT_Block_Concretes
+ extends GT_Block_Stones_Abstract
+{
+ public GT_Block_Concretes()
+ {
+ super(GT_Item_Concretes.class, "gt.blockconcretes");
+ setResistance(20.0F);
+ this.slipperiness = 0.9F;
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".0.name", "Dark Concrete");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".1.name", "Dark Concrete Cobblestone");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".2.name", "Mossy Dark Concrete Cobblestone");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".3.name", "Dark Concrete Bricks");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".4.name", "Cracked Dark Concrete Bricks");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".5.name", "Mossy Dark Concrete Bricks");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".6.name", "Chiseled Dark Concrete");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".7.name", "Smooth Dark Concrete");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".8.name", "Light Concrete");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".9.name", "Light Concrete Cobblestone");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".10.name", "Mossy Light Concrete Cobblestone");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".11.name", "Light Concrete Bricks");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".12.name", "Cracked Light Concrete Bricks");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".13.name", "Mossy Light Concrete Bricks");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".14.name", "Chiseled Light Concrete");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".15.name", "Smooth Light Concrete");
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 0));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 1));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 2));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 3));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 4));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 5));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 6));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 7));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 8));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 9));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 10));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 11));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 12));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 13));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 14));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.Concrete, new ItemStack(this, 1, 15));
+ }
+
+ public int getHarvestLevel(int aMeta)
+ {
+ return 1;
+ }
+
+ public float getBlockHardness(World aWorld, int aX, int aY, int aZ)
+ {
+ return this.blockHardness = Blocks.stone.getBlockHardness(aWorld, aX, aY, aZ);
+ }
+
+ public IIcon getIcon(int aSide, int aMeta)
+ {
+ if ((aMeta >= 0) && (aMeta < 16)) {
+ return gregtech.api.enums.Textures.BlockIcons.CONCRETES[aMeta].getIcon();
+ }
+ return gregtech.api.enums.Textures.BlockIcons.CONCRETES[0].getIcon();
+ }
+
+ public void onEntityCollidedWithBlock(World aWorld, int aX, int aY, int aZ, Entity aEntity)
+ {
+ Block tBlock = aWorld.getBlock(aX, aY + 1, aZ);
+ if (((aEntity instanceof EntityLivingBase)) && (!(tBlock instanceof IFluidBlock)) && (!(tBlock instanceof BlockLiquid)) && (aEntity.onGround) && (!aEntity.isInWater()) && (!aEntity.isWet())) {
+ if (aEntity.isSneaking())
+ {
+ aEntity.motionX *= 0.8999999761581421D;
+ aEntity.motionZ *= 0.8999999761581421D;
+ }
+ else
+ {
+ aEntity.motionX *= 1.100000023841858D;
+ aEntity.motionZ *= 1.100000023841858D;
+ }
+ }
+ }
+
+ public AxisAlignedBB getCollisionBoundingBoxFromPool(World aWorld, int aX, int aY, int aZ)
+ {
+ Block tBlock = aWorld.getBlock(aX, aY + 1, aZ);
+ if (((tBlock instanceof IFluidBlock)) || ((tBlock instanceof BlockLiquid))) {
+ return super.getCollisionBoundingBoxFromPool(aWorld, aX, aY, aZ);
+ }
+ return AxisAlignedBB.getBoundingBox(aX, aY, aZ, aX + 1, aY + 0.875D, aZ + 1);
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Block_Granites.java b/main/java/gregtech/common/blocks/GT_Block_Granites.java index a952e3631a..379fb0003b 100644 --- a/main/java/gregtech/common/blocks/GT_Block_Granites.java +++ b/main/java/gregtech/common/blocks/GT_Block_Granites.java @@ -1,83 +1,83 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import gregtech.api.enums.Materials;
-/* 4: */ import gregtech.api.enums.OrePrefixes;
-/* 5: */ import gregtech.api.interfaces.IIconContainer;
-/* 6: */ import gregtech.api.util.GT_LanguageManager;
-/* 7: */ import gregtech.api.util.GT_OreDictUnificator;
-/* 8: */ import net.minecraft.block.Block;
-/* 9: */ import net.minecraft.entity.Entity;
-/* 10: */ import net.minecraft.entity.boss.EntityWither;
-/* 11: */ import net.minecraft.init.Blocks;
-/* 12: */ import net.minecraft.item.ItemStack;
-/* 13: */ import net.minecraft.util.IIcon;
-/* 14: */ import net.minecraft.world.IBlockAccess;
-/* 15: */ import net.minecraft.world.World;
-/* 16: */
-/* 17: */ public class GT_Block_Granites
-/* 18: */ extends GT_Block_Stones_Abstract
-/* 19: */ {
-/* 20: */ public GT_Block_Granites()
-/* 21: */ {
-/* 22:18 */ super(GT_Item_Granites.class, "gt.blockgranites");
-/* 23:19 */ setResistance(60.0F);
-/* 24:20 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".0.name", "Black Granite");
-/* 25:21 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".1.name", "Black Granite Cobblestone");
-/* 26:22 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".2.name", "Mossy Black Granite Cobblestone");
-/* 27:23 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".3.name", "Black Granite Bricks");
-/* 28:24 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".4.name", "Cracked Black Granite Bricks");
-/* 29:25 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".5.name", "Mossy Black Granite Bricks");
-/* 30:26 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".6.name", "Chiseled Black Granite");
-/* 31:27 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".7.name", "Smooth Black Granite");
-/* 32:28 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".8.name", "Red Granite");
-/* 33:29 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".9.name", "Red Granite Cobblestone");
-/* 34:30 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".10.name", "Mossy Red Granite Cobblestone");
-/* 35:31 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".11.name", "Red Granite Bricks");
-/* 36:32 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".12.name", "Cracked Red Granite Bricks");
-/* 37:33 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".13.name", "Mossy Red Granite Bricks");
-/* 38:34 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".14.name", "Chiseled Red Granite");
-/* 39:35 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".15.name", "Smooth Red Granite");
-/* 40:36 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 0));
-/* 41:37 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 1));
-/* 42:38 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 2));
-/* 43:39 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 3));
-/* 44:40 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 4));
-/* 45:41 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 5));
-/* 46:42 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 6));
-/* 47:43 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 7));
-/* 48:44 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 8));
-/* 49:45 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 9));
-/* 50:46 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 10));
-/* 51:47 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 11));
-/* 52:48 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 12));
-/* 53:49 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 13));
-/* 54:50 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 14));
-/* 55:51 */ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 15));
-/* 56: */ }
-/* 57: */
-/* 58: */ public int getHarvestLevel(int aMeta)
-/* 59: */ {
-/* 60:56 */ return 3;
-/* 61: */ }
-/* 62: */
-/* 63: */ public float getBlockHardness(World aWorld, int aX, int aY, int aZ)
-/* 64: */ {
-/* 65:61 */ return this.blockHardness = Blocks.stone.getBlockHardness(aWorld, aX, aY, aZ) * 3.0F;
-/* 66: */ }
-/* 67: */
-/* 68: */ public IIcon getIcon(int aSide, int aMeta)
-/* 69: */ {
-/* 70:64 */ if ((aMeta >= 0) && (aMeta < 16)) {
-/* 71:64 */ return gregtech.api.enums.Textures.BlockIcons.GRANITES[aMeta].getIcon();
-/* 72: */ }
-/* 73:64 */ return gregtech.api.enums.Textures.BlockIcons.GRANITES[0].getIcon();
-/* 74: */ }
-/* 75: */
-/* 76: */ public boolean canEntityDestroy(IBlockAccess world, int x, int y, int z, Entity entity)
-/* 77: */ {
-/* 78:68 */ return !(entity instanceof EntityWither);
-/* 79: */ }
-/* 80: */ }
+package gregtech.common.blocks;
+
+import gregtech.api.enums.Materials;
+import gregtech.api.enums.OrePrefixes;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_OreDictUnificator;
+import net.minecraft.block.Block;
+import net.minecraft.entity.Entity;
+import net.minecraft.entity.boss.EntityWither;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.IIcon;
+import net.minecraft.world.IBlockAccess;
+import net.minecraft.world.World;
+
+public class GT_Block_Granites
+ extends GT_Block_Stones_Abstract
+{
+ public GT_Block_Granites()
+ {
+ super(GT_Item_Granites.class, "gt.blockgranites");
+ setResistance(60.0F);
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".0.name", "Black Granite");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".1.name", "Black Granite Cobblestone");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".2.name", "Mossy Black Granite Cobblestone");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".3.name", "Black Granite Bricks");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".4.name", "Cracked Black Granite Bricks");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".5.name", "Mossy Black Granite Bricks");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".6.name", "Chiseled Black Granite");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".7.name", "Smooth Black Granite");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".8.name", "Red Granite");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".9.name", "Red Granite Cobblestone");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".10.name", "Mossy Red Granite Cobblestone");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".11.name", "Red Granite Bricks");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".12.name", "Cracked Red Granite Bricks");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".13.name", "Mossy Red Granite Bricks");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".14.name", "Chiseled Red Granite");
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".15.name", "Smooth Red Granite");
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 0));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 1));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 2));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 3));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 4));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 5));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 6));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteBlack, new ItemStack(this, 1, 7));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 8));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 9));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 10));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 11));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 12));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 13));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 14));
+ GT_OreDictUnificator.registerOre(OrePrefixes.stone, Materials.GraniteRed, new ItemStack(this, 1, 15));
+ }
+
+ public int getHarvestLevel(int aMeta)
+ {
+ return 3;
+ }
+
+ public float getBlockHardness(World aWorld, int aX, int aY, int aZ)
+ {
+ return this.blockHardness = Blocks.stone.getBlockHardness(aWorld, aX, aY, aZ) * 3.0F;
+ }
+
+ public IIcon getIcon(int aSide, int aMeta)
+ {
+ if ((aMeta >= 0) && (aMeta < 16)) {
+ return gregtech.api.enums.Textures.BlockIcons.GRANITES[aMeta].getIcon();
+ }
+ return gregtech.api.enums.Textures.BlockIcons.GRANITES[0].getIcon();
+ }
+
+ public boolean canEntityDestroy(IBlockAccess world, int x, int y, int z, Entity entity)
+ {
+ return !(entity instanceof EntityWither);
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Block_Machines.java b/main/java/gregtech/common/blocks/GT_Block_Machines.java index d4bf198851..3943331295 100644 --- a/main/java/gregtech/common/blocks/GT_Block_Machines.java +++ b/main/java/gregtech/common/blocks/GT_Block_Machines.java @@ -1,577 +1,577 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import cpw.mods.fml.relauncher.Side;
-/* 4: */ import cpw.mods.fml.relauncher.SideOnly;
-/* 5: */ import gregtech.api.GregTech_API;
+package gregtech.common.blocks;
+
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.GregTech_API;
import gregtech.api.enums.Textures;
-/* 6: */ import gregtech.api.enums.Textures.BlockIcons;
-/* 7: */ import gregtech.api.interfaces.IDebugableBlock;
-/* 8: */ import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
-/* 9: */ import gregtech.api.interfaces.tileentity.ICoverable;
-/* 10: */ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-/* 11: */ import gregtech.api.items.GT_Generic_Block;
-/* 12: */ import gregtech.api.metatileentity.BaseMetaPipeEntity;
-/* 13: */ import gregtech.api.metatileentity.BaseMetaTileEntity;
-/* 14: */ import gregtech.api.metatileentity.BaseTileEntity;
-/* 15: */ import gregtech.api.util.GT_BaseCrop;
-/* 16: */ import gregtech.api.util.GT_Log;
-/* 17: */ import gregtech.api.util.GT_Utility;
-/* 18: */ import gregtech.common.render.GT_Renderer_Block;
+import gregtech.api.enums.Textures.BlockIcons;
+import gregtech.api.interfaces.IDebugableBlock;
+import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
+import gregtech.api.interfaces.tileentity.ICoverable;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.items.GT_Generic_Block;
+import gregtech.api.metatileentity.BaseMetaPipeEntity;
+import gregtech.api.metatileentity.BaseMetaTileEntity;
+import gregtech.api.metatileentity.BaseTileEntity;
+import gregtech.api.util.GT_BaseCrop;
+import gregtech.api.util.GT_Log;
+import gregtech.api.util.GT_Utility;
+import gregtech.common.render.GT_Renderer_Block;
+
+import java.io.PrintStream;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Random;
-/* 19: */ import java.io.PrintStream;
-/* 20: */ import java.util.ArrayList;
-/* 21: */ import java.util.List;
-/* 22: */ import java.util.Random;
+import net.minecraft.block.Block;
+import net.minecraft.block.ITileEntityProvider;
+import net.minecraft.client.renderer.texture.IIconRegister;
+import net.minecraft.creativetab.CreativeTabs;
+import net.minecraft.entity.Entity;
+import net.minecraft.entity.EntityLivingBase;
+import net.minecraft.entity.EnumCreatureType;
+import net.minecraft.entity.item.EntityItem;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.Item;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.util.AxisAlignedBB;
+import net.minecraft.util.IIcon;
+import net.minecraft.util.MathHelper;
+import net.minecraft.util.StatCollector;
+import net.minecraft.world.Explosion;
+import net.minecraft.world.IBlockAccess;
+import net.minecraft.world.World;
+import net.minecraftforge.common.util.ForgeDirection;
-/* 23: */ import net.minecraft.block.Block;
-/* 24: */ import net.minecraft.block.ITileEntityProvider;
-/* 25: */ import net.minecraft.client.renderer.texture.IIconRegister;
-/* 26: */ import net.minecraft.creativetab.CreativeTabs;
-/* 27: */ import net.minecraft.entity.Entity;
-/* 28: */ import net.minecraft.entity.EntityLivingBase;
-/* 29: */ import net.minecraft.entity.EnumCreatureType;
-/* 30: */ import net.minecraft.entity.item.EntityItem;
-/* 31: */ import net.minecraft.entity.player.EntityPlayer;
-/* 32: */ import net.minecraft.item.Item;
-/* 33: */ import net.minecraft.item.ItemStack;
-/* 34: */ import net.minecraft.nbt.NBTTagCompound;
-/* 35: */ import net.minecraft.tileentity.TileEntity;
-/* 36: */ import net.minecraft.util.AxisAlignedBB;
-/* 37: */ import net.minecraft.util.IIcon;
-/* 38: */ import net.minecraft.util.MathHelper;
-/* 39: */ import net.minecraft.util.StatCollector;
-/* 40: */ import net.minecraft.world.Explosion;
-/* 41: */ import net.minecraft.world.IBlockAccess;
-/* 42: */ import net.minecraft.world.World;
-/* 43: */ import net.minecraftforge.common.util.ForgeDirection;
-/* 44: */
-/* 45: */ public class GT_Block_Machines
-/* 46: */ extends GT_Generic_Block
-/* 47: */ implements IDebugableBlock, ITileEntityProvider
-/* 48: */ {
-/* 49: 47 */ public static ThreadLocal<IGregTechTileEntity> mTemporaryTileEntity = new ThreadLocal();
-/* 50: */
-/* 51: */ public GT_Block_Machines()
-/* 52: */ {
-/* 53: 50 */ super(GT_Item_Machines.class, "gt.blockmachines", new GT_Material_Machines());
-/* 54: 51 */ GregTech_API.registerMachineBlock(this, -1);
-/* 55: 52 */ setHardness(1.0F);
-/* 56: 53 */ setResistance(10.0F);
-/* 57: 54 */ setStepSound(soundTypeMetal);
-/* 58: 55 */ setCreativeTab(GregTech_API.TAB_GREGTECH);
-/* 59: 56 */ this.isBlockContainer = true;
-/* 60: */ }
-/* 61: */
-/* 62: */ public String getHarvestTool(int aMeta)
-/* 63: */ {
-/* 64: 61 */ switch (aMeta / 4)
-/* 65: */ {
-/* 66: */ case 0:
-/* 67: 62 */ return "wrench";
-/* 68: */ case 1:
-/* 69: 63 */ return "wrench";
-/* 70: */ case 2:
-/* 71: 64 */ return "cutter";
-/* 72: */ case 3:
-/* 73: 65 */ return "axe";
-/* 74: */ }
-/* 75: 66 */ return "wrench";
-/* 76: */ }
-/* 77: */
-/* 78: */ public int getHarvestLevel(int aMeta)
-/* 79: */ {
-/* 80: 72 */ return aMeta % 4;
-/* 81: */ }
-/* 82: */
-/* 83: */ protected boolean canSilkHarvest()
-/* 84: */ {
-/* 85: 77 */ return false;
-/* 86: */ }
-/* 87: */
-/* 88: */ public void onNeighborChange(IBlockAccess aWorld, int aX, int aY, int aZ, int aTileX, int aTileY, int aTileZ)
-/* 89: */ {
-/* 90: 80 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 91: 80 */ if ((tTileEntity instanceof BaseTileEntity)) {
-/* 92: 80 */ ((BaseTileEntity)tTileEntity).onAdjacentBlockChange(aTileX, aTileY, aTileZ);
-/* 93: */ }
-/* 94: */ }
-/* 95: */
-/* 96: */ public void onBlockAdded(World aWorld, int aX, int aY, int aZ)
-/* 97: */ {
-/* 98: 81 */ super.onBlockAdded(aWorld, aX, aY, aZ);
-/* 99: 81 */ if (GregTech_API.isMachineBlock(this, aWorld.getBlockMetadata(aX, aY, aZ))) {
-/* 100: 81 */ GregTech_API.causeMachineUpdate(aWorld, aX, aY, aZ);
-/* 101: */ }
-/* 102: */ }
-/* 103: */
-/* 104: */ public String getUnlocalizedName()
-/* 105: */ {
-/* 106: 82 */ return "gt.blockmachines";
-/* 107: */ }
-/* 108: */
-/* 109: */ public String getLocalizedName()
-/* 110: */ {
-/* 111: 83 */ return StatCollector.translateToLocal(getUnlocalizedName() + ".name");
-/* 112: */ }
-/* 113: */
-/* 114: */ public int getFlammability(IBlockAccess aWorld, int aX, int aY, int aZ, ForgeDirection face)
-/* 115: */ {
-/* 116: 84 */ return 0;
-/* 117: */ }
-/* 118: */
-/* 119: */ public int getFireSpreadSpeed(IBlockAccess aWorld, int aX, int aY, int aZ, ForgeDirection face)
-/* 120: */ {
-/* 121: 85 */ return (GregTech_API.sMachineFlammable) && (aWorld.getBlockMetadata(aX, aY, aZ) == 0) ? 100 : 0;
-/* 122: */ }
-/* 123: */
-/* 124: */ public int getRenderType()
-/* 125: */ {
-/* 126: 86 */ if (GT_Renderer_Block.INSTANCE == null) {
-/* 127: 86 */ return super.getRenderType();
-/* 128: */ }
-/* 129: 86 */ return GT_Renderer_Block.INSTANCE.mRenderID;
-/* 130: */ }
-/* 131: */
-/* 132: */ public boolean isFireSource(World aWorld, int aX, int aY, int aZ, ForgeDirection side)
-/* 133: */ {
-/* 134: 87 */ return (GregTech_API.sMachineFlammable) && (aWorld.getBlockMetadata(aX, aY, aZ) == 0);
-/* 135: */ }
-/* 136: */
-/* 137: */ public boolean isFlammable(IBlockAccess aWorld, int aX, int aY, int aZ, ForgeDirection face)
-/* 138: */ {
-/* 139: 88 */ return (GregTech_API.sMachineFlammable) && (aWorld.getBlockMetadata(aX, aY, aZ) == 0);
-/* 140: */ }
-/* 141: */
-/* 142: */ public boolean canCreatureSpawn(EnumCreatureType type, IBlockAccess aWorld, int aX, int aY, int aZ)
-/* 143: */ {
-/* 144: 89 */ return false;
-/* 145: */ }
-/* 146: */
-/* 147: */ public boolean canConnectRedstone(IBlockAccess var1, int var2, int var3, int var4, int var5)
-/* 148: */ {
-/* 149: 90 */ return true;
-/* 150: */ }
-/* 151: */
-/* 152: */ public boolean canBeReplacedByLeaves(IBlockAccess aWorld, int aX, int aY, int aZ)
-/* 153: */ {
-/* 154: 91 */ return false;
-/* 155: */ }
-/* 156: */
-/* 157: */ public boolean isNormalCube(IBlockAccess aWorld, int aX, int aY, int aZ)
-/* 158: */ {
-/* 159: 92 */ return false;
-/* 160: */ }
-/* 161: */
-/* 162: */ public boolean hasTileEntity(int aMeta)
-/* 163: */ {
-/* 164: 93 */ return true;
-/* 165: */ }
-/* 166: */
-/* 167: */ public boolean hasComparatorInputOverride()
-/* 168: */ {
-/* 169: 94 */ return true;
-/* 170: */ }
-/* 171: */
-/* 172: */ public boolean renderAsNormalBlock()
-/* 173: */ {
-/* 174: 95 */ return false;
-/* 175: */ }
-/* 176: */
-/* 177: */ public boolean canProvidePower()
-/* 178: */ {
-/* 179: 96 */ return true;
-/* 180: */ }
-/* 181: */
-/* 182: */ public boolean isOpaqueCube()
-/* 183: */ {
-/* 184: 97 */ return false;
-/* 185: */ }
-/* 186: */
-/* 187: */ public TileEntity createNewTileEntity(World aWorld, int aMeta)
-/* 188: */ {
-/* 189: 98 */ return createTileEntity(aWorld, aMeta);
-/* 190: */ }
-/* 191: */
-/* 192: */ public IIcon getIcon(IBlockAccess aIBlockAccess, int aX, int aY, int aZ, int aSide)
-/* 193: */ {
-/* 194: 99 */ return Textures.BlockIcons.MACHINE_LV_SIDE.getIcon();
-/* 195: */ }
-/* 196: */
-/* 197: */ public IIcon getIcon(int aSide, int aMeta)
-/* 198: */ {
-/* 199:100 */ return Textures.BlockIcons.MACHINE_LV_SIDE.getIcon();
-/* 200: */ }
-/* 201: */
-/* 202: */ public boolean onBlockEventReceived(World aWorld, int aX, int aY, int aZ, int aData1, int aData2)
-/* 203: */ {
-/* 204:104 */ super.onBlockEventReceived(aWorld, aX, aY, aZ, aData1, aData2);
-/* 205:105 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 206:106 */ return tTileEntity != null ? tTileEntity.receiveClientEvent(aData1, aData2) : false;
-/* 207: */ }
-/* 208: */
-/* 209: */ public void addCollisionBoxesToList(World aWorld, int aX, int aY, int aZ, AxisAlignedBB inputAABB, List outputAABB, Entity collider)
-/* 210: */ {
-/* 211:111 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 212:112 */ if (((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity)tTileEntity).getMetaTileEntity() != null))
-/* 213: */ {
-/* 214:113 */ ((IGregTechTileEntity)tTileEntity).addCollisionBoxesToList(aWorld, aX, aY, aZ, inputAABB, outputAABB, collider);
-/* 215:114 */ return;
-/* 216: */ }
-/* 217:116 */ super.addCollisionBoxesToList(aWorld, aX, aY, aZ, inputAABB, outputAABB, collider);
-/* 218: */ }
-/* 219: */
-/* 220: */ public AxisAlignedBB getCollisionBoundingBoxFromPool(World aWorld, int aX, int aY, int aZ)
-/* 221: */ {
-/* 222:121 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 223:122 */ if (((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity)tTileEntity).getMetaTileEntity() != null)) {
-/* 224:123 */ return ((IGregTechTileEntity)tTileEntity).getCollisionBoundingBoxFromPool(aWorld, aX, aY, aZ);
-/* 225: */ }
-/* 226:125 */ return super.getCollisionBoundingBoxFromPool(aWorld, aX, aY, aZ);
-/* 227: */ }
-/* 228: */
-/* 229: */ public void onEntityCollidedWithBlock(World aWorld, int aX, int aY, int aZ, Entity collider)
-/* 230: */ {
-/* 231:130 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 232:131 */ if (((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity)tTileEntity).getMetaTileEntity() != null))
-/* 233: */ {
-/* 234:132 */ ((IGregTechTileEntity)tTileEntity).onEntityCollidedWithBlock(aWorld, aX, aY, aZ, collider);
-/* 235:133 */ return;
-/* 236: */ }
-/* 237:135 */ super.onEntityCollidedWithBlock(aWorld, aX, aY, aZ, collider);
-/* 238: */ }
-/* 239: */
-/* 240: */ @SideOnly(Side.CLIENT)
-/* 241: */ public void registerBlockIcons(IIconRegister aIconRegister)
-/* 242: */ {
-/* 243:141 */ if (GregTech_API.sPostloadFinished)
-/* 244: */ {
-/* 245:142 */ GT_Log.out.println("GT_Mod: Setting up Icon Register for Blocks");
-/* 246:143 */ GregTech_API.sBlockIcons = aIconRegister;
-/* 247: */
-/* 248:145 */ GT_Log.out.println("GT_Mod: Registering MetaTileEntity specific Textures");
-/* 249:146 */ for (IMetaTileEntity tMetaTileEntity : GregTech_API.METATILEENTITIES) {
-/* 250: */ try
-/* 251: */ {
-/* 252:148 */ if (tMetaTileEntity != null) {
-/* 253:148 */ tMetaTileEntity.registerIcons(aIconRegister);
-/* 254: */ }
-/* 255: */ }
-/* 256: */ catch (Throwable e)
-/* 257: */ {
-/* 258:150 */ e.printStackTrace(GT_Log.err);
-/* 259: */ }
-/* 260: */ }
-/* 261:154 */ GT_Log.out.println("GT_Mod: Registering Crop specific Textures");
-/* 262: */ try
-/* 263: */ {
-/* 264:156 */ for (GT_BaseCrop tCrop : GT_BaseCrop.sCropList) {
-/* 265:157 */ tCrop.registerSprites(aIconRegister);
-/* 266: */ }
-/* 267: */ }
-/* 268: */ catch (Throwable e)
-/* 269: */ {
-/* 270:160 */ e.printStackTrace(GT_Log.err);
-/* 271: */ }
-/* 272:163 */ GT_Log.out.println("GT_Mod: Starting Block Icon Load Phase");
-/* 273:164 */ System.out.println("GT_Mod: Starting Block Icon Load Phase");
-/* 274:165 */ for (Runnable tRunnable : GregTech_API.sGTBlockIconload) {
-/* 275: */ try
-/* 276: */ {
-/* 277:167 */ tRunnable.run();
-/* 278: */ }
-/* 279: */ catch (Throwable e)
-/* 280: */ {
-/* 281:169 */ e.printStackTrace(GT_Log.err);
-/* 282: */ }
-/* 283: */ }
-/* 284:172 */ GT_Log.out.println("GT_Mod: Finished Block Icon Load Phase");
-/* 285:173 */ System.out.println("GT_Mod: Finished Block Icon Load Phase");
-/* 286: */ }
-/* 287: */ }
-/* 288: */
-/* 289: */ public float getBlockHardness(World aWorld, int aX, int aY, int aZ)
-/* 290: */ {
-/* 291:180 */ return super.getBlockHardness(aWorld, aX, aY, aZ);
-/* 292: */ }
-/* 293: */
-/* 294: */ public float getPlayerRelativeBlockHardness(EntityPlayer aPlayer, World aWorld, int aX, int aY, int aZ)
-/* 295: */ {
-/* 296:185 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 297:186 */ if (((tTileEntity instanceof BaseMetaTileEntity)) && (((BaseMetaTileEntity)tTileEntity).privateAccess()) && (!((BaseMetaTileEntity)tTileEntity).playerOwnsThis(aPlayer, true))) {
-/* 298:186 */ return -1.0F;
-/* 299: */ }
-/* 300:187 */ return super.getPlayerRelativeBlockHardness(aPlayer, aWorld, aX, aY, aZ);
-/* 301: */ }
-/* 302: */
-/* 303: */ public boolean onBlockActivated(World aWorld, int aX, int aY, int aZ, EntityPlayer aPlayer, int aSide, float par1, float par2, float par3)
-/* 304: */ {
-/* 305:192 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 306:194 */ if ((tTileEntity == null) || (aPlayer.isSneaking())) {
-/* 307:194 */ return false;
-/* 308: */ }
-/* 309:196 */ if ((tTileEntity instanceof IGregTechTileEntity))
-/* 310: */ {
-/* 311:197 */ if (((IGregTechTileEntity)tTileEntity).getTimer() < 50L) {
-/* 312:197 */ return false;
-/* 313: */ }
-/* 314:198 */ if ((!aWorld.isRemote) && (!((IGregTechTileEntity)tTileEntity).isUseableByPlayer(aPlayer))) {
-/* 315:198 */ return true;
-/* 316: */ }
-/* 317:199 */ return ((IGregTechTileEntity)tTileEntity).onRightclick(aPlayer, (byte)aSide, par1, par2, par3);
-/* 318: */ }
-/* 319:202 */ return false;
-/* 320: */ }
-/* 321: */
-/* 322: */ public void onBlockClicked(World aWorld, int aX, int aY, int aZ, EntityPlayer aPlayer)
-/* 323: */ {
-/* 324:207 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 325:208 */ if ((tTileEntity != null) &&
-/* 326:209 */ ((tTileEntity instanceof IGregTechTileEntity))) {
-/* 327:210 */ ((IGregTechTileEntity)tTileEntity).onLeftclick(aPlayer);
-/* 328: */ }
-/* 329: */ }
-/* 330: */
-/* 331: */ public int getDamageValue(World aWorld, int aX, int aY, int aZ)
-/* 332: */ {
-/* 333:217 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 334:218 */ if ((tTileEntity instanceof IGregTechTileEntity)) {
-/* 335:219 */ return ((IGregTechTileEntity)tTileEntity).getMetaTileID();
-/* 336: */ }
-/* 337:221 */ return 0;
-/* 338: */ }
-/* 339: */
-/* 340: */ public void onBlockExploded(World aWorld, int aX, int aY, int aZ, Explosion aExplosion)
-/* 341: */ {
-/* 342:226 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 343:227 */ if ((tTileEntity instanceof BaseMetaTileEntity)) {
-/* 344:227 */ ((BaseMetaTileEntity)tTileEntity).doEnergyExplosion();
-/* 345: */ }
-/* 346:228 */ super.onBlockExploded(aWorld, aX, aY, aZ, aExplosion);
-/* 347: */ }
-/* 348: */
-/* 349: */ public void breakBlock(World aWorld, int aX, int aY, int aZ, Block par5, int par6)
-/* 350: */ {
-/* 351:233 */ GregTech_API.causeMachineUpdate(aWorld, aX, aY, aZ);
-/* 352:234 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 353:235 */ if ((tTileEntity instanceof IGregTechTileEntity))
-/* 354: */ {
-/* 355:236 */ IGregTechTileEntity tGregTechTileEntity = (IGregTechTileEntity)tTileEntity;
-/* 356:237 */ Random tRandom = new Random();
-/* 357:238 */ mTemporaryTileEntity.set(tGregTechTileEntity);
-/* 358:239 */ for (int i = 0; i < tGregTechTileEntity.getSizeInventory(); i++)
-/* 359: */ {
-/* 360:240 */ ItemStack tItem = tGregTechTileEntity.getStackInSlot(i);
-/* 361:241 */ if ((tItem != null) && (tItem.stackSize > 0) && (tGregTechTileEntity.isValidSlot(i)))
-/* 362: */ {
-/* 363:242 */ EntityItem tItemEntity = new EntityItem(aWorld, aX + tRandom.nextFloat() * 0.8F + 0.1F, aY + tRandom.nextFloat() * 0.8F + 0.1F, aZ + tRandom.nextFloat() * 0.8F + 0.1F, new ItemStack(tItem.getItem(), tItem.stackSize, tItem.getItemDamage()));
-/* 364:243 */ if (tItem.hasTagCompound()) {
-/* 365:243 */ tItemEntity.getEntityItem().setTagCompound((NBTTagCompound)tItem.getTagCompound().copy());
-/* 366: */ }
-/* 367:244 */ tItemEntity.motionX = (tRandom.nextGaussian() * 0.0500000007450581D);
-/* 368:245 */ tItemEntity.motionY = (tRandom.nextGaussian() * 0.0500000007450581D + 0.2000000029802322D);
-/* 369:246 */ tItemEntity.motionZ = (tRandom.nextGaussian() * 0.0500000007450581D);
-/* 370:247 */ aWorld.spawnEntityInWorld(tItemEntity);
-/* 371:248 */ tItem.stackSize = 0;
-/* 372:249 */ tGregTechTileEntity.setInventorySlotContents(i, null);
-/* 373: */ }
-/* 374: */ }
-/* 375: */ }
-/* 376:253 */ super.breakBlock(aWorld, aX, aY, aZ, par5, par6);
-/* 377:254 */ aWorld.removeTileEntity(aX, aY, aZ);
-/* 378: */ }
-/* 379: */
-/* 380: */ public ArrayList<ItemStack> getDrops(World aWorld, int aX, int aY, int aZ, int aMeta, int aFortune)
-/* 381: */ {
-/* 382:259 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 383:260 */ if ((tTileEntity instanceof IGregTechTileEntity)) {
-/* 384:260 */ return ((IGregTechTileEntity)tTileEntity).getDrops();
-/* 385: */ }
-/* 386:261 */ return mTemporaryTileEntity.get() == null ? new ArrayList() : ((IGregTechTileEntity)mTemporaryTileEntity.get()).getDrops();
-/* 387: */ }
-/* 388: */
-/* 389: */ public int getComparatorInputOverride(World aWorld, int aX, int aY, int aZ, int aSide)
-/* 390: */ {
-/* 391:266 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 392:267 */ if ((tTileEntity != null) && ((tTileEntity instanceof IGregTechTileEntity))) {
-/* 393:267 */ return ((IGregTechTileEntity)tTileEntity).getComparatorValue((byte)aSide);
-/* 394: */ }
-/* 395:268 */ return 0;
-/* 396: */ }
-/* 397: */
-/* 398: */ public int isProvidingWeakPower(IBlockAccess aWorld, int aX, int aY, int aZ, int aSide)
-/* 399: */ {
-/* 400:273 */ if ((aSide < 0) || (aSide > 5)) {
-/* 401:273 */ return 0;
-/* 402: */ }
-/* 403:275 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 404:277 */ if ((tTileEntity != null) && ((tTileEntity instanceof IGregTechTileEntity))) {
-/* 405:277 */ return ((IGregTechTileEntity)tTileEntity).getOutputRedstoneSignal(GT_Utility.getOppositeSide(aSide));
-/* 406: */ }
-/* 407:279 */ return 0;
-/* 408: */ }
-/* 409: */
-/* 410: */ public int isProvidingStrongPower(IBlockAccess aWorld, int aX, int aY, int aZ, int aSide)
-/* 411: */ {
-/* 412:284 */ if ((aSide < 0) || (aSide > 5)) {
-/* 413:284 */ return 0;
-/* 414: */ }
-/* 415:286 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 416:288 */ if ((tTileEntity != null) && ((tTileEntity instanceof IGregTechTileEntity))) {
-/* 417:288 */ return ((IGregTechTileEntity)tTileEntity).getStrongOutputRedstoneSignal(GT_Utility.getOppositeSide(aSide));
-/* 418: */ }
-/* 419:290 */ return 0;
-/* 420: */ }
-/* 421: */
-/* 422: */ public void dropBlockAsItemWithChance(World aWorld, int aX, int aY, int aZ, int par5, float chance, int par7)
-/* 423: */ {
-/* 424:295 */ if (!aWorld.isRemote)
-/* 425: */ {
-/* 426:296 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 427:298 */ if ((tTileEntity != null) && (chance < 1.0F))
-/* 428: */ {
-/* 429:299 */ if (((tTileEntity instanceof BaseMetaTileEntity)) && (GregTech_API.sMachineNonWrenchExplosions)) {
-/* 430:299 */ ((BaseMetaTileEntity)tTileEntity).doEnergyExplosion();
-/* 431: */ }
-/* 432: */ }
-/* 433: */ else {
-/* 434:301 */ super.dropBlockAsItemWithChance(aWorld, aX, aY, aZ, par5, chance, par7);
-/* 435: */ }
-/* 436: */ }
-/* 437: */ }
-/* 438: */
-/* 439: */ public boolean isSideSolid(IBlockAccess aWorld, int aX, int aY, int aZ, ForgeDirection aSide)
-/* 440: */ {
-/* 441:313 */ if (aWorld.getBlockMetadata(aX, aY, aZ) == 0) {
-/* 442:313 */ return true;
-/* 443: */ }
-/* 444:314 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 445:315 */ if (tTileEntity != null)
-/* 446: */ {
-/* 447:316 */ if ((tTileEntity instanceof BaseMetaTileEntity)) {
-/* 448:316 */ return true;
-/* 449: */ }
-/* 450:317 */ if (((tTileEntity instanceof BaseMetaPipeEntity)) && ((((BaseMetaPipeEntity)tTileEntity).mConnections & 0xFFFFFFC0) != 0)) {
-/* 451:317 */ return true;
-/* 452: */ }
-/* 453:318 */ if (((tTileEntity instanceof ICoverable)) && (((ICoverable)tTileEntity).getCoverIDAtSide((byte)aSide.ordinal()) != 0)) {
-/* 454:318 */ return true;
-/* 455: */ }
-/* 456: */ }
-/* 457:320 */ return false;
-/* 458: */ }
-/* 459: */
-/* 460: */ public int getLightOpacity(IBlockAccess aWorld, int aX, int aY, int aZ)
-/* 461: */ {
-/* 462:325 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 463:326 */ if (tTileEntity == null) {
-/* 464:326 */ return 0;
-/* 465: */ }
-/* 466:327 */ if ((tTileEntity instanceof IGregTechTileEntity)) {
-/* 467:327 */ return ((IGregTechTileEntity)tTileEntity).getLightOpacity();
-/* 468: */ }
-/* 469:328 */ return aWorld.getBlockMetadata(aX, aY, aZ) == 0 ? 255 : 0;
-/* 470: */ }
-/* 471: */
-/* 472: */ public int getLightValue(IBlockAccess aWorld, int aX, int aY, int aZ)
-/* 473: */ {
-/* 474:333 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 475:334 */ if ((tTileEntity instanceof BaseMetaTileEntity)) {
-/* 476:334 */ return ((BaseMetaTileEntity)tTileEntity).getLightValue();
-/* 477: */ }
-/* 478:335 */ return 0;
-/* 479: */ }
-/* 480: */
-/* 481: */ public TileEntity createTileEntity(World aWorld, int aMeta)
-/* 482: */ {
-/* 483:340 */ if (aMeta < 4) {
-/* 484:340 */ return GregTech_API.constructBaseMetaTileEntity();
-/* 485: */ }
-/* 486:341 */ return new BaseMetaPipeEntity();
-/* 487: */ }
-/* 488: */
-/* 489: */ public float getExplosionResistance(Entity par1Entity, World aWorld, int aX, int aY, int aZ, double explosionX, double explosionY, double explosionZ)
-/* 490: */ {
-/* 491:346 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 492:347 */ if ((tTileEntity != null) && ((tTileEntity instanceof IGregTechTileEntity))) {
-/* 493:347 */ return ((IGregTechTileEntity)tTileEntity).getBlastResistance((byte)6);
-/* 494: */ }
-/* 495:348 */ return 10.0F;
-/* 496: */ }
-/* 497: */
-/* 498: */ @SideOnly(Side.CLIENT)
-/* 499: */ public void getSubBlocks(Item par1, CreativeTabs par2CreativeTabs, List par3List)
-/* 500: */ {
-/* 501:353 */ for (int i = 1; i < GregTech_API.METATILEENTITIES.length; i++) {
-/* 502:353 */ if (GregTech_API.METATILEENTITIES[i] != null) {
-/* 503:353 */ par3List.add(new ItemStack(par1, 1, i));
-/* 504: */ }
-/* 505: */ }
-/* 506: */ }
-/* 507: */
-/* 508: */ public void onBlockPlacedBy(World aWorld, int aX, int aY, int aZ, EntityLivingBase aPlayer, ItemStack aStack)
-/* 509: */ {
-/* 510:358 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 511:359 */ if (tTileEntity == null) {
-/* 512:359 */ return;
-/* 513: */ }
-/* 514:360 */ if ((tTileEntity instanceof IGregTechTileEntity))
-/* 515: */ {
-/* 516:361 */ IGregTechTileEntity var6 = (IGregTechTileEntity)tTileEntity;
-/* 517:362 */ if (aPlayer == null)
-/* 518: */ {
-/* 519:363 */ var6.setFrontFacing((byte)1);
-/* 520: */ }
-/* 521: */ else
-/* 522: */ {
-/* 523:365 */ int var7 = MathHelper.floor_double(aPlayer.rotationYaw * 4.0F / 360.0F + 0.5D) & 0x3;
-/* 524:366 */ int var8 = Math.round(aPlayer.rotationPitch);
-/* 525:367 */ if ((var8 >= 65) && (var6.isValidFacing((byte)1))) {
-/* 526:368 */ var6.setFrontFacing((byte)1);
-/* 527:369 */ } else if ((var8 <= -65) && (var6.isValidFacing((byte)0))) {
-/* 528:370 */ var6.setFrontFacing((byte)0);
-/* 529: */ } else {
-/* 530:372 */ switch (var7)
-/* 531: */ {
-/* 532: */ case 0:
-/* 533:373 */ var6.setFrontFacing((byte)2); break;
-/* 534: */ case 1:
-/* 535:374 */ var6.setFrontFacing((byte)5); break;
-/* 536: */ case 2:
-/* 537:375 */ var6.setFrontFacing((byte)3); break;
-/* 538: */ case 3:
-/* 539:376 */ var6.setFrontFacing((byte)4);
-/* 540: */ }
-/* 541: */ }
-/* 542: */ }
-/* 543: */ }
-/* 544: */ }
-/* 545: */
-/* 546: */ public ArrayList<String> getDebugInfo(EntityPlayer aPlayer, int aX, int aY, int aZ, int aLogLevel)
-/* 547: */ {
-/* 548:385 */ TileEntity tTileEntity = aPlayer.worldObj.getTileEntity(aX, aY, aZ);
-/* 549:386 */ if ((tTileEntity instanceof BaseMetaTileEntity)) {
-/* 550:386 */ return ((BaseMetaTileEntity)tTileEntity).getDebugInfo(aPlayer, aLogLevel);
-/* 551: */ }
-/* 552:387 */ if ((tTileEntity instanceof BaseMetaPipeEntity)) {
-/* 553:387 */ return ((BaseMetaPipeEntity)tTileEntity).getDebugInfo(aPlayer, aLogLevel);
-/* 554: */ }
-/* 555:388 */ return null;
-/* 556: */ }
-/* 557: */
-/* 558: */ public boolean recolourBlock(World aWorld, int aX, int aY, int aZ, ForgeDirection aSide, int aColor)
-/* 559: */ {
-/* 560:393 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 561:394 */ if ((tTileEntity instanceof IGregTechTileEntity))
-/* 562: */ {
-/* 563:395 */ if (((IGregTechTileEntity)tTileEntity).getColorization() == (byte)((aColor ^ 0xFFFFFFFF) & 0xF)) {
-/* 564:395 */ return false;
-/* 565: */ }
-/* 566:396 */ ((IGregTechTileEntity)tTileEntity).setColorization((byte)((aColor ^ 0xFFFFFFFF) & 0xF));
-/* 567:397 */ return true;
-/* 568: */ }
-/* 569:399 */ return false;
-/* 570: */ }
-/* 571: */ }
+public class GT_Block_Machines
+ extends GT_Generic_Block
+ implements IDebugableBlock, ITileEntityProvider
+{
+ public static ThreadLocal<IGregTechTileEntity> mTemporaryTileEntity = new ThreadLocal();
+
+ public GT_Block_Machines()
+ {
+ super(GT_Item_Machines.class, "gt.blockmachines", new GT_Material_Machines());
+ GregTech_API.registerMachineBlock(this, -1);
+ setHardness(1.0F);
+ setResistance(10.0F);
+ setStepSound(soundTypeMetal);
+ setCreativeTab(GregTech_API.TAB_GREGTECH);
+ this.isBlockContainer = true;
+ }
+
+ public String getHarvestTool(int aMeta)
+ {
+ switch (aMeta / 4)
+ {
+ case 0:
+ return "wrench";
+ case 1:
+ return "wrench";
+ case 2:
+ return "cutter";
+ case 3:
+ return "axe";
+ }
+ return "wrench";
+ }
+
+ public int getHarvestLevel(int aMeta)
+ {
+ return aMeta % 4;
+ }
+
+ protected boolean canSilkHarvest()
+ {
+ return false;
+ }
+
+ public void onNeighborChange(IBlockAccess aWorld, int aX, int aY, int aZ, int aTileX, int aTileY, int aTileZ)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity instanceof BaseTileEntity)) {
+ ((BaseTileEntity)tTileEntity).onAdjacentBlockChange(aTileX, aTileY, aTileZ);
+ }
+ }
+
+ public void onBlockAdded(World aWorld, int aX, int aY, int aZ)
+ {
+ super.onBlockAdded(aWorld, aX, aY, aZ);
+ if (GregTech_API.isMachineBlock(this, aWorld.getBlockMetadata(aX, aY, aZ))) {
+ GregTech_API.causeMachineUpdate(aWorld, aX, aY, aZ);
+ }
+ }
+
+ public String getUnlocalizedName()
+ {
+ return "gt.blockmachines";
+ }
+
+ public String getLocalizedName()
+ {
+ return StatCollector.translateToLocal(getUnlocalizedName() + ".name");
+ }
+
+ public int getFlammability(IBlockAccess aWorld, int aX, int aY, int aZ, ForgeDirection face)
+ {
+ return 0;
+ }
+
+ public int getFireSpreadSpeed(IBlockAccess aWorld, int aX, int aY, int aZ, ForgeDirection face)
+ {
+ return (GregTech_API.sMachineFlammable) && (aWorld.getBlockMetadata(aX, aY, aZ) == 0) ? 100 : 0;
+ }
+
+ public int getRenderType()
+ {
+ if (GT_Renderer_Block.INSTANCE == null) {
+ return super.getRenderType();
+ }
+ return GT_Renderer_Block.INSTANCE.mRenderID;
+ }
+
+ public boolean isFireSource(World aWorld, int aX, int aY, int aZ, ForgeDirection side)
+ {
+ return (GregTech_API.sMachineFlammable) && (aWorld.getBlockMetadata(aX, aY, aZ) == 0);
+ }
+
+ public boolean isFlammable(IBlockAccess aWorld, int aX, int aY, int aZ, ForgeDirection face)
+ {
+ return (GregTech_API.sMachineFlammable) && (aWorld.getBlockMetadata(aX, aY, aZ) == 0);
+ }
+
+ public boolean canCreatureSpawn(EnumCreatureType type, IBlockAccess aWorld, int aX, int aY, int aZ)
+ {
+ return false;
+ }
+
+ public boolean canConnectRedstone(IBlockAccess var1, int var2, int var3, int var4, int var5)
+ {
+ return true;
+ }
+
+ public boolean canBeReplacedByLeaves(IBlockAccess aWorld, int aX, int aY, int aZ)
+ {
+ return false;
+ }
+
+ public boolean isNormalCube(IBlockAccess aWorld, int aX, int aY, int aZ)
+ {
+ return false;
+ }
+
+ public boolean hasTileEntity(int aMeta)
+ {
+ return true;
+ }
+
+ public boolean hasComparatorInputOverride()
+ {
+ return true;
+ }
+
+ public boolean renderAsNormalBlock()
+ {
+ return false;
+ }
+
+ public boolean canProvidePower()
+ {
+ return true;
+ }
+
+ public boolean isOpaqueCube()
+ {
+ return false;
+ }
+
+ public TileEntity createNewTileEntity(World aWorld, int aMeta)
+ {
+ return createTileEntity(aWorld, aMeta);
+ }
+
+ public IIcon getIcon(IBlockAccess aIBlockAccess, int aX, int aY, int aZ, int aSide)
+ {
+ return Textures.BlockIcons.MACHINE_LV_SIDE.getIcon();
+ }
+
+ public IIcon getIcon(int aSide, int aMeta)
+ {
+ return Textures.BlockIcons.MACHINE_LV_SIDE.getIcon();
+ }
+
+ public boolean onBlockEventReceived(World aWorld, int aX, int aY, int aZ, int aData1, int aData2)
+ {
+ super.onBlockEventReceived(aWorld, aX, aY, aZ, aData1, aData2);
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ return tTileEntity != null ? tTileEntity.receiveClientEvent(aData1, aData2) : false;
+ }
+
+ public void addCollisionBoxesToList(World aWorld, int aX, int aY, int aZ, AxisAlignedBB inputAABB, List outputAABB, Entity collider)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if (((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity)tTileEntity).getMetaTileEntity() != null))
+ {
+ ((IGregTechTileEntity)tTileEntity).addCollisionBoxesToList(aWorld, aX, aY, aZ, inputAABB, outputAABB, collider);
+ return;
+ }
+ super.addCollisionBoxesToList(aWorld, aX, aY, aZ, inputAABB, outputAABB, collider);
+ }
+
+ public AxisAlignedBB getCollisionBoundingBoxFromPool(World aWorld, int aX, int aY, int aZ)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if (((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity)tTileEntity).getMetaTileEntity() != null)) {
+ return ((IGregTechTileEntity)tTileEntity).getCollisionBoundingBoxFromPool(aWorld, aX, aY, aZ);
+ }
+ return super.getCollisionBoundingBoxFromPool(aWorld, aX, aY, aZ);
+ }
+
+ public void onEntityCollidedWithBlock(World aWorld, int aX, int aY, int aZ, Entity collider)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if (((tTileEntity instanceof IGregTechTileEntity)) && (((IGregTechTileEntity)tTileEntity).getMetaTileEntity() != null))
+ {
+ ((IGregTechTileEntity)tTileEntity).onEntityCollidedWithBlock(aWorld, aX, aY, aZ, collider);
+ return;
+ }
+ super.onEntityCollidedWithBlock(aWorld, aX, aY, aZ, collider);
+ }
+
+ @SideOnly(Side.CLIENT)
+ public void registerBlockIcons(IIconRegister aIconRegister)
+ {
+ if (GregTech_API.sPostloadFinished)
+ {
+ GT_Log.out.println("GT_Mod: Setting up Icon Register for Blocks");
+ GregTech_API.sBlockIcons = aIconRegister;
+
+ GT_Log.out.println("GT_Mod: Registering MetaTileEntity specific Textures");
+ for (IMetaTileEntity tMetaTileEntity : GregTech_API.METATILEENTITIES) {
+ try
+ {
+ if (tMetaTileEntity != null) {
+ tMetaTileEntity.registerIcons(aIconRegister);
+ }
+ }
+ catch (Throwable e)
+ {
+ e.printStackTrace(GT_Log.err);
+ }
+ }
+ GT_Log.out.println("GT_Mod: Registering Crop specific Textures");
+ try
+ {
+ for (GT_BaseCrop tCrop : GT_BaseCrop.sCropList) {
+ tCrop.registerSprites(aIconRegister);
+ }
+ }
+ catch (Throwable e)
+ {
+ e.printStackTrace(GT_Log.err);
+ }
+ GT_Log.out.println("GT_Mod: Starting Block Icon Load Phase");
+ System.out.println("GT_Mod: Starting Block Icon Load Phase");
+ for (Runnable tRunnable : GregTech_API.sGTBlockIconload) {
+ try
+ {
+ tRunnable.run();
+ }
+ catch (Throwable e)
+ {
+ e.printStackTrace(GT_Log.err);
+ }
+ }
+ GT_Log.out.println("GT_Mod: Finished Block Icon Load Phase");
+ System.out.println("GT_Mod: Finished Block Icon Load Phase");
+ }
+ }
+
+ public float getBlockHardness(World aWorld, int aX, int aY, int aZ)
+ {
+ return super.getBlockHardness(aWorld, aX, aY, aZ);
+ }
+
+ public float getPlayerRelativeBlockHardness(EntityPlayer aPlayer, World aWorld, int aX, int aY, int aZ)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if (((tTileEntity instanceof BaseMetaTileEntity)) && (((BaseMetaTileEntity)tTileEntity).privateAccess()) && (!((BaseMetaTileEntity)tTileEntity).playerOwnsThis(aPlayer, true))) {
+ return -1.0F;
+ }
+ return super.getPlayerRelativeBlockHardness(aPlayer, aWorld, aX, aY, aZ);
+ }
+
+ public boolean onBlockActivated(World aWorld, int aX, int aY, int aZ, EntityPlayer aPlayer, int aSide, float par1, float par2, float par3)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity == null) || (aPlayer.isSneaking())) {
+ return false;
+ }
+ if ((tTileEntity instanceof IGregTechTileEntity))
+ {
+ if (((IGregTechTileEntity)tTileEntity).getTimer() < 50L) {
+ return false;
+ }
+ if ((!aWorld.isRemote) && (!((IGregTechTileEntity)tTileEntity).isUseableByPlayer(aPlayer))) {
+ return true;
+ }
+ return ((IGregTechTileEntity)tTileEntity).onRightclick(aPlayer, (byte)aSide, par1, par2, par3);
+ }
+ return false;
+ }
+
+ public void onBlockClicked(World aWorld, int aX, int aY, int aZ, EntityPlayer aPlayer)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity != null) &&
+ ((tTileEntity instanceof IGregTechTileEntity))) {
+ ((IGregTechTileEntity)tTileEntity).onLeftclick(aPlayer);
+ }
+ }
+
+ public int getDamageValue(World aWorld, int aX, int aY, int aZ)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity instanceof IGregTechTileEntity)) {
+ return ((IGregTechTileEntity)tTileEntity).getMetaTileID();
+ }
+ return 0;
+ }
+
+ public void onBlockExploded(World aWorld, int aX, int aY, int aZ, Explosion aExplosion)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity instanceof BaseMetaTileEntity)) {
+ ((BaseMetaTileEntity)tTileEntity).doEnergyExplosion();
+ }
+ super.onBlockExploded(aWorld, aX, aY, aZ, aExplosion);
+ }
+
+ public void breakBlock(World aWorld, int aX, int aY, int aZ, Block par5, int par6)
+ {
+ GregTech_API.causeMachineUpdate(aWorld, aX, aY, aZ);
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity instanceof IGregTechTileEntity))
+ {
+ IGregTechTileEntity tGregTechTileEntity = (IGregTechTileEntity)tTileEntity;
+ Random tRandom = new Random();
+ mTemporaryTileEntity.set(tGregTechTileEntity);
+ for (int i = 0; i < tGregTechTileEntity.getSizeInventory(); i++)
+ {
+ ItemStack tItem = tGregTechTileEntity.getStackInSlot(i);
+ if ((tItem != null) && (tItem.stackSize > 0) && (tGregTechTileEntity.isValidSlot(i)))
+ {
+ EntityItem tItemEntity = new EntityItem(aWorld, aX + tRandom.nextFloat() * 0.8F + 0.1F, aY + tRandom.nextFloat() * 0.8F + 0.1F, aZ + tRandom.nextFloat() * 0.8F + 0.1F, new ItemStack(tItem.getItem(), tItem.stackSize, tItem.getItemDamage()));
+ if (tItem.hasTagCompound()) {
+ tItemEntity.getEntityItem().setTagCompound((NBTTagCompound)tItem.getTagCompound().copy());
+ }
+ tItemEntity.motionX = (tRandom.nextGaussian() * 0.0500000007450581D);
+ tItemEntity.motionY = (tRandom.nextGaussian() * 0.0500000007450581D + 0.2000000029802322D);
+ tItemEntity.motionZ = (tRandom.nextGaussian() * 0.0500000007450581D);
+ aWorld.spawnEntityInWorld(tItemEntity);
+ tItem.stackSize = 0;
+ tGregTechTileEntity.setInventorySlotContents(i, null);
+ }
+ }
+ }
+ super.breakBlock(aWorld, aX, aY, aZ, par5, par6);
+ aWorld.removeTileEntity(aX, aY, aZ);
+ }
+
+ public ArrayList<ItemStack> getDrops(World aWorld, int aX, int aY, int aZ, int aMeta, int aFortune)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity instanceof IGregTechTileEntity)) {
+ return ((IGregTechTileEntity)tTileEntity).getDrops();
+ }
+ return mTemporaryTileEntity.get() == null ? new ArrayList() : ((IGregTechTileEntity)mTemporaryTileEntity.get()).getDrops();
+ }
+
+ public int getComparatorInputOverride(World aWorld, int aX, int aY, int aZ, int aSide)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity != null) && ((tTileEntity instanceof IGregTechTileEntity))) {
+ return ((IGregTechTileEntity)tTileEntity).getComparatorValue((byte)aSide);
+ }
+ return 0;
+ }
+
+ public int isProvidingWeakPower(IBlockAccess aWorld, int aX, int aY, int aZ, int aSide)
+ {
+ if ((aSide < 0) || (aSide > 5)) {
+ return 0;
+ }
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity != null) && ((tTileEntity instanceof IGregTechTileEntity))) {
+ return ((IGregTechTileEntity)tTileEntity).getOutputRedstoneSignal(GT_Utility.getOppositeSide(aSide));
+ }
+ return 0;
+ }
+
+ public int isProvidingStrongPower(IBlockAccess aWorld, int aX, int aY, int aZ, int aSide)
+ {
+ if ((aSide < 0) || (aSide > 5)) {
+ return 0;
+ }
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity != null) && ((tTileEntity instanceof IGregTechTileEntity))) {
+ return ((IGregTechTileEntity)tTileEntity).getStrongOutputRedstoneSignal(GT_Utility.getOppositeSide(aSide));
+ }
+ return 0;
+ }
+
+ public void dropBlockAsItemWithChance(World aWorld, int aX, int aY, int aZ, int par5, float chance, int par7)
+ {
+ if (!aWorld.isRemote)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity != null) && (chance < 1.0F))
+ {
+ if (((tTileEntity instanceof BaseMetaTileEntity)) && (GregTech_API.sMachineNonWrenchExplosions)) {
+ ((BaseMetaTileEntity)tTileEntity).doEnergyExplosion();
+ }
+ }
+ else {
+ super.dropBlockAsItemWithChance(aWorld, aX, aY, aZ, par5, chance, par7);
+ }
+ }
+ }
+
+ public boolean isSideSolid(IBlockAccess aWorld, int aX, int aY, int aZ, ForgeDirection aSide)
+ {
+ if (aWorld.getBlockMetadata(aX, aY, aZ) == 0) {
+ return true;
+ }
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if (tTileEntity != null)
+ {
+ if ((tTileEntity instanceof BaseMetaTileEntity)) {
+ return true;
+ }
+ if (((tTileEntity instanceof BaseMetaPipeEntity)) && ((((BaseMetaPipeEntity)tTileEntity).mConnections & 0xFFFFFFC0) != 0)) {
+ return true;
+ }
+ if (((tTileEntity instanceof ICoverable)) && (((ICoverable)tTileEntity).getCoverIDAtSide((byte)aSide.ordinal()) != 0)) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ public int getLightOpacity(IBlockAccess aWorld, int aX, int aY, int aZ)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if (tTileEntity == null) {
+ return 0;
+ }
+ if ((tTileEntity instanceof IGregTechTileEntity)) {
+ return ((IGregTechTileEntity)tTileEntity).getLightOpacity();
+ }
+ return aWorld.getBlockMetadata(aX, aY, aZ) == 0 ? 255 : 0;
+ }
+
+ public int getLightValue(IBlockAccess aWorld, int aX, int aY, int aZ)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity instanceof BaseMetaTileEntity)) {
+ return ((BaseMetaTileEntity)tTileEntity).getLightValue();
+ }
+ return 0;
+ }
+
+ public TileEntity createTileEntity(World aWorld, int aMeta)
+ {
+ if (aMeta < 4) {
+ return GregTech_API.constructBaseMetaTileEntity();
+ }
+ return new BaseMetaPipeEntity();
+ }
+
+ public float getExplosionResistance(Entity par1Entity, World aWorld, int aX, int aY, int aZ, double explosionX, double explosionY, double explosionZ)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity != null) && ((tTileEntity instanceof IGregTechTileEntity))) {
+ return ((IGregTechTileEntity)tTileEntity).getBlastResistance((byte)6);
+ }
+ return 10.0F;
+ }
+
+ @SideOnly(Side.CLIENT)
+ public void getSubBlocks(Item par1, CreativeTabs par2CreativeTabs, List par3List)
+ {
+ for (int i = 1; i < GregTech_API.METATILEENTITIES.length; i++) {
+ if (GregTech_API.METATILEENTITIES[i] != null) {
+ par3List.add(new ItemStack(par1, 1, i));
+ }
+ }
+ }
+
+ public void onBlockPlacedBy(World aWorld, int aX, int aY, int aZ, EntityLivingBase aPlayer, ItemStack aStack)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if (tTileEntity == null) {
+ return;
+ }
+ if ((tTileEntity instanceof IGregTechTileEntity))
+ {
+ IGregTechTileEntity var6 = (IGregTechTileEntity)tTileEntity;
+ if (aPlayer == null)
+ {
+ var6.setFrontFacing((byte)1);
+ }
+ else
+ {
+ int var7 = MathHelper.floor_double(aPlayer.rotationYaw * 4.0F / 360.0F + 0.5D) & 0x3;
+ int var8 = Math.round(aPlayer.rotationPitch);
+ if ((var8 >= 65) && (var6.isValidFacing((byte)1))) {
+ var6.setFrontFacing((byte)1);
+ } else if ((var8 <= -65) && (var6.isValidFacing((byte)0))) {
+ var6.setFrontFacing((byte)0);
+ } else {
+ switch (var7)
+ {
+ case 0:
+ var6.setFrontFacing((byte)2); break;
+ case 1:
+ var6.setFrontFacing((byte)5); break;
+ case 2:
+ var6.setFrontFacing((byte)3); break;
+ case 3:
+ var6.setFrontFacing((byte)4);
+ }
+ }
+ }
+ }
+ }
+
+ public ArrayList<String> getDebugInfo(EntityPlayer aPlayer, int aX, int aY, int aZ, int aLogLevel)
+ {
+ TileEntity tTileEntity = aPlayer.worldObj.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity instanceof BaseMetaTileEntity)) {
+ return ((BaseMetaTileEntity)tTileEntity).getDebugInfo(aPlayer, aLogLevel);
+ }
+ if ((tTileEntity instanceof BaseMetaPipeEntity)) {
+ return ((BaseMetaPipeEntity)tTileEntity).getDebugInfo(aPlayer, aLogLevel);
+ }
+ return null;
+ }
+
+ public boolean recolourBlock(World aWorld, int aX, int aY, int aZ, ForgeDirection aSide, int aColor)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity instanceof IGregTechTileEntity))
+ {
+ if (((IGregTechTileEntity)tTileEntity).getColorization() == (byte)((aColor ^ 0xFFFFFFFF) & 0xF)) {
+ return false;
+ }
+ ((IGregTechTileEntity)tTileEntity).setColorization((byte)((aColor ^ 0xFFFFFFFF) & 0xF));
+ return true;
+ }
+ return false;
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Block_Ores.java b/main/java/gregtech/common/blocks/GT_Block_Ores.java index 19bf814a31..3353150340 100644 --- a/main/java/gregtech/common/blocks/GT_Block_Ores.java +++ b/main/java/gregtech/common/blocks/GT_Block_Ores.java @@ -1,264 +1,264 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import cpw.mods.fml.relauncher.Side;
-/* 4: */ import cpw.mods.fml.relauncher.SideOnly;
-/* 5: */ import gregtech.api.GregTech_API;
-/* 6: */ import gregtech.api.enums.Materials;
-/* 7: */ import gregtech.api.enums.OrePrefixes;
-/* 8: */ import gregtech.api.items.GT_Generic_Block;
-/* 9: */ import gregtech.api.util.GT_LanguageManager;
-/* 10: */ import gregtech.api.util.GT_ModHandler;
-/* 11: */ import gregtech.api.util.GT_OreDictUnificator;
-/* 12: */ import gregtech.common.render.GT_Renderer_Block;
-/* 13: */ import java.util.ArrayList;
-/* 14: */ import java.util.List;
-/* 15: */ import net.minecraft.block.Block;
-/* 16: */ import net.minecraft.block.ITileEntityProvider;
-/* 17: */ import net.minecraft.block.material.Material;
-/* 18: */ import net.minecraft.client.renderer.texture.IIconRegister;
-/* 19: */ import net.minecraft.creativetab.CreativeTabs;
-/* 20: */ import net.minecraft.entity.Entity;
-/* 21: */ import net.minecraft.entity.boss.EntityDragon;
-/* 22: */ import net.minecraft.init.Blocks;
-/* 23: */ import net.minecraft.item.Item;
-/* 24: */ import net.minecraft.item.ItemStack;
-/* 25: */ import net.minecraft.tileentity.TileEntity;
-/* 26: */ import net.minecraft.util.IIcon;
-/* 27: */ import net.minecraft.util.StatCollector;
-/* 28: */ import net.minecraft.world.IBlockAccess;
-/* 29: */ import net.minecraft.world.World;
-/* 30: */
-/* 31: */ public class GT_Block_Ores
-/* 32: */ extends GT_Generic_Block
-/* 33: */ implements ITileEntityProvider
-/* 34: */ {
-/* 35: 35 */ public static ThreadLocal<GT_TileEntity_Ores> mTemporaryTileEntity = new ThreadLocal();
-/* 36: */
-/* 37: */ public GT_Block_Ores()
-/* 38: */ {
-/* 39: 38 */ super(GT_Item_Ores.class, "gt.blockores", Material.rock);
-/* 40: 39 */ this.isBlockContainer = true;
-/* 41: 40 */ setStepSound(soundTypeStone);
-/* 42: 41 */ setCreativeTab(GregTech_API.TAB_GREGTECH_ORES);
-/* 43: 42 */ for (int i = 0; i < 16; i++) {
-/* 44: 42 */ GT_ModHandler.addValuableOre(this, i, 1);
-/* 45: */ }
-/* 46: 43 */ for (int i = 1; i < GregTech_API.sGeneratedMaterials.length; i++) {
-/* 47: 43 */ if (GregTech_API.sGeneratedMaterials[i] != null)
-/* 48: */ {
-/* 49: 44 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + i + ".name", getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
-/* 50: 45 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 1000) + ".name", getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
-/* 51: 46 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 2000) + ".name", getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
-/* 52: 47 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 3000) + ".name", getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
-/* 53: 48 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 4000) + ".name", getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
-/* 54: 49 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 16000) + ".name", "Small " + getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
-/* 55: 50 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 17000) + ".name", "Small " + getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
-/* 56: 51 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 18000) + ".name", "Small " + getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
-/* 57: 52 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 19000) + ".name", "Small " + getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
-/* 58: 53 */ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 20000) + ".name", "Small " + getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
-/* 59: 54 */ if ((GregTech_API.sGeneratedMaterials[i].mTypes & 0x8) != 0)
-/* 60: */ {
-/* 61: 55 */ GT_OreDictUnificator.registerOre(OrePrefixes.ore.get(GregTech_API.sGeneratedMaterials[i]), new ItemStack(this, 1, i));
-/* 62: 56 */ GT_OreDictUnificator.registerOre(OrePrefixes.oreNetherrack.get(GregTech_API.sGeneratedMaterials[i]), new ItemStack(this, 1, i + 1000));
-/* 63: 57 */ GT_OreDictUnificator.registerOre(OrePrefixes.oreEndstone.get(GregTech_API.sGeneratedMaterials[i]), new ItemStack(this, 1, i + 2000));
-/* 64: 58 */ GT_OreDictUnificator.registerOre(OrePrefixes.oreBlackgranite.get(GregTech_API.sGeneratedMaterials[i]), new ItemStack(this, 1, i + 3000));
-/* 65: 59 */ GT_OreDictUnificator.registerOre(OrePrefixes.oreRedgranite.get(GregTech_API.sGeneratedMaterials[i]), new ItemStack(this, 1, i + 4000));
-/* 66: */ }
-/* 67: */ }
-/* 68: */ }
-/* 69: */ }
-/* 70: */
-/* 71: 64 */ public static boolean FUCKING_LOCK = false;
-/* 72: */
-/* 73: */ public void onNeighborChange(IBlockAccess aWorld, int aX, int aY, int aZ, int aTileX, int aTileY, int aTileZ)
-/* 74: */ {
-/* 75: 68 */ if (!FUCKING_LOCK)
-/* 76: */ {
-/* 77: 69 */ FUCKING_LOCK = true;
-/* 78: 70 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 79: 71 */ if ((tTileEntity instanceof GT_TileEntity_Ores)) {
-/* 80: 71 */ ((GT_TileEntity_Ores)tTileEntity).onUpdated();
-/* 81: */ }
-/* 82: */ }
-/* 83: 73 */ FUCKING_LOCK = false;
-/* 84: */ }
-/* 85: */
-/* 86: */ public void onNeighborBlockChange(World aWorld, int aX, int aY, int aZ, Block aBlock)
-/* 87: */ {
-/* 88: 78 */ if (!FUCKING_LOCK)
-/* 89: */ {
-/* 90: 79 */ FUCKING_LOCK = true;
-/* 91: 80 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 92: 81 */ if ((tTileEntity instanceof GT_TileEntity_Ores)) {
-/* 93: 81 */ ((GT_TileEntity_Ores)tTileEntity).onUpdated();
-/* 94: */ }
-/* 95: */ }
-/* 96: 83 */ FUCKING_LOCK = false;
-/* 97: */ }
-/* 98: */
-/* 99: */ public String getLocalizedName(Materials aMaterial) {
- /* 87 */ switch (aMaterial) {
- /* */ case InfusedAir: case InfusedDull: case InfusedEarth: case InfusedEntropy: case InfusedFire: case InfusedOrder: case InfusedVis: case InfusedWater:
- /* 89 */ return aMaterial.mDefaultLocalName + " Infused Stone";
- /* */ case Vermiculite: case Bentonite: case Kaolinite: case Talc: case BasalticMineralSand: case GraniticMineralSand: case GlauconiteSand: case CassiteriteSand: case GarnetSand: case QuartzSand: case Pitchblende: case FullersEarth:
- /* 91 */ return aMaterial.mDefaultLocalName;
- /* */ }
- /* 93 */ return aMaterial.mDefaultLocalName + OrePrefixes.ore.mLocalizedMaterialPost;
- /* */ }
-/* 128: */
-/* 129: */ public boolean onBlockEventReceived(World p_149696_1_, int p_149696_2_, int p_149696_3_, int p_149696_4_, int p_149696_5_, int p_149696_6_)
-/* 130: */ {
-/* 131: 99 */ super.onBlockEventReceived(p_149696_1_, p_149696_2_, p_149696_3_, p_149696_4_, p_149696_5_, p_149696_6_);
-/* 132:100 */ TileEntity tileentity = p_149696_1_.getTileEntity(p_149696_2_, p_149696_3_, p_149696_4_);
-/* 133:101 */ return tileentity != null ? tileentity.receiveClientEvent(p_149696_5_, p_149696_6_) : false;
-/* 134: */ }
-/* 135: */
-/* 136: */ public boolean canEntityDestroy(IBlockAccess world, int x, int y, int z, Entity entity)
-/* 137: */ {
-/* 138:106 */ return (!(entity instanceof EntityDragon)) && (super.canEntityDestroy(world, x, y, z, entity));
-/* 139: */ }
-/* 140: */
-/* 141: */ public String getHarvestTool(int aMeta)
-/* 142: */ {
-/* 143:111 */ return aMeta < 8 ? "pickaxe" : "shovel";
-/* 144: */ }
-/* 145: */
-/* 146: */ public int getHarvestLevel(int aMeta)
-/* 147: */ {
-/* 148:116 */ return aMeta % 8;
-/* 149: */ }
-/* 150: */
-/* 151: */ public float getBlockHardness(World aWorld, int aX, int aY, int aZ)
-/* 152: */ {
-/* 153:121 */ return 1.0F + getHarvestLevel(aWorld.getBlockMetadata(aX, aY, aZ)) * 1.0F;
-/* 154: */ }
-/* 155: */
-/* 156: */ public float getExplosionResistance(Entity par1Entity, World aWorld, int aX, int aY, int aZ, double explosionX, double explosionY, double explosionZ)
-/* 157: */ {
-/* 158:126 */ return 1.0F + getHarvestLevel(aWorld.getBlockMetadata(aX, aY, aZ)) * 1.0F;
-/* 159: */ }
-/* 160: */
-/* 161: */ protected boolean canSilkHarvest()
-/* 162: */ {
-/* 163:131 */ return false;
-/* 164: */ }
-/* 165: */
-/* 166: */ public String getUnlocalizedName()
-/* 167: */ {
-/* 168:134 */ return "gt.blockores";
-/* 169: */ }
-/* 170: */
-/* 171: */ public String getLocalizedName()
-/* 172: */ {
-/* 173:135 */ return StatCollector.translateToLocal(getUnlocalizedName() + ".name");
-/* 174: */ }
-/* 175: */
-/* 176: */ public int getRenderType()
-/* 177: */ {
-/* 178:136 */ if (GT_Renderer_Block.INSTANCE == null) {
-/* 179:136 */ return super.getRenderType();
-/* 180: */ }
-/* 181:136 */ return GT_Renderer_Block.INSTANCE.mRenderID;
-/* 182: */ }
-/* 183: */
-/* 184: */ public boolean canBeReplacedByLeaves(IBlockAccess aWorld, int aX, int aY, int aZ)
-/* 185: */ {
-/* 186:137 */ return false;
-/* 187: */ }
-/* 188: */
-/* 189: */ public boolean isNormalCube(IBlockAccess aWorld, int aX, int aY, int aZ)
-/* 190: */ {
-/* 191:138 */ return true;
-/* 192: */ }
-/* 193: */
-/* 194: */ public boolean hasTileEntity(int aMeta)
-/* 195: */ {
-/* 196:139 */ return true;
-/* 197: */ }
-/* 198: */
-/* 199: */ public boolean renderAsNormalBlock()
-/* 200: */ {
-/* 201:140 */ return true;
-/* 202: */ }
-/* 203: */
-/* 204: */ public boolean isOpaqueCube()
-/* 205: */ {
-/* 206:141 */ return true;
-/* 207: */ }
-/* 208: */
-/* 209: */ public TileEntity createNewTileEntity(World aWorld, int aMeta)
-/* 210: */ {
-/* 211:142 */ return createTileEntity(aWorld, aMeta);
-/* 212: */ }
-/* 213: */
-/* 214: */ public IIcon getIcon(IBlockAccess aIBlockAccess, int aX, int aY, int aZ, int aSide)
-/* 215: */ {
-/* 216:143 */ return Blocks.stone.getIcon(0, 0);
-/* 217: */ }
-/* 218: */
-/* 219: */ public IIcon getIcon(int aSide, int aMeta)
-/* 220: */ {
-/* 221:144 */ return Blocks.stone.getIcon(0, 0);
-/* 222: */ }
-/* 223: */
-/* 224: */ @SideOnly(Side.CLIENT)
-/* 225: */ public void registerBlockIcons(IIconRegister aIconRegister) {}
-/* 226: */
-/* 227: */ public int getDamageValue(World aWorld, int aX, int aY, int aZ)
-/* 228: */ {
-/* 229:154 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 230:155 */ if ((tTileEntity != null) && ((tTileEntity instanceof GT_TileEntity_Ores))) {
-/* 231:155 */ return ((GT_TileEntity_Ores)tTileEntity).getMetaData();
-/* 232: */ }
-/* 233:156 */ return 0;
-/* 234: */ }
-/* 235: */
-/* 236: */ public void breakBlock(World aWorld, int aX, int aY, int aZ, Block par5, int par6)
-/* 237: */ {
-/* 238:161 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 239:162 */ if ((tTileEntity instanceof GT_TileEntity_Ores)) {
-/* 240:162 */ mTemporaryTileEntity.set((GT_TileEntity_Ores)tTileEntity);
-/* 241: */ }
-/* 242:163 */ super.breakBlock(aWorld, aX, aY, aZ, par5, par6);
-/* 243:164 */ aWorld.removeTileEntity(aX, aY, aZ);
-/* 244: */ }
-/* 245: */
-/* 246: */ public ArrayList<ItemStack> getDrops(World aWorld, int aX, int aY, int aZ, int aMeta, int aFortune)
-/* 247: */ {
-/* 248:169 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 249:170 */ if ((tTileEntity instanceof GT_TileEntity_Ores)) {
-/* 250:170 */ return ((GT_TileEntity_Ores)tTileEntity).getDrops(aFortune);
-/* 251: */ }
-/* 252:171 */ return mTemporaryTileEntity.get() == null ? new ArrayList() : ((GT_TileEntity_Ores)mTemporaryTileEntity.get()).getDrops(aFortune);
-/* 253: */ }
-/* 254: */
-/* 255: */ public TileEntity createTileEntity(World aWorld, int aMeta)
-/* 256: */ {
-/* 257:176 */ return new GT_TileEntity_Ores();
-/* 258: */ }
-/* 259: */
-/* 260: */ @SideOnly(Side.CLIENT)
-/* 261: */ public void getSubBlocks(Item aItem, CreativeTabs aTab, List aList)
-/* 262: */ {
-/* 263:182 */ for (int i = 0; i < GregTech_API.sGeneratedMaterials.length; i++)
-/* 264: */ {
-/* 265:183 */ Materials tMaterial = GregTech_API.sGeneratedMaterials[i];
-/* 266:184 */ if ((tMaterial != null) && ((tMaterial.mTypes & 0x8) != 0))
-/* 267: */ {
-/* 268:185 */ aList.add(new ItemStack(aItem, 1, i));
-/* 269:186 */ aList.add(new ItemStack(aItem, 1, i + 1000));
-/* 270:187 */ aList.add(new ItemStack(aItem, 1, i + 2000));
-/* 271:188 */ aList.add(new ItemStack(aItem, 1, i + 3000));
-/* 272:189 */ aList.add(new ItemStack(aItem, 1, i + 4000));
-/* 273:190 */ aList.add(new ItemStack(aItem, 1, i + 16000));
-/* 274:191 */ aList.add(new ItemStack(aItem, 1, i + 17000));
-/* 275:192 */ aList.add(new ItemStack(aItem, 1, i + 18000));
-/* 276:193 */ aList.add(new ItemStack(aItem, 1, i + 19000));
-/* 277:194 */ aList.add(new ItemStack(aItem, 1, i + 20000));
-/* 278: */ }
-/* 279: */ }
-/* 280: */ }
-/* 281: */ }
+package gregtech.common.blocks;
+
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.Materials;
+import gregtech.api.enums.OrePrefixes;
+import gregtech.api.items.GT_Generic_Block;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_ModHandler;
+import gregtech.api.util.GT_OreDictUnificator;
+import gregtech.common.render.GT_Renderer_Block;
+import java.util.ArrayList;
+import java.util.List;
+import net.minecraft.block.Block;
+import net.minecraft.block.ITileEntityProvider;
+import net.minecraft.block.material.Material;
+import net.minecraft.client.renderer.texture.IIconRegister;
+import net.minecraft.creativetab.CreativeTabs;
+import net.minecraft.entity.Entity;
+import net.minecraft.entity.boss.EntityDragon;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.Item;
+import net.minecraft.item.ItemStack;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.util.IIcon;
+import net.minecraft.util.StatCollector;
+import net.minecraft.world.IBlockAccess;
+import net.minecraft.world.World;
+
+public class GT_Block_Ores
+ extends GT_Generic_Block
+ implements ITileEntityProvider
+{
+ public static ThreadLocal<GT_TileEntity_Ores> mTemporaryTileEntity = new ThreadLocal();
+
+ public GT_Block_Ores()
+ {
+ super(GT_Item_Ores.class, "gt.blockores", Material.rock);
+ this.isBlockContainer = true;
+ setStepSound(soundTypeStone);
+ setCreativeTab(GregTech_API.TAB_GREGTECH_ORES);
+ for (int i = 0; i < 16; i++) {
+ GT_ModHandler.addValuableOre(this, i, 1);
+ }
+ for (int i = 1; i < GregTech_API.sGeneratedMaterials.length; i++) {
+ if (GregTech_API.sGeneratedMaterials[i] != null)
+ {
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + i + ".name", getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 1000) + ".name", getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 2000) + ".name", getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 3000) + ".name", getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 4000) + ".name", getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 16000) + ".name", "Small " + getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 17000) + ".name", "Small " + getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 18000) + ".name", "Small " + getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 19000) + ".name", "Small " + getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
+ GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + 20000) + ".name", "Small " + getLocalizedName(GregTech_API.sGeneratedMaterials[i]));
+ if ((GregTech_API.sGeneratedMaterials[i].mTypes & 0x8) != 0)
+ {
+ GT_OreDictUnificator.registerOre(OrePrefixes.ore.get(GregTech_API.sGeneratedMaterials[i]), new ItemStack(this, 1, i));
+ GT_OreDictUnificator.registerOre(OrePrefixes.oreNetherrack.get(GregTech_API.sGeneratedMaterials[i]), new ItemStack(this, 1, i + 1000));
+ GT_OreDictUnificator.registerOre(OrePrefixes.oreEndstone.get(GregTech_API.sGeneratedMaterials[i]), new ItemStack(this, 1, i + 2000));
+ GT_OreDictUnificator.registerOre(OrePrefixes.oreBlackgranite.get(GregTech_API.sGeneratedMaterials[i]), new ItemStack(this, 1, i + 3000));
+ GT_OreDictUnificator.registerOre(OrePrefixes.oreRedgranite.get(GregTech_API.sGeneratedMaterials[i]), new ItemStack(this, 1, i + 4000));
+ }
+ }
+ }
+ }
+
+ public static boolean FUCKING_LOCK = false;
+
+ public void onNeighborChange(IBlockAccess aWorld, int aX, int aY, int aZ, int aTileX, int aTileY, int aTileZ)
+ {
+ if (!FUCKING_LOCK)
+ {
+ FUCKING_LOCK = true;
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity instanceof GT_TileEntity_Ores)) {
+ ((GT_TileEntity_Ores)tTileEntity).onUpdated();
+ }
+ }
+ FUCKING_LOCK = false;
+ }
+
+ public void onNeighborBlockChange(World aWorld, int aX, int aY, int aZ, Block aBlock)
+ {
+ if (!FUCKING_LOCK)
+ {
+ FUCKING_LOCK = true;
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity instanceof GT_TileEntity_Ores)) {
+ ((GT_TileEntity_Ores)tTileEntity).onUpdated();
+ }
+ }
+ FUCKING_LOCK = false;
+ }
+
+ public String getLocalizedName(Materials aMaterial) {
+ switch (aMaterial) {
+ case InfusedAir: case InfusedDull: case InfusedEarth: case InfusedEntropy: case InfusedFire: case InfusedOrder: case InfusedVis: case InfusedWater:
+ return aMaterial.mDefaultLocalName + " Infused Stone";
+ case Vermiculite: case Bentonite: case Kaolinite: case Talc: case BasalticMineralSand: case GraniticMineralSand: case GlauconiteSand: case CassiteriteSand: case GarnetSand: case QuartzSand: case Pitchblende: case FullersEarth:
+ return aMaterial.mDefaultLocalName;
+ }
+ return aMaterial.mDefaultLocalName + OrePrefixes.ore.mLocalizedMaterialPost;
+ }
+
+ public boolean onBlockEventReceived(World p_149696_1_, int p_149696_2_, int p_149696_3_, int p_149696_4_, int p_149696_5_, int p_149696_6_)
+ {
+ super.onBlockEventReceived(p_149696_1_, p_149696_2_, p_149696_3_, p_149696_4_, p_149696_5_, p_149696_6_);
+ TileEntity tileentity = p_149696_1_.getTileEntity(p_149696_2_, p_149696_3_, p_149696_4_);
+ return tileentity != null ? tileentity.receiveClientEvent(p_149696_5_, p_149696_6_) : false;
+ }
+
+ public boolean canEntityDestroy(IBlockAccess world, int x, int y, int z, Entity entity)
+ {
+ return (!(entity instanceof EntityDragon)) && (super.canEntityDestroy(world, x, y, z, entity));
+ }
+
+ public String getHarvestTool(int aMeta)
+ {
+ return aMeta < 8 ? "pickaxe" : "shovel";
+ }
+
+ public int getHarvestLevel(int aMeta)
+ {
+ return aMeta % 8;
+ }
+
+ public float getBlockHardness(World aWorld, int aX, int aY, int aZ)
+ {
+ return 1.0F + getHarvestLevel(aWorld.getBlockMetadata(aX, aY, aZ)) * 1.0F;
+ }
+
+ public float getExplosionResistance(Entity par1Entity, World aWorld, int aX, int aY, int aZ, double explosionX, double explosionY, double explosionZ)
+ {
+ return 1.0F + getHarvestLevel(aWorld.getBlockMetadata(aX, aY, aZ)) * 1.0F;
+ }
+
+ protected boolean canSilkHarvest()
+ {
+ return false;
+ }
+
+ public String getUnlocalizedName()
+ {
+ return "gt.blockores";
+ }
+
+ public String getLocalizedName()
+ {
+ return StatCollector.translateToLocal(getUnlocalizedName() + ".name");
+ }
+
+ public int getRenderType()
+ {
+ if (GT_Renderer_Block.INSTANCE == null) {
+ return super.getRenderType();
+ }
+ return GT_Renderer_Block.INSTANCE.mRenderID;
+ }
+
+ public boolean canBeReplacedByLeaves(IBlockAccess aWorld, int aX, int aY, int aZ)
+ {
+ return false;
+ }
+
+ public boolean isNormalCube(IBlockAccess aWorld, int aX, int aY, int aZ)
+ {
+ return true;
+ }
+
+ public boolean hasTileEntity(int aMeta)
+ {
+ return true;
+ }
+
+ public boolean renderAsNormalBlock()
+ {
+ return true;
+ }
+
+ public boolean isOpaqueCube()
+ {
+ return true;
+ }
+
+ public TileEntity createNewTileEntity(World aWorld, int aMeta)
+ {
+ return createTileEntity(aWorld, aMeta);
+ }
+
+ public IIcon getIcon(IBlockAccess aIBlockAccess, int aX, int aY, int aZ, int aSide)
+ {
+ return Blocks.stone.getIcon(0, 0);
+ }
+
+ public IIcon getIcon(int aSide, int aMeta)
+ {
+ return Blocks.stone.getIcon(0, 0);
+ }
+
+ @SideOnly(Side.CLIENT)
+ public void registerBlockIcons(IIconRegister aIconRegister) {}
+
+ public int getDamageValue(World aWorld, int aX, int aY, int aZ)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity != null) && ((tTileEntity instanceof GT_TileEntity_Ores))) {
+ return ((GT_TileEntity_Ores)tTileEntity).getMetaData();
+ }
+ return 0;
+ }
+
+ public void breakBlock(World aWorld, int aX, int aY, int aZ, Block par5, int par6)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity instanceof GT_TileEntity_Ores)) {
+ mTemporaryTileEntity.set((GT_TileEntity_Ores)tTileEntity);
+ }
+ super.breakBlock(aWorld, aX, aY, aZ, par5, par6);
+ aWorld.removeTileEntity(aX, aY, aZ);
+ }
+
+ public ArrayList<ItemStack> getDrops(World aWorld, int aX, int aY, int aZ, int aMeta, int aFortune)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity instanceof GT_TileEntity_Ores)) {
+ return ((GT_TileEntity_Ores)tTileEntity).getDrops(aFortune);
+ }
+ return mTemporaryTileEntity.get() == null ? new ArrayList() : ((GT_TileEntity_Ores)mTemporaryTileEntity.get()).getDrops(aFortune);
+ }
+
+ public TileEntity createTileEntity(World aWorld, int aMeta)
+ {
+ return new GT_TileEntity_Ores();
+ }
+
+ @SideOnly(Side.CLIENT)
+ public void getSubBlocks(Item aItem, CreativeTabs aTab, List aList)
+ {
+ for (int i = 0; i < GregTech_API.sGeneratedMaterials.length; i++)
+ {
+ Materials tMaterial = GregTech_API.sGeneratedMaterials[i];
+ if ((tMaterial != null) && ((tMaterial.mTypes & 0x8) != 0))
+ {
+ aList.add(new ItemStack(aItem, 1, i));
+ aList.add(new ItemStack(aItem, 1, i + 1000));
+ aList.add(new ItemStack(aItem, 1, i + 2000));
+ aList.add(new ItemStack(aItem, 1, i + 3000));
+ aList.add(new ItemStack(aItem, 1, i + 4000));
+ aList.add(new ItemStack(aItem, 1, i + 16000));
+ aList.add(new ItemStack(aItem, 1, i + 17000));
+ aList.add(new ItemStack(aItem, 1, i + 18000));
+ aList.add(new ItemStack(aItem, 1, i + 19000));
+ aList.add(new ItemStack(aItem, 1, i + 20000));
+ }
+ }
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Block_Stones_Abstract.java b/main/java/gregtech/common/blocks/GT_Block_Stones_Abstract.java index fe427a0428..011a0e0614 100644 --- a/main/java/gregtech/common/blocks/GT_Block_Stones_Abstract.java +++ b/main/java/gregtech/common/blocks/GT_Block_Stones_Abstract.java @@ -1,178 +1,178 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import cpw.mods.fml.relauncher.Side;
-/* 4: */ import cpw.mods.fml.relauncher.SideOnly;
-/* 5: */ import gregtech.api.GregTech_API;
-/* 6: */ import gregtech.api.enums.GT_Values;
-/* 7: */ import gregtech.api.enums.ItemList;
-/* 8: */ import gregtech.api.enums.Materials;
-/* 9: */ import gregtech.api.enums.OreDictNames;
-/* 10: */ import gregtech.api.enums.OrePrefixes;
-/* 11: */ import gregtech.api.interfaces.IIconContainer;
-/* 12: */ import gregtech.api.interfaces.IOreRecipeRegistrator;
-/* 13: */ import gregtech.api.interfaces.internal.IGT_RecipeAdder;
-/* 14: */ import gregtech.api.items.GT_Generic_Block;
-/* 15: */ import gregtech.api.util.GT_ModHandler;
-/* 16: */ import gregtech.api.util.GT_ModHandler.RecipeBits;
-/* 17: */ import gregtech.api.util.GT_Utility;
-/* 18: */ import java.util.List;
-/* 19: */ import java.util.Random;
-/* 20: */ import net.minecraft.block.Block;
-/* 21: */ import net.minecraft.block.material.Material;
-/* 22: */ import net.minecraft.client.renderer.texture.IIconRegister;
-/* 23: */ import net.minecraft.creativetab.CreativeTabs;
-/* 24: */ import net.minecraft.entity.EnumCreatureType;
-/* 25: */ import net.minecraft.init.Blocks;
-/* 26: */ import net.minecraft.item.Item;
-/* 27: */ import net.minecraft.item.ItemBlock;
-/* 28: */ import net.minecraft.item.ItemStack;
-/* 29: */ import net.minecraft.util.IIcon;
-/* 30: */ import net.minecraft.util.StatCollector;
-/* 31: */ import net.minecraft.world.IBlockAccess;
-/* 32: */ import net.minecraft.world.World;
-/* 33: */
-/* 34: */ public class GT_Block_Stones_Abstract
-/* 35: */ extends GT_Generic_Block
-/* 36: */ implements IOreRecipeRegistrator
-/* 37: */ {
-/* 38: */ public GT_Block_Stones_Abstract(Class<? extends ItemBlock> aItemClass, String aName)
-/* 39: */ {
-/* 40: 31 */ super(aItemClass, aName, Material.rock);
-/* 41: 32 */ OrePrefixes.crafting.add(this);
-/* 42: 33 */ setStepSound(soundTypeStone);
-/* 43: 34 */ setCreativeTab(GregTech_API.TAB_GREGTECH_MATERIALS);
-/* 44: 35 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 0), new ItemStack(this, 1, 7));
-/* 45: 36 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 1), new ItemStack(this, 1, 0));
-/* 46: 37 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 2), new ItemStack(this, 1, 0));
-/* 47: 38 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 3), new ItemStack(this, 1, 0));
-/* 48: 39 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 4), new ItemStack(this, 1, 0));
-/* 49: 40 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 5), new ItemStack(this, 1, 0));
-/* 50: 41 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 6), new ItemStack(this, 1, 0));
-/* 51: 42 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 7), new ItemStack(this, 1, 0));
-/* 52: 43 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 8), new ItemStack(this, 1, 15));
-/* 53: 44 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 9), new ItemStack(this, 1, 8));
-/* 54: 45 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 10), new ItemStack(this, 1, 8));
-/* 55: 46 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 11), new ItemStack(this, 1, 8));
-/* 56: 47 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 12), new ItemStack(this, 1, 8));
-/* 57: 48 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 13), new ItemStack(this, 1, 8));
-/* 58: 49 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 14), new ItemStack(this, 1, 8));
-/* 59: 50 */ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 15), new ItemStack(this, 1, 8));
-/* 60: 51 */ GT_Values.RA.addAssemblerRecipe(new ItemStack(this, 1, 0), ItemList.Circuit_Integrated.getWithDamage(0L, 4L, new Object[0]), new ItemStack(this, 1, 3), 50, 4);
-/* 61: 52 */ GT_Values.RA.addAssemblerRecipe(new ItemStack(this, 1, 8), ItemList.Circuit_Integrated.getWithDamage(0L, 4L, new Object[0]), new ItemStack(this, 1, 11), 50, 4);
-/* 62: 53 */ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 1, 6), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "f", "X", Character.valueOf('X'), new ItemStack(this, 1, 7) });
-/* 63: 54 */ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 1, 14), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "f", "X", Character.valueOf('X'), new ItemStack(this, 1, 15) });
-/* 64: 55 */ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 1, 4), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "h", "X", Character.valueOf('X'), new ItemStack(this, 1, 3) });
-/* 65: 56 */ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 1, 12), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "h", "X", Character.valueOf('X'), new ItemStack(this, 1, 11) });
-/* 66: 57 */ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 1, 1), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "h", "X", Character.valueOf('X'), new ItemStack(this, 1, 0) });
-/* 67: 58 */ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 1, 9), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "h", "X", Character.valueOf('X'), new ItemStack(this, 1, 8) });
-/* 68: 59 */ GT_Values.RA.addForgeHammerRecipe(new ItemStack(this, 1, 3), new ItemStack(this, 1, 4), 16, 10);
-/* 69: 60 */ GT_Values.RA.addForgeHammerRecipe(new ItemStack(this, 1, 11), new ItemStack(this, 1, 12), 16, 10);
-/* 70: 61 */ GT_Values.RA.addForgeHammerRecipe(new ItemStack(this, 1, 0), new ItemStack(this, 1, 1), 16, 10);
-/* 71: 62 */ GT_Values.RA.addForgeHammerRecipe(new ItemStack(this, 1, 8), new ItemStack(this, 1, 9), 16, 10);
-/* 72: 63 */ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 4, 3), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "XX", "XX", Character.valueOf('X'), new ItemStack(this, 4, 0) });
-/* 73: 64 */ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 4, 11), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "XX", "XX", Character.valueOf('X'), new ItemStack(this, 4, 8) });
-/* 74: 65 */ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 4, 3), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "XX", "XX", Character.valueOf('X'), new ItemStack(this, 4, 7) });
-/* 75: 66 */ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 4, 11), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "XX", "XX", Character.valueOf('X'), new ItemStack(this, 4, 15) });
-/* 76: */ }
-/* 77: */
-/* 78: */ public void registerOre(OrePrefixes aPrefix, Materials aMaterial, String aOreDictName, String aModName, ItemStack aStack)
-/* 79: */ {
-/* 80: 71 */ if (aOreDictName.equals(OreDictNames.craftingLensWhite.toString()))
-/* 81: */ {
-/* 82: 72 */ GT_Values.RA.addLaserEngraverRecipe(new ItemStack(this, 1, 7), GT_Utility.copyAmount(0L, new Object[] { aStack }), new ItemStack(this, 1, 6), 50, 16);
-/* 83: 73 */ GT_Values.RA.addLaserEngraverRecipe(new ItemStack(this, 1, 15), GT_Utility.copyAmount(0L, new Object[] { aStack }), new ItemStack(this, 1, 14), 50, 16);
-/* 84: */ }
-/* 85: */ }
-/* 86: */
-/* 87: */ public String getHarvestTool(int aMeta)
-/* 88: */ {
-/* 89: 79 */ return "pickaxe";
-/* 90: */ }
-/* 91: */
-/* 92: */ public int getHarvestLevel(int aMeta)
-/* 93: */ {
-/* 94: 84 */ return 1;
-/* 95: */ }
-/* 96: */
-/* 97: */ public float getBlockHardness(World aWorld, int aX, int aY, int aZ)
-/* 98: */ {
-/* 99: 89 */ return this.blockHardness = Blocks.stone.getBlockHardness(aWorld, aX, aY, aZ) * 3.0F;
-/* 100: */ }
-/* 101: */
-/* 102: */ public String getUnlocalizedName()
-/* 103: */ {
-/* 104: 92 */ return this.mUnlocalizedName;
-/* 105: */ }
-/* 106: */
-/* 107: */ public String getLocalizedName()
-/* 108: */ {
-/* 109: 93 */ return StatCollector.translateToLocal(this.mUnlocalizedName + ".name");
-/* 110: */ }
-/* 111: */
-/* 112: */ public boolean canBeReplacedByLeaves(IBlockAccess aWorld, int aX, int aY, int aZ)
-/* 113: */ {
-/* 114: 94 */ return false;
-/* 115: */ }
-/* 116: */
-/* 117: */ public boolean isNormalCube(IBlockAccess aWorld, int aX, int aY, int aZ)
-/* 118: */ {
-/* 119: 95 */ return true;
-/* 120: */ }
-/* 121: */
-/* 122: */ public boolean renderAsNormalBlock()
-/* 123: */ {
-/* 124: 96 */ return true;
-/* 125: */ }
-/* 126: */
-/* 127: */ public boolean isOpaqueCube()
-/* 128: */ {
-/* 129: 97 */ return true;
-/* 130: */ }
-/* 131: */
-/* 132: */ public IIcon getIcon(int aSide, int aMeta)
-/* 133: */ {
-/* 134: 98 */ if ((aMeta >= 0) && (aMeta < 16)) {
-/* 135: 98 */ return gregtech.api.enums.Textures.BlockIcons.GRANITES[aMeta].getIcon();
-/* 136: */ }
-/* 137: 98 */ return null;
-/* 138: */ }
-/* 139: */
-/* 140: */ public boolean canCreatureSpawn(EnumCreatureType type, IBlockAccess world, int x, int y, int z)
-/* 141: */ {
-/* 142:102 */ return world.getBlockMetadata(x, y, z) % 8 < 3;
-/* 143: */ }
-/* 144: */
-/* 145: */ public int damageDropped(int par1)
-/* 146: */ {
-/* 147:107 */ return par1 % 8 == 0 ? par1 + 1 : par1;
-/* 148: */ }
-/* 149: */
-/* 150: */ public int getDamageValue(World par1World, int par2, int par3, int par4)
-/* 151: */ {
-/* 152:112 */ return par1World.getBlockMetadata(par2, par3, par4);
-/* 153: */ }
-/* 154: */
-/* 155: */ public int quantityDropped(Random par1Random)
-/* 156: */ {
-/* 157:117 */ return 1;
-/* 158: */ }
-/* 159: */
-/* 160: */ public Item getItemDropped(int par1, Random par2Random, int par3)
-/* 161: */ {
-/* 162:122 */ return Item.getItemFromBlock(this);
-/* 163: */ }
-/* 164: */
-/* 165: */ @SideOnly(Side.CLIENT)
-/* 166: */ public void registerBlockIcons(IIconRegister aIconRegister) {}
-/* 167: */
-/* 168: */ @SideOnly(Side.CLIENT)
-/* 169: */ public void getSubBlocks(Item aItem, CreativeTabs par2CreativeTabs, List aList)
-/* 170: */ {
-/* 171:133 */ for (int i = 0; i < 16; i++) {
-/* 172:133 */ aList.add(new ItemStack(aItem, 1, i));
-/* 173: */ }
-/* 174: */ }
-/* 175: */ }
+package gregtech.common.blocks;
+
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.GT_Values;
+import gregtech.api.enums.ItemList;
+import gregtech.api.enums.Materials;
+import gregtech.api.enums.OreDictNames;
+import gregtech.api.enums.OrePrefixes;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.interfaces.IOreRecipeRegistrator;
+import gregtech.api.interfaces.internal.IGT_RecipeAdder;
+import gregtech.api.items.GT_Generic_Block;
+import gregtech.api.util.GT_ModHandler;
+import gregtech.api.util.GT_ModHandler.RecipeBits;
+import gregtech.api.util.GT_Utility;
+import java.util.List;
+import java.util.Random;
+import net.minecraft.block.Block;
+import net.minecraft.block.material.Material;
+import net.minecraft.client.renderer.texture.IIconRegister;
+import net.minecraft.creativetab.CreativeTabs;
+import net.minecraft.entity.EnumCreatureType;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.Item;
+import net.minecraft.item.ItemBlock;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.IIcon;
+import net.minecraft.util.StatCollector;
+import net.minecraft.world.IBlockAccess;
+import net.minecraft.world.World;
+
+public class GT_Block_Stones_Abstract
+ extends GT_Generic_Block
+ implements IOreRecipeRegistrator
+{
+ public GT_Block_Stones_Abstract(Class<? extends ItemBlock> aItemClass, String aName)
+ {
+ super(aItemClass, aName, Material.rock);
+ OrePrefixes.crafting.add(this);
+ setStepSound(soundTypeStone);
+ setCreativeTab(GregTech_API.TAB_GREGTECH_MATERIALS);
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 0), new ItemStack(this, 1, 7));
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 1), new ItemStack(this, 1, 0));
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 2), new ItemStack(this, 1, 0));
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 3), new ItemStack(this, 1, 0));
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 4), new ItemStack(this, 1, 0));
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 5), new ItemStack(this, 1, 0));
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 6), new ItemStack(this, 1, 0));
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 7), new ItemStack(this, 1, 0));
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 8), new ItemStack(this, 1, 15));
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 9), new ItemStack(this, 1, 8));
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 10), new ItemStack(this, 1, 8));
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 11), new ItemStack(this, 1, 8));
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 12), new ItemStack(this, 1, 8));
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 13), new ItemStack(this, 1, 8));
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 14), new ItemStack(this, 1, 8));
+ GT_ModHandler.addSmeltingRecipe(new ItemStack(this, 1, 15), new ItemStack(this, 1, 8));
+ GT_Values.RA.addAssemblerRecipe(new ItemStack(this, 1, 0), ItemList.Circuit_Integrated.getWithDamage(0L, 4L, new Object[0]), new ItemStack(this, 1, 3), 50, 4);
+ GT_Values.RA.addAssemblerRecipe(new ItemStack(this, 1, 8), ItemList.Circuit_Integrated.getWithDamage(0L, 4L, new Object[0]), new ItemStack(this, 1, 11), 50, 4);
+ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 1, 6), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "f", "X", Character.valueOf('X'), new ItemStack(this, 1, 7) });
+ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 1, 14), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "f", "X", Character.valueOf('X'), new ItemStack(this, 1, 15) });
+ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 1, 4), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "h", "X", Character.valueOf('X'), new ItemStack(this, 1, 3) });
+ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 1, 12), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "h", "X", Character.valueOf('X'), new ItemStack(this, 1, 11) });
+ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 1, 1), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "h", "X", Character.valueOf('X'), new ItemStack(this, 1, 0) });
+ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 1, 9), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "h", "X", Character.valueOf('X'), new ItemStack(this, 1, 8) });
+ GT_Values.RA.addForgeHammerRecipe(new ItemStack(this, 1, 3), new ItemStack(this, 1, 4), 16, 10);
+ GT_Values.RA.addForgeHammerRecipe(new ItemStack(this, 1, 11), new ItemStack(this, 1, 12), 16, 10);
+ GT_Values.RA.addForgeHammerRecipe(new ItemStack(this, 1, 0), new ItemStack(this, 1, 1), 16, 10);
+ GT_Values.RA.addForgeHammerRecipe(new ItemStack(this, 1, 8), new ItemStack(this, 1, 9), 16, 10);
+ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 4, 3), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "XX", "XX", Character.valueOf('X'), new ItemStack(this, 4, 0) });
+ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 4, 11), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "XX", "XX", Character.valueOf('X'), new ItemStack(this, 4, 8) });
+ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 4, 3), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "XX", "XX", Character.valueOf('X'), new ItemStack(this, 4, 7) });
+ GT_ModHandler.addCraftingRecipe(new ItemStack(this, 4, 11), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] { "XX", "XX", Character.valueOf('X'), new ItemStack(this, 4, 15) });
+ }
+
+ public void registerOre(OrePrefixes aPrefix, Materials aMaterial, String aOreDictName, String aModName, ItemStack aStack)
+ {
+ if (aOreDictName.equals(OreDictNames.craftingLensWhite.toString()))
+ {
+ GT_Values.RA.addLaserEngraverRecipe(new ItemStack(this, 1, 7), GT_Utility.copyAmount(0L, new Object[] { aStack }), new ItemStack(this, 1, 6), 50, 16);
+ GT_Values.RA.addLaserEngraverRecipe(new ItemStack(this, 1, 15), GT_Utility.copyAmount(0L, new Object[] { aStack }), new ItemStack(this, 1, 14), 50, 16);
+ }
+ }
+
+ public String getHarvestTool(int aMeta)
+ {
+ return "pickaxe";
+ }
+
+ public int getHarvestLevel(int aMeta)
+ {
+ return 1;
+ }
+
+ public float getBlockHardness(World aWorld, int aX, int aY, int aZ)
+ {
+ return this.blockHardness = Blocks.stone.getBlockHardness(aWorld, aX, aY, aZ) * 3.0F;
+ }
+
+ public String getUnlocalizedName()
+ {
+ return this.mUnlocalizedName;
+ }
+
+ public String getLocalizedName()
+ {
+ return StatCollector.translateToLocal(this.mUnlocalizedName + ".name");
+ }
+
+ public boolean canBeReplacedByLeaves(IBlockAccess aWorld, int aX, int aY, int aZ)
+ {
+ return false;
+ }
+
+ public boolean isNormalCube(IBlockAccess aWorld, int aX, int aY, int aZ)
+ {
+ return true;
+ }
+
+ public boolean renderAsNormalBlock()
+ {
+ return true;
+ }
+
+ public boolean isOpaqueCube()
+ {
+ return true;
+ }
+
+ public IIcon getIcon(int aSide, int aMeta)
+ {
+ if ((aMeta >= 0) && (aMeta < 16)) {
+ return gregtech.api.enums.Textures.BlockIcons.GRANITES[aMeta].getIcon();
+ }
+ return null;
+ }
+
+ public boolean canCreatureSpawn(EnumCreatureType type, IBlockAccess world, int x, int y, int z)
+ {
+ return world.getBlockMetadata(x, y, z) % 8 < 3;
+ }
+
+ public int damageDropped(int par1)
+ {
+ return par1 % 8 == 0 ? par1 + 1 : par1;
+ }
+
+ public int getDamageValue(World par1World, int par2, int par3, int par4)
+ {
+ return par1World.getBlockMetadata(par2, par3, par4);
+ }
+
+ public int quantityDropped(Random par1Random)
+ {
+ return 1;
+ }
+
+ public Item getItemDropped(int par1, Random par2Random, int par3)
+ {
+ return Item.getItemFromBlock(this);
+ }
+
+ @SideOnly(Side.CLIENT)
+ public void registerBlockIcons(IIconRegister aIconRegister) {}
+
+ @SideOnly(Side.CLIENT)
+ public void getSubBlocks(Item aItem, CreativeTabs par2CreativeTabs, List aList)
+ {
+ for (int i = 0; i < 16; i++) {
+ aList.add(new ItemStack(aItem, 1, i));
+ }
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Item_Casings1.java b/main/java/gregtech/common/blocks/GT_Item_Casings1.java index 7da8304775..3dc1dcb213 100644 --- a/main/java/gregtech/common/blocks/GT_Item_Casings1.java +++ b/main/java/gregtech/common/blocks/GT_Item_Casings1.java @@ -1,32 +1,32 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import java.util.List;
-/* 4: */ import net.minecraft.block.Block;
-/* 5: */ import net.minecraft.entity.player.EntityPlayer;
-/* 6: */ import net.minecraft.item.ItemStack;
-/* 7: */
-/* 8: */ public class GT_Item_Casings1
-/* 9: */ extends GT_Item_Casings_Abstract
-/* 10: */ {
-/* 11: */ public GT_Item_Casings1(Block par1)
-/* 12: */ {
-/* 13:11 */ super(par1);
-/* 14: */ }
-/* 15: */
-/* 16: */ public void addInformation(ItemStack aStack, EntityPlayer aPlayer, List aList, boolean aF3_H)
-/* 17: */ {
-/* 18:16 */ super.addInformation(aStack, aPlayer, aList, aF3_H);
-/* 19:17 */ switch (getDamage(aStack))
-/* 20: */ {
-/* 21: */ case 12:
-/* 22:18 */ aList.add(this.mCoil01Tooltip); break;
-/* 23: */ case 13:
-/* 24:19 */ aList.add(this.mCoil02Tooltip); break;
-/* 25: */ case 14:
-/* 26:20 */ aList.add(this.mCoil03Tooltip);
-/* 27: */ }
-/* 28: */ }
-/* 29: */ }
+package gregtech.common.blocks;
+
+import java.util.List;
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+
+public class GT_Item_Casings1
+ extends GT_Item_Casings_Abstract
+{
+ public GT_Item_Casings1(Block par1)
+ {
+ super(par1);
+ }
+
+ public void addInformation(ItemStack aStack, EntityPlayer aPlayer, List aList, boolean aF3_H)
+ {
+ super.addInformation(aStack, aPlayer, aList, aF3_H);
+ switch (getDamage(aStack))
+ {
+ case 12:
+ aList.add(this.mCoil01Tooltip); break;
+ case 13:
+ aList.add(this.mCoil02Tooltip); break;
+ case 14:
+ aList.add(this.mCoil03Tooltip);
+ }
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Item_Casings2.java b/main/java/gregtech/common/blocks/GT_Item_Casings2.java index 7f50676852..3ff52142ff 100644 --- a/main/java/gregtech/common/blocks/GT_Item_Casings2.java +++ b/main/java/gregtech/common/blocks/GT_Item_Casings2.java @@ -1,28 +1,28 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import java.util.List;
-/* 4: */ import net.minecraft.block.Block;
-/* 5: */ import net.minecraft.entity.player.EntityPlayer;
-/* 6: */ import net.minecraft.item.ItemStack;
-/* 7: */
-/* 8: */ public class GT_Item_Casings2
-/* 9: */ extends GT_Item_Casings_Abstract
-/* 10: */ {
-/* 11: */ public GT_Item_Casings2(Block par1)
-/* 12: */ {
-/* 13:11 */ super(par1);
-/* 14: */ }
-/* 15: */
-/* 16: */ public void addInformation(ItemStack aStack, EntityPlayer aPlayer, List aList, boolean aF3_H)
-/* 17: */ {
-/* 18:16 */ super.addInformation(aStack, aPlayer, aList, aF3_H);
-/* 19:17 */ switch (getDamage(aStack))
-/* 20: */ {
-/* 21: */ case 8:
-/* 22:18 */ aList.add(this.mBlastProofTooltip);
-/* 23: */ }
-/* 24: */ }
-/* 25: */ }
+package gregtech.common.blocks;
+
+import java.util.List;
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+
+public class GT_Item_Casings2
+ extends GT_Item_Casings_Abstract
+{
+ public GT_Item_Casings2(Block par1)
+ {
+ super(par1);
+ }
+
+ public void addInformation(ItemStack aStack, EntityPlayer aPlayer, List aList, boolean aF3_H)
+ {
+ super.addInformation(aStack, aPlayer, aList, aF3_H);
+ switch (getDamage(aStack))
+ {
+ case 8:
+ aList.add(this.mBlastProofTooltip);
+ }
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Item_Casings3.java b/main/java/gregtech/common/blocks/GT_Item_Casings3.java index b12daf4fc2..da2d8eda09 100644 --- a/main/java/gregtech/common/blocks/GT_Item_Casings3.java +++ b/main/java/gregtech/common/blocks/GT_Item_Casings3.java @@ -1,15 +1,15 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import net.minecraft.block.Block;
-/* 4: */
-/* 5: */ public class GT_Item_Casings3
-/* 6: */ extends GT_Item_Casings_Abstract
-/* 7: */ {
-/* 8: */ public GT_Item_Casings3(Block par1)
-/* 9: */ {
-/* ::7 */ super(par1);
-/* ;: */ }
-/* <: */ }
+package gregtech.common.blocks;
+
+import net.minecraft.block.Block;
+
+public class GT_Item_Casings3
+ extends GT_Item_Casings_Abstract
+{
+ public GT_Item_Casings3(Block par1)
+ {
+ super(par1);
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Item_Casings4.java b/main/java/gregtech/common/blocks/GT_Item_Casings4.java index d7a7f596d0..f3135b5a89 100644 --- a/main/java/gregtech/common/blocks/GT_Item_Casings4.java +++ b/main/java/gregtech/common/blocks/GT_Item_Casings4.java @@ -1,15 +1,15 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import net.minecraft.block.Block;
-/* 4: */
-/* 5: */ public class GT_Item_Casings4
-/* 6: */ extends GT_Item_Casings_Abstract
-/* 7: */ {
-/* 8: */ public GT_Item_Casings4(Block par1)
-/* 9: */ {
-/* ::7 */ super(par1);
-/* ;: */ }
-/* <: */ }
+package gregtech.common.blocks;
+
+import net.minecraft.block.Block;
+
+public class GT_Item_Casings4
+ extends GT_Item_Casings_Abstract
+{
+ public GT_Item_Casings4(Block par1)
+ {
+ super(par1);
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Item_Casings_Abstract.java b/main/java/gregtech/common/blocks/GT_Item_Casings_Abstract.java index 26a7df8a03..b3ed47ab86 100644 --- a/main/java/gregtech/common/blocks/GT_Item_Casings_Abstract.java +++ b/main/java/gregtech/common/blocks/GT_Item_Casings_Abstract.java @@ -1,48 +1,48 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import gregtech.api.GregTech_API;
-/* 4: */ import gregtech.api.util.GT_LanguageManager;
-/* 5: */ import java.util.List;
-/* 6: */ import net.minecraft.block.Block;
-/* 7: */ import net.minecraft.entity.player.EntityPlayer;
-/* 8: */ import net.minecraft.item.ItemBlock;
-/* 9: */ import net.minecraft.item.ItemStack;
-/* 10: */
-/* 11: */ public abstract class GT_Item_Casings_Abstract
-/* 12: */ extends ItemBlock
-/* 13: */ {
-/* 14: */ public GT_Item_Casings_Abstract(Block par1)
-/* 15: */ {
-/* 16:15 */ super(par1);
-/* 17:16 */ setMaxDamage(0);
-/* 18:17 */ setHasSubtypes(true);
-/* 19:18 */ setCreativeTab(GregTech_API.TAB_GREGTECH_MATERIALS);
-/* 20: */ }
-/* 21: */
-/* 22: */ public int getMetadata(int aMeta)
-/* 23: */ {
-/* 24:23 */ return aMeta;
-/* 25: */ }
-/* 26: */
-/* 27:26 */ protected final String mNoMobsToolTip = GT_LanguageManager.addStringLocalization("gt.nomobspawnsonthisblock", "Mobs cannot Spawn on this Block");
-/* 28:27 */ protected final String mNoTileEntityToolTip = GT_LanguageManager.addStringLocalization("gt.notileentityinthisblock", "This is NOT a TileEntity!");
-/* 29:28 */ protected final String mCoil01Tooltip = GT_LanguageManager.addStringLocalization("gt.coil01tooltip", "Base Heating Capacity = 1800 Kelvin");
-/* 30:29 */ protected final String mCoil02Tooltip = GT_LanguageManager.addStringLocalization("gt.coil02tooltip", "Base Heating Capacity = 2700 Kelvin");
-/* 31:30 */ protected final String mCoil03Tooltip = GT_LanguageManager.addStringLocalization("gt.coil03tooltip", "Base Heating Capacity = 3600 Kelvin");
-/* 32:31 */ protected final String mBlastProofTooltip = GT_LanguageManager.addStringLocalization("gt.blastprooftooltip", "This Block is Blast Proof");
-/* 33: */
-/* 34: */ public String getUnlocalizedName(ItemStack aStack)
-/* 35: */ {
-/* 36:35 */ return this.field_150939_a.getUnlocalizedName() + "." + getDamage(aStack);
-/* 37: */ }
-/* 38: */
-/* 39: */ public void addInformation(ItemStack aStack, EntityPlayer aPlayer, List aList, boolean aF3_H)
-/* 40: */ {
-/* 41:40 */ super.addInformation(aStack, aPlayer, aList, aF3_H);
-/* 42:41 */ aList.add(this.mNoMobsToolTip);
-/* 43:42 */ aList.add(this.mNoTileEntityToolTip);
-/* 44: */ }
-/* 45: */ }
+package gregtech.common.blocks;
+
+import gregtech.api.GregTech_API;
+import gregtech.api.util.GT_LanguageManager;
+import java.util.List;
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemBlock;
+import net.minecraft.item.ItemStack;
+
+public abstract class GT_Item_Casings_Abstract
+ extends ItemBlock
+{
+ public GT_Item_Casings_Abstract(Block par1)
+ {
+ super(par1);
+ setMaxDamage(0);
+ setHasSubtypes(true);
+ setCreativeTab(GregTech_API.TAB_GREGTECH_MATERIALS);
+ }
+
+ public int getMetadata(int aMeta)
+ {
+ return aMeta;
+ }
+
+ protected final String mNoMobsToolTip = GT_LanguageManager.addStringLocalization("gt.nomobspawnsonthisblock", "Mobs cannot Spawn on this Block");
+ protected final String mNoTileEntityToolTip = GT_LanguageManager.addStringLocalization("gt.notileentityinthisblock", "This is NOT a TileEntity!");
+ 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 mBlastProofTooltip = GT_LanguageManager.addStringLocalization("gt.blastprooftooltip", "This Block is Blast Proof");
+
+ public String getUnlocalizedName(ItemStack aStack)
+ {
+ return this.field_150939_a.getUnlocalizedName() + "." + getDamage(aStack);
+ }
+
+ public void addInformation(ItemStack aStack, EntityPlayer aPlayer, List aList, boolean aF3_H)
+ {
+ super.addInformation(aStack, aPlayer, aList, aF3_H);
+ aList.add(this.mNoMobsToolTip);
+ aList.add(this.mNoTileEntityToolTip);
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Item_Concretes.java b/main/java/gregtech/common/blocks/GT_Item_Concretes.java index 37b3fe3d82..0034859c63 100644 --- a/main/java/gregtech/common/blocks/GT_Item_Concretes.java +++ b/main/java/gregtech/common/blocks/GT_Item_Concretes.java @@ -1,27 +1,27 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import gregtech.api.util.GT_LanguageManager;
-/* 4: */ import java.util.List;
-/* 5: */ import net.minecraft.block.Block;
-/* 6: */ import net.minecraft.entity.player.EntityPlayer;
-/* 7: */ import net.minecraft.item.ItemStack;
-/* 8: */
-/* 9: */ public class GT_Item_Concretes
-/* 10: */ extends GT_Item_Stones_Abstract
-/* 11: */ {
-/* 12: */ public GT_Item_Concretes(Block par1)
-/* 13: */ {
-/* 14:13 */ super(par1);
-/* 15: */ }
-/* 16: */
-/* 17:16 */ private final String mRunFasterToolTip = GT_LanguageManager.addStringLocalization("gt.runfastertooltip", "You can walk faster on this Block");
-/* 18: */
-/* 19: */ public void addInformation(ItemStack aStack, EntityPlayer aPlayer, List aList, boolean aF3_H)
-/* 20: */ {
-/* 21:20 */ super.addInformation(aStack, aPlayer, aList, aF3_H);
-/* 22:21 */ aList.add(this.mRunFasterToolTip);
-/* 23: */ }
-/* 24: */ }
+package gregtech.common.blocks;
+
+import gregtech.api.util.GT_LanguageManager;
+import java.util.List;
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+
+public class GT_Item_Concretes
+ extends GT_Item_Stones_Abstract
+{
+ public GT_Item_Concretes(Block par1)
+ {
+ super(par1);
+ }
+
+ private final String mRunFasterToolTip = GT_LanguageManager.addStringLocalization("gt.runfastertooltip", "You can walk faster on this Block");
+
+ public void addInformation(ItemStack aStack, EntityPlayer aPlayer, List aList, boolean aF3_H)
+ {
+ super.addInformation(aStack, aPlayer, aList, aF3_H);
+ aList.add(this.mRunFasterToolTip);
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Item_Granites.java b/main/java/gregtech/common/blocks/GT_Item_Granites.java index e026edbe6f..4604d07740 100644 --- a/main/java/gregtech/common/blocks/GT_Item_Granites.java +++ b/main/java/gregtech/common/blocks/GT_Item_Granites.java @@ -1,15 +1,15 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import net.minecraft.block.Block;
-/* 4: */
-/* 5: */ public class GT_Item_Granites
-/* 6: */ extends GT_Item_Stones_Abstract
-/* 7: */ {
-/* 8: */ public GT_Item_Granites(Block par1)
-/* 9: */ {
-/* ::7 */ super(par1);
-/* ;: */ }
-/* <: */ }
+package gregtech.common.blocks;
+
+import net.minecraft.block.Block;
+
+public class GT_Item_Granites
+ extends GT_Item_Stones_Abstract
+{
+ public GT_Item_Granites(Block par1)
+ {
+ super(par1);
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Item_Machines.java b/main/java/gregtech/common/blocks/GT_Item_Machines.java index 36c7482f64..ba9bb6152b 100644 --- a/main/java/gregtech/common/blocks/GT_Item_Machines.java +++ b/main/java/gregtech/common/blocks/GT_Item_Machines.java @@ -1,169 +1,169 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import gregtech.api.GregTech_API;
-/* 4: */ import gregtech.api.enums.GT_Values;
-/* 5: */ import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
-/* 6: */ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-/* 7: */ import gregtech.api.util.GT_ItsNotMyFaultException;
-/* 8: */ import gregtech.api.util.GT_LanguageManager;
-/* 9: */ import gregtech.api.util.GT_Log;
-/* 10: */ import gregtech.api.util.GT_Utility;
-/* 11: */ import java.util.List;
-/* 12: */ import net.minecraft.block.Block;
-/* 13: */ import net.minecraft.entity.player.EntityPlayer;
-/* 14: */ import net.minecraft.item.ItemBlock;
-/* 15: */ import net.minecraft.item.ItemStack;
-/* 16: */ import net.minecraft.nbt.NBTTagCompound;
-/* 17: */ import net.minecraft.tileentity.TileEntity;
-/* 18: */ import net.minecraft.util.EnumChatFormatting;
-/* 19: */ import net.minecraft.world.World;
-/* 20: */
-/* 21: */ public class GT_Item_Machines
-/* 22: */ extends ItemBlock
-/* 23: */ {
-/* 24: */ public GT_Item_Machines(Block par1)
-/* 25: */ {
-/* 26: 25 */ super(par1);
-/* 27: 26 */ setMaxDamage(0);
-/* 28: 27 */ setHasSubtypes(true);
-/* 29: 28 */ setCreativeTab(GregTech_API.TAB_GREGTECH);
-/* 30: */ }
-/* 31: */
-/* 32: */ public void addInformation(ItemStack aStack, EntityPlayer aPlayer, List aList, boolean par4)
-/* 33: */ {
-/* 34: */ try
-/* 35: */ {
-/* 36: 34 */ int tDamage = getDamage(aStack);
-/* 37: 36 */ if ((tDamage <= 0) || (tDamage >= GregTech_API.METATILEENTITIES.length)) {
-/* 38: 36 */ return;
-/* 39: */ }
-/* 40: 38 */ if (tDamage == 0)
-/* 41: */ {
-/* 42: 39 */ aList.add("WARNING, THE EXISTENCE OF THIS ITEM IS A BUG");
-/* 43: 40 */ aList.add("IF YOU GOT IT IN SURVIVAL THEN PLEASE REPORT IT");
-/* 44: */ }
-/* 45: */ else
-/* 46: */ {
-/* 47: 42 */ TileEntity temp = GregTech_API.sBlockMachines.createTileEntity(aPlayer == null ? GT_Values.DW : aPlayer.worldObj, GregTech_API.METATILEENTITIES[tDamage] == null ? 0 : GregTech_API.METATILEENTITIES[tDamage].getTileEntityBaseType());
-/* 48: 43 */ if (temp != null)
-/* 49: */ {
-/* 50: 44 */ temp.setWorldObj(aPlayer == null ? GT_Values.DW : aPlayer.worldObj);temp.xCoord = 0;temp.yCoord = 0;temp.zCoord = 0;
-/* 51: 45 */ if ((temp instanceof IGregTechTileEntity))
-/* 52: */ {
-/* 53: 46 */ IGregTechTileEntity tTileEntity = (IGregTechTileEntity)temp;
-/* 54: 47 */ tTileEntity.setInitialValuesAsNBT(new NBTTagCompound(), (short)tDamage);
-/* 55: 48 */ if (tTileEntity.getDescription() != null)
-/* 56: */ {
-/* 57: 48 */ int i = 0;
-/* 58: 48 */ for (String tDescription : tTileEntity.getDescription()) {
-/* 59: 48 */ if (GT_Utility.isStringValid(tDescription)) {
-/* 60: 48 */ aList.add(GT_LanguageManager.addStringLocalization("TileEntity_DESCRIPTION_" + tDamage + "_Index_" + i++, tDescription, !GregTech_API.sPostloadFinished));
-/* 61: */ }
-/* 62: */ }
-/* 63: */ }
-/* 64: 49 */ if (tTileEntity.getEUCapacity() > 0L)
-/* 65: */ {
-/* 66: 50 */ if (tTileEntity.getInputVoltage() > 0L) {
-/* 67: 50 */ aList.add(GT_LanguageManager.addStringLocalization("TileEntity_EUp_IN", "Voltage IN: ", !GregTech_API.sPostloadFinished) + EnumChatFormatting.GREEN + tTileEntity.getInputVoltage() + " (" + GT_Values.VN[GT_Utility.getTier(tTileEntity.getInputVoltage())] + ")" + EnumChatFormatting.GRAY);
-/* 68: */ }
-/* 69: 51 */ if (tTileEntity.getOutputVoltage() > 0L) {
-/* 70: 51 */ aList.add(GT_LanguageManager.addStringLocalization("TileEntity_EUp_OUT", "Voltage OUT: ", !GregTech_API.sPostloadFinished) + EnumChatFormatting.GREEN + tTileEntity.getOutputVoltage() + " (" + GT_Values.VN[GT_Utility.getTier(tTileEntity.getOutputVoltage())] + ")" + EnumChatFormatting.GRAY);
-/* 71: */ }
-/* 72: 52 */ if (tTileEntity.getOutputAmperage() > 1L) {
-/* 73: 52 */ aList.add(GT_LanguageManager.addStringLocalization("TileEntity_EUp_AMOUNT", "Amperage: ", !GregTech_API.sPostloadFinished) + EnumChatFormatting.YELLOW + tTileEntity.getOutputAmperage() + EnumChatFormatting.GRAY);
-/* 74: */ }
-/* 75: 53 */ aList.add(GT_LanguageManager.addStringLocalization("TileEntity_EUp_STORE", "Capacity: ", !GregTech_API.sPostloadFinished) + EnumChatFormatting.BLUE + tTileEntity.getEUCapacity() + EnumChatFormatting.GRAY);
-/* 76: */ }
-/* 77: */ }
-/* 78: */ }
-/* 79: */ }
-/* 80: 59 */ NBTTagCompound aNBT = aStack.getTagCompound();
-/* 81: 61 */ if (aNBT != null)
-/* 82: */ {
-/* 83: 62 */ if (aNBT.getBoolean("mMuffler")) {
-/* 84: 62 */ aList.add(GT_LanguageManager.addStringLocalization("GT_TileEntity_MUFFLER", "has Muffler Upgrade", !GregTech_API.sPostloadFinished));
-/* 85: */ }
-/* 86: 63 */ if (aNBT.getBoolean("mSteamConverter")) {
-/* 87: 63 */ aList.add(GT_LanguageManager.addStringLocalization("GT_TileEntity_STEAMCONVERTER", "has Steam Upgrade", !GregTech_API.sPostloadFinished));
-/* 88: */ }
-/* 89: 64 */ int tAmount = 0;
-/* 90: 65 */ if ((tAmount = aNBT.getByte("mSteamTanks")) > 0) {
-/* 91: 65 */ aList.add(tAmount + " " + GT_LanguageManager.addStringLocalization("GT_TileEntity_STEAMTANKS", "Steam Tank Upgrades", !GregTech_API.sPostloadFinished));
-/* 92: */ }
-/* 93: */ }
-/* 94: */ }
-/* 95: */ catch (Throwable e)
-/* 96: */ {
-/* 97: 68 */ e.printStackTrace(GT_Log.err);
-/* 98: */ }
-/* 99: */ }
-/* 100: */
-/* 101: */ public boolean onItemUseFirst(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side, float hitX, float hitY, float hitZ)
-/* 102: */ {
-/* 103: 74 */ return false;
-/* 104: */ }
-/* 105: */
-/* 106: */ public String getUnlocalizedName(ItemStack aStack)
-/* 107: */ {
-/* 108: 79 */ short tDamage = (short)getDamage(aStack);
-/* 109: 80 */ if ((tDamage < 0) || (tDamage >= GregTech_API.METATILEENTITIES.length)) {
-/* 110: 80 */ return "";
-/* 111: */ }
-/* 112: 81 */ if (GregTech_API.METATILEENTITIES[tDamage] != null) {
-/* 113: 82 */ return getUnlocalizedName() + "." + GregTech_API.METATILEENTITIES[tDamage].getMetaName();
-/* 114: */ }
-/* 115: 84 */ return "";
-/* 116: */ }
-/* 117: */
-/* 118: */ public void onCreated(ItemStack aStack, World aWorld, EntityPlayer aPlayer)
-/* 119: */ {
-/* 120: 89 */ super.onCreated(aStack, aWorld, aPlayer);
-/* 121: 90 */ short tDamage = (short)getDamage(aStack);
-/* 122: 91 */ if ((tDamage < 0) || ((tDamage >= GregTech_API.METATILEENTITIES.length) && (GregTech_API.METATILEENTITIES[tDamage] != null))) {
-/* 123: 91 */ GregTech_API.METATILEENTITIES[tDamage].onCreated(aStack, aWorld, aPlayer);
-/* 124: */ }
-/* 125: */ }
-/* 126: */
-/* 127: */ public boolean placeBlockAt(ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX, int aY, int aZ, int side, float hitX, float hitY, float hitZ, int aMeta)
-/* 128: */ {
-/* 129: 96 */ short tDamage = (short)getDamage(aStack);
-/* 130: 97 */ if (tDamage > 0)
-/* 131: */ {
-/* 132: 98 */ if (GregTech_API.METATILEENTITIES[tDamage] == null) {
-/* 133: 98 */ return false;
-/* 134: */ }
-/* 135: 99 */ int tMetaData = GregTech_API.METATILEENTITIES[tDamage].getTileEntityBaseType();
-/* 136:100 */ if (!aWorld.setBlock(aX, aY, aZ, this.field_150939_a, tMetaData, 3)) {
-/* 137:100 */ return false;
-/* 138: */ }
-/* 139:101 */ if (aWorld.getBlock(aX, aY, aZ) != this.field_150939_a) {
-/* 140:101 */ throw new GT_ItsNotMyFaultException("Failed to place Block even though World.setBlock returned true. It COULD be MCPC/Bukkit causing that. In case you really have that installed, don't report this Bug to me, I don't know how to fix it.");
-/* 141: */ }
-/* 142:102 */ if (aWorld.getBlockMetadata(aX, aY, aZ) != tMetaData) {
-/* 143:102 */ throw new GT_ItsNotMyFaultException("Failed to set the MetaValue of the Block even though World.setBlock returned true. It COULD be MCPC/Bukkit causing that. In case you really have that installed, don't report this Bug to me, I don't know how to fix it.");
-/* 144: */ }
-/* 145:103 */ IGregTechTileEntity tTileEntity = (IGregTechTileEntity)aWorld.getTileEntity(aX, aY, aZ);
-/* 146:104 */ if (tTileEntity != null)
-/* 147: */ {
-/* 148:105 */ tTileEntity.setInitialValuesAsNBT(tTileEntity.isServerSide() ? aStack.getTagCompound() : null, tDamage);
-/* 149:106 */ if (aPlayer != null) {
-/* 150:106 */ tTileEntity.setOwnerName(aPlayer.getDisplayName());
-/* 151: */ }
-/* 152:107 */ tTileEntity.getMetaTileEntity().initDefaultModes(aStack.getTagCompound());
-/* 153: */ }
-/* 154: */ }
-/* 155:110 */ else if (!aWorld.setBlock(aX, aY, aZ, this.field_150939_a, tDamage, 3))
-/* 156: */ {
-/* 157:110 */ return false;
-/* 158: */ }
-/* 159:113 */ if (aWorld.getBlock(aX, aY, aZ) == this.field_150939_a)
-/* 160: */ {
-/* 161:114 */ this.field_150939_a.onBlockPlacedBy(aWorld, aX, aY, aZ, aPlayer, aStack);
-/* 162:115 */ this.field_150939_a.onPostBlockPlaced(aWorld, aX, aY, aZ, tDamage);
-/* 163: */ }
-/* 164:117 */ return true;
-/* 165: */ }
-/* 166: */ }
+package gregtech.common.blocks;
+
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.GT_Values;
+import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.util.GT_ItsNotMyFaultException;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_Log;
+import gregtech.api.util.GT_Utility;
+import java.util.List;
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemBlock;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.world.World;
+
+public class GT_Item_Machines
+ extends ItemBlock
+{
+ public GT_Item_Machines(Block par1)
+ {
+ super(par1);
+ setMaxDamage(0);
+ setHasSubtypes(true);
+ setCreativeTab(GregTech_API.TAB_GREGTECH);
+ }
+
+ public void addInformation(ItemStack aStack, EntityPlayer aPlayer, List aList, boolean par4)
+ {
+ try
+ {
+ int tDamage = getDamage(aStack);
+ if ((tDamage <= 0) || (tDamage >= GregTech_API.METATILEENTITIES.length)) {
+ return;
+ }
+ if (tDamage == 0)
+ {
+ aList.add("WARNING, THE EXISTENCE OF THIS ITEM IS A BUG");
+ aList.add("IF YOU GOT IT IN SURVIVAL THEN PLEASE REPORT IT");
+ }
+ else
+ {
+ TileEntity temp = GregTech_API.sBlockMachines.createTileEntity(aPlayer == null ? GT_Values.DW : aPlayer.worldObj, GregTech_API.METATILEENTITIES[tDamage] == null ? 0 : GregTech_API.METATILEENTITIES[tDamage].getTileEntityBaseType());
+ if (temp != null)
+ {
+ temp.setWorldObj(aPlayer == null ? GT_Values.DW : aPlayer.worldObj);temp.xCoord = 0;temp.yCoord = 0;temp.zCoord = 0;
+ if ((temp instanceof IGregTechTileEntity))
+ {
+ IGregTechTileEntity tTileEntity = (IGregTechTileEntity)temp;
+ tTileEntity.setInitialValuesAsNBT(new NBTTagCompound(), (short)tDamage);
+ if (tTileEntity.getDescription() != null)
+ {
+ int i = 0;
+ for (String tDescription : tTileEntity.getDescription()) {
+ if (GT_Utility.isStringValid(tDescription)) {
+ aList.add(GT_LanguageManager.addStringLocalization("TileEntity_DESCRIPTION_" + tDamage + "_Index_" + i++, tDescription, !GregTech_API.sPostloadFinished));
+ }
+ }
+ }
+ if (tTileEntity.getEUCapacity() > 0L)
+ {
+ if (tTileEntity.getInputVoltage() > 0L) {
+ aList.add(GT_LanguageManager.addStringLocalization("TileEntity_EUp_IN", "Voltage IN: ", !GregTech_API.sPostloadFinished) + EnumChatFormatting.GREEN + tTileEntity.getInputVoltage() + " (" + GT_Values.VN[GT_Utility.getTier(tTileEntity.getInputVoltage())] + ")" + EnumChatFormatting.GRAY);
+ }
+ if (tTileEntity.getOutputVoltage() > 0L) {
+ aList.add(GT_LanguageManager.addStringLocalization("TileEntity_EUp_OUT", "Voltage OUT: ", !GregTech_API.sPostloadFinished) + EnumChatFormatting.GREEN + tTileEntity.getOutputVoltage() + " (" + GT_Values.VN[GT_Utility.getTier(tTileEntity.getOutputVoltage())] + ")" + EnumChatFormatting.GRAY);
+ }
+ if (tTileEntity.getOutputAmperage() > 1L) {
+ aList.add(GT_LanguageManager.addStringLocalization("TileEntity_EUp_AMOUNT", "Amperage: ", !GregTech_API.sPostloadFinished) + EnumChatFormatting.YELLOW + tTileEntity.getOutputAmperage() + EnumChatFormatting.GRAY);
+ }
+ aList.add(GT_LanguageManager.addStringLocalization("TileEntity_EUp_STORE", "Capacity: ", !GregTech_API.sPostloadFinished) + EnumChatFormatting.BLUE + tTileEntity.getEUCapacity() + EnumChatFormatting.GRAY);
+ }
+ }
+ }
+ }
+ NBTTagCompound aNBT = aStack.getTagCompound();
+ if (aNBT != null)
+ {
+ if (aNBT.getBoolean("mMuffler")) {
+ aList.add(GT_LanguageManager.addStringLocalization("GT_TileEntity_MUFFLER", "has Muffler Upgrade", !GregTech_API.sPostloadFinished));
+ }
+ if (aNBT.getBoolean("mSteamConverter")) {
+ aList.add(GT_LanguageManager.addStringLocalization("GT_TileEntity_STEAMCONVERTER", "has Steam Upgrade", !GregTech_API.sPostloadFinished));
+ }
+ int tAmount = 0;
+ if ((tAmount = aNBT.getByte("mSteamTanks")) > 0) {
+ aList.add(tAmount + " " + GT_LanguageManager.addStringLocalization("GT_TileEntity_STEAMTANKS", "Steam Tank Upgrades", !GregTech_API.sPostloadFinished));
+ }
+ }
+ }
+ catch (Throwable e)
+ {
+ e.printStackTrace(GT_Log.err);
+ }
+ }
+
+ public boolean onItemUseFirst(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side, float hitX, float hitY, float hitZ)
+ {
+ return false;
+ }
+
+ public String getUnlocalizedName(ItemStack aStack)
+ {
+ short tDamage = (short)getDamage(aStack);
+ if ((tDamage < 0) || (tDamage >= GregTech_API.METATILEENTITIES.length)) {
+ return "";
+ }
+ if (GregTech_API.METATILEENTITIES[tDamage] != null) {
+ return getUnlocalizedName() + "." + GregTech_API.METATILEENTITIES[tDamage].getMetaName();
+ }
+ return "";
+ }
+
+ public void onCreated(ItemStack aStack, World aWorld, EntityPlayer aPlayer)
+ {
+ super.onCreated(aStack, aWorld, aPlayer);
+ short tDamage = (short)getDamage(aStack);
+ if ((tDamage < 0) || ((tDamage >= GregTech_API.METATILEENTITIES.length) && (GregTech_API.METATILEENTITIES[tDamage] != null))) {
+ GregTech_API.METATILEENTITIES[tDamage].onCreated(aStack, aWorld, aPlayer);
+ }
+ }
+
+ public boolean placeBlockAt(ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX, int aY, int aZ, int side, float hitX, float hitY, float hitZ, int aMeta)
+ {
+ short tDamage = (short)getDamage(aStack);
+ if (tDamage > 0)
+ {
+ if (GregTech_API.METATILEENTITIES[tDamage] == null) {
+ return false;
+ }
+ int tMetaData = GregTech_API.METATILEENTITIES[tDamage].getTileEntityBaseType();
+ if (!aWorld.setBlock(aX, aY, aZ, this.field_150939_a, tMetaData, 3)) {
+ return false;
+ }
+ if (aWorld.getBlock(aX, aY, aZ) != this.field_150939_a) {
+ throw new GT_ItsNotMyFaultException("Failed to place Block even though World.setBlock returned true. It COULD be MCPC/Bukkit causing that. In case you really have that installed, don't report this Bug to me, I don't know how to fix it.");
+ }
+ if (aWorld.getBlockMetadata(aX, aY, aZ) != tMetaData) {
+ throw new GT_ItsNotMyFaultException("Failed to set the MetaValue of the Block even though World.setBlock returned true. It COULD be MCPC/Bukkit causing that. In case you really have that installed, don't report this Bug to me, I don't know how to fix it.");
+ }
+ IGregTechTileEntity tTileEntity = (IGregTechTileEntity)aWorld.getTileEntity(aX, aY, aZ);
+ if (tTileEntity != null)
+ {
+ tTileEntity.setInitialValuesAsNBT(tTileEntity.isServerSide() ? aStack.getTagCompound() : null, tDamage);
+ if (aPlayer != null) {
+ tTileEntity.setOwnerName(aPlayer.getDisplayName());
+ }
+ tTileEntity.getMetaTileEntity().initDefaultModes(aStack.getTagCompound());
+ }
+ }
+ else if (!aWorld.setBlock(aX, aY, aZ, this.field_150939_a, tDamage, 3))
+ {
+ return false;
+ }
+ if (aWorld.getBlock(aX, aY, aZ) == this.field_150939_a)
+ {
+ this.field_150939_a.onBlockPlacedBy(aWorld, aX, aY, aZ, aPlayer, aStack);
+ this.field_150939_a.onPostBlockPlaced(aWorld, aX, aY, aZ, tDamage);
+ }
+ return true;
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Item_Ores.java b/main/java/gregtech/common/blocks/GT_Item_Ores.java index 4be045ee43..38b9b2fb69 100644 --- a/main/java/gregtech/common/blocks/GT_Item_Ores.java +++ b/main/java/gregtech/common/blocks/GT_Item_Ores.java @@ -1,57 +1,57 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import gregtech.api.GregTech_API;
-/* 4: */ import net.minecraft.block.Block;
-/* 5: */ import net.minecraft.entity.player.EntityPlayer;
-/* 6: */ import net.minecraft.item.ItemBlock;
-/* 7: */ import net.minecraft.item.ItemStack;
-/* 8: */ import net.minecraft.world.World;
-/* 9: */
-/* 10: */ public class GT_Item_Ores
-/* 11: */ extends ItemBlock
-/* 12: */ {
-/* 13: */ public GT_Item_Ores(Block par1)
-/* 14: */ {
-/* 15:12 */ super(par1);
-/* 16:13 */ setMaxDamage(0);
-/* 17:14 */ setHasSubtypes(true);
-/* 18:15 */ setCreativeTab(GregTech_API.TAB_GREGTECH_MATERIALS);
-/* 19: */ }
-/* 20: */
-/* 21: */ public boolean onItemUseFirst(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side, float hitX, float hitY, float hitZ)
-/* 22: */ {
-/* 23:20 */ return false;
-/* 24: */ }
-/* 25: */
-/* 26: */ public String getUnlocalizedName(ItemStack aStack)
-/* 27: */ {
-/* 28:25 */ return this.field_150939_a.getUnlocalizedName() + "." + getDamage(aStack);
-/* 29: */ }
-/* 30: */
-/* 31: */ public boolean placeBlockAt(ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX, int aY, int aZ, int side, float hitX, float hitY, float hitZ, int aMeta)
-/* 32: */ {
-/* 33:30 */ short tDamage = (short)getDamage(aStack);
-/* 34:31 */ if (tDamage > 0)
-/* 35: */ {
-/* 36:32 */ if (!aWorld.setBlock(aX, aY, aZ, this.field_150939_a, GT_TileEntity_Ores.getHarvestData(tDamage), 3)) {
-/* 37:32 */ return false;
-/* 38: */ }
-/* 39:33 */ GT_TileEntity_Ores tTileEntity = (GT_TileEntity_Ores)aWorld.getTileEntity(aX, aY, aZ);
-/* 40:34 */ tTileEntity.mMetaData = tDamage;
-/* 41:35 */ tTileEntity.mNatural = false;
-/* 42: */ }
-/* 43:37 */ else if (!aWorld.setBlock(aX, aY, aZ, this.field_150939_a, 0, 3))
-/* 44: */ {
-/* 45:37 */ return false;
-/* 46: */ }
-/* 47:40 */ if (aWorld.getBlock(aX, aY, aZ) == this.field_150939_a)
-/* 48: */ {
-/* 49:41 */ this.field_150939_a.onBlockPlacedBy(aWorld, aX, aY, aZ, aPlayer, aStack);
-/* 50:42 */ this.field_150939_a.onPostBlockPlaced(aWorld, aX, aY, aZ, tDamage);
-/* 51: */ }
-/* 52:44 */ return true;
-/* 53: */ }
-/* 54: */ }
+package gregtech.common.blocks;
+
+import gregtech.api.GregTech_API;
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemBlock;
+import net.minecraft.item.ItemStack;
+import net.minecraft.world.World;
+
+public class GT_Item_Ores
+ extends ItemBlock
+{
+ public GT_Item_Ores(Block par1)
+ {
+ super(par1);
+ setMaxDamage(0);
+ setHasSubtypes(true);
+ setCreativeTab(GregTech_API.TAB_GREGTECH_MATERIALS);
+ }
+
+ public boolean onItemUseFirst(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side, float hitX, float hitY, float hitZ)
+ {
+ return false;
+ }
+
+ public String getUnlocalizedName(ItemStack aStack)
+ {
+ return this.field_150939_a.getUnlocalizedName() + "." + getDamage(aStack);
+ }
+
+ public boolean placeBlockAt(ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX, int aY, int aZ, int side, float hitX, float hitY, float hitZ, int aMeta)
+ {
+ short tDamage = (short)getDamage(aStack);
+ if (tDamage > 0)
+ {
+ if (!aWorld.setBlock(aX, aY, aZ, this.field_150939_a, GT_TileEntity_Ores.getHarvestData(tDamage), 3)) {
+ return false;
+ }
+ GT_TileEntity_Ores tTileEntity = (GT_TileEntity_Ores)aWorld.getTileEntity(aX, aY, aZ);
+ tTileEntity.mMetaData = tDamage;
+ tTileEntity.mNatural = false;
+ }
+ else if (!aWorld.setBlock(aX, aY, aZ, this.field_150939_a, 0, 3))
+ {
+ return false;
+ }
+ if (aWorld.getBlock(aX, aY, aZ) == this.field_150939_a)
+ {
+ this.field_150939_a.onBlockPlacedBy(aWorld, aX, aY, aZ, aPlayer, aStack);
+ this.field_150939_a.onPostBlockPlaced(aWorld, aX, aY, aZ, tDamage);
+ }
+ return true;
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Item_Stones_Abstract.java b/main/java/gregtech/common/blocks/GT_Item_Stones_Abstract.java index b858a8a53e..7a1dbdaee1 100644 --- a/main/java/gregtech/common/blocks/GT_Item_Stones_Abstract.java +++ b/main/java/gregtech/common/blocks/GT_Item_Stones_Abstract.java @@ -1,44 +1,44 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import gregtech.api.GregTech_API;
-/* 4: */ import gregtech.api.util.GT_LanguageManager;
-/* 5: */ import java.util.List;
-/* 6: */ import net.minecraft.block.Block;
-/* 7: */ import net.minecraft.entity.player.EntityPlayer;
-/* 8: */ import net.minecraft.item.ItemBlock;
-/* 9: */ import net.minecraft.item.ItemStack;
-/* 10: */
-/* 11: */ public class GT_Item_Stones_Abstract
-/* 12: */ extends ItemBlock
-/* 13: */ {
-/* 14: */ public GT_Item_Stones_Abstract(Block par1)
-/* 15: */ {
-/* 16:15 */ super(par1);
-/* 17:16 */ setMaxDamage(0);
-/* 18:17 */ setHasSubtypes(true);
-/* 19:18 */ setCreativeTab(GregTech_API.TAB_GREGTECH_MATERIALS);
-/* 20: */ }
-/* 21: */
-/* 22: */ public String getUnlocalizedName(ItemStack aStack)
-/* 23: */ {
-/* 24:23 */ return this.field_150939_a.getUnlocalizedName() + "." + getDamage(aStack);
-/* 25: */ }
-/* 26: */
-/* 27: */ public int getMetadata(int aMeta)
-/* 28: */ {
-/* 29:28 */ return aMeta;
-/* 30: */ }
-/* 31: */
-/* 32:31 */ private final String mNoMobsToolTip = GT_LanguageManager.addStringLocalization("gt.nomobspawnsonthisblock", "Mobs cannot Spawn on this Block");
-/* 33: */
-/* 34: */ public void addInformation(ItemStack aStack, EntityPlayer aPlayer, List aList, boolean aF3_H)
-/* 35: */ {
-/* 36:35 */ super.addInformation(aStack, aPlayer, aList, aF3_H);
-/* 37:36 */ if (aStack.getItemDamage() % 8 >= 3) {
-/* 38:36 */ aList.add(this.mNoMobsToolTip);
-/* 39: */ }
-/* 40: */ }
-/* 41: */ }
+package gregtech.common.blocks;
+
+import gregtech.api.GregTech_API;
+import gregtech.api.util.GT_LanguageManager;
+import java.util.List;
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemBlock;
+import net.minecraft.item.ItemStack;
+
+public class GT_Item_Stones_Abstract
+ extends ItemBlock
+{
+ public GT_Item_Stones_Abstract(Block par1)
+ {
+ super(par1);
+ setMaxDamage(0);
+ setHasSubtypes(true);
+ setCreativeTab(GregTech_API.TAB_GREGTECH_MATERIALS);
+ }
+
+ public String getUnlocalizedName(ItemStack aStack)
+ {
+ return this.field_150939_a.getUnlocalizedName() + "." + getDamage(aStack);
+ }
+
+ public int getMetadata(int aMeta)
+ {
+ return aMeta;
+ }
+
+ private final String mNoMobsToolTip = GT_LanguageManager.addStringLocalization("gt.nomobspawnsonthisblock", "Mobs cannot Spawn on this Block");
+
+ public void addInformation(ItemStack aStack, EntityPlayer aPlayer, List aList, boolean aF3_H)
+ {
+ super.addInformation(aStack, aPlayer, aList, aF3_H);
+ if (aStack.getItemDamage() % 8 >= 3) {
+ aList.add(this.mNoMobsToolTip);
+ }
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Material_Casings.java b/main/java/gregtech/common/blocks/GT_Material_Casings.java index e3a866a80d..9bae1ad5a2 100644 --- a/main/java/gregtech/common/blocks/GT_Material_Casings.java +++ b/main/java/gregtech/common/blocks/GT_Material_Casings.java @@ -1,24 +1,24 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import net.minecraft.block.material.MapColor;
-/* 4: */ import net.minecraft.block.material.Material;
-/* 5: */
-/* 6: */ public class GT_Material_Casings
-/* 7: */ extends Material
-/* 8: */ {
-/* 9: 7 */ public static final Material INSTANCE = new GT_Material_Casings();
-/* 10: */
-/* 11: */ private GT_Material_Casings()
-/* 12: */ {
-/* 13:10 */ super(MapColor.ironColor);
-/* 14:11 */ setRequiresTool();
-/* 15: */ }
-/* 16: */
-/* 17: */ public boolean isOpaque()
-/* 18: */ {
-/* 19:16 */ return false;
-/* 20: */ }
-/* 21: */ }
+package gregtech.common.blocks;
+
+import net.minecraft.block.material.MapColor;
+import net.minecraft.block.material.Material;
+
+public class GT_Material_Casings
+ extends Material
+{
+ public static final Material INSTANCE = new GT_Material_Casings();
+
+ private GT_Material_Casings()
+ {
+ super(MapColor.ironColor);
+ setRequiresTool();
+ }
+
+ public boolean isOpaque()
+ {
+ return false;
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Material_Machines.java b/main/java/gregtech/common/blocks/GT_Material_Machines.java index 6de2022449..b77deb9c65 100644 --- a/main/java/gregtech/common/blocks/GT_Material_Machines.java +++ b/main/java/gregtech/common/blocks/GT_Material_Machines.java @@ -1,24 +1,24 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import net.minecraft.block.material.MapColor;
-/* 4: */ import net.minecraft.block.material.Material;
-/* 5: */
-/* 6: */ public class GT_Material_Machines
-/* 7: */ extends Material
-/* 8: */ {
-/* 9: */ public GT_Material_Machines()
-/* 10: */ {
-/* 11: 8 */ super(MapColor.ironColor);
-/* 12: 9 */ setRequiresTool();
-/* 13:10 */ setImmovableMobility();
-/* 14:11 */ setAdventureModeExempt();
-/* 15: */ }
-/* 16: */
-/* 17: */ public boolean isOpaque()
-/* 18: */ {
-/* 19:16 */ return false;
-/* 20: */ }
-/* 21: */ }
+package gregtech.common.blocks;
+
+import net.minecraft.block.material.MapColor;
+import net.minecraft.block.material.Material;
+
+public class GT_Material_Machines
+ extends Material
+{
+ public GT_Material_Machines()
+ {
+ super(MapColor.ironColor);
+ setRequiresTool();
+ setImmovableMobility();
+ setAdventureModeExempt();
+ }
+
+ public boolean isOpaque()
+ {
+ return false;
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_Packet_Ores.java b/main/java/gregtech/common/blocks/GT_Packet_Ores.java index 60fb9e4669..c6648b17d0 100644 --- a/main/java/gregtech/common/blocks/GT_Packet_Ores.java +++ b/main/java/gregtech/common/blocks/GT_Packet_Ores.java @@ -1,71 +1,71 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import com.google.common.io.ByteArrayDataInput;
-/* 4: */ import com.google.common.io.ByteArrayDataOutput;
-/* 5: */ import com.google.common.io.ByteStreams;
-/* 6: */ import gregtech.api.net.GT_Packet;
-/* 7: */ import net.minecraft.tileentity.TileEntity;
-/* 8: */ import net.minecraft.world.IBlockAccess;
-/* 9: */ import net.minecraft.world.World;
-/* 10: */
-/* 11: */ public class GT_Packet_Ores
-/* 12: */ extends GT_Packet
-/* 13: */ {
-/* 14: */ private int mX;
-/* 15: */ private int mZ;
-/* 16: */ private short mY;
-/* 17: */ private short mMetaData;
-/* 18: */
-/* 19: */ public GT_Packet_Ores()
-/* 20: */ {
-/* 21:17 */ super(true);
-/* 22: */ }
-/* 23: */
-/* 24: */ public GT_Packet_Ores(int aX, short aY, int aZ, short aMetaData)
-/* 25: */ {
-/* 26:21 */ super(false);
-/* 27:22 */ this.mX = aX;
-/* 28:23 */ this.mY = aY;
-/* 29:24 */ this.mZ = aZ;
-/* 30:25 */ this.mMetaData = aMetaData;
-/* 31: */ }
-/* 32: */
-/* 33: */ public byte[] encode()
-/* 34: */ {
-/* 35:30 */ ByteArrayDataOutput tOut = ByteStreams.newDataOutput(12);
-/* 36: */
-/* 37:32 */ tOut.writeInt(this.mX);
-/* 38:33 */ tOut.writeShort(this.mY);
-/* 39:34 */ tOut.writeInt(this.mZ);
-/* 40:35 */ tOut.writeShort(this.mMetaData);
-/* 41: */
-/* 42:37 */ return tOut.toByteArray();
-/* 43: */ }
-/* 44: */
-/* 45: */ public GT_Packet decode(ByteArrayDataInput aData)
-/* 46: */ {
-/* 47:42 */ return new GT_Packet_Ores(aData.readInt(), aData.readShort(), aData.readInt(), aData.readShort());
-/* 48: */ }
-/* 49: */
-/* 50: */ public void process(IBlockAccess aWorld)
-/* 51: */ {
-/* 52:47 */ if (aWorld != null)
-/* 53: */ {
-/* 54:48 */ TileEntity tTileEntity = aWorld.getTileEntity(this.mX, this.mY, this.mZ);
-/* 55:49 */ if ((tTileEntity instanceof GT_TileEntity_Ores)) {
-/* 56:49 */ ((GT_TileEntity_Ores)tTileEntity).mMetaData = this.mMetaData;
-/* 57: */ }
-/* 58:50 */ if (((aWorld instanceof World)) && (((World)aWorld).isRemote)) {
-/* 59:50 */ ((World)aWorld).markBlockForUpdate(this.mX, this.mY, this.mZ);
-/* 60: */ }
-/* 61: */ }
-/* 62: */ }
-/* 63: */
-/* 64: */ public byte getPacketID()
-/* 65: */ {
-/* 66:56 */ return 3;
-/* 67: */ }
-/* 68: */ }
+package gregtech.common.blocks;
+
+import com.google.common.io.ByteArrayDataInput;
+import com.google.common.io.ByteArrayDataOutput;
+import com.google.common.io.ByteStreams;
+import gregtech.api.net.GT_Packet;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.world.IBlockAccess;
+import net.minecraft.world.World;
+
+public class GT_Packet_Ores
+ extends GT_Packet
+{
+ private int mX;
+ private int mZ;
+ private short mY;
+ private short mMetaData;
+
+ public GT_Packet_Ores()
+ {
+ super(true);
+ }
+
+ public GT_Packet_Ores(int aX, short aY, int aZ, short aMetaData)
+ {
+ super(false);
+ this.mX = aX;
+ this.mY = aY;
+ this.mZ = aZ;
+ this.mMetaData = aMetaData;
+ }
+
+ public byte[] encode()
+ {
+ ByteArrayDataOutput tOut = ByteStreams.newDataOutput(12);
+
+ tOut.writeInt(this.mX);
+ tOut.writeShort(this.mY);
+ tOut.writeInt(this.mZ);
+ tOut.writeShort(this.mMetaData);
+
+ return tOut.toByteArray();
+ }
+
+ public GT_Packet decode(ByteArrayDataInput aData)
+ {
+ return new GT_Packet_Ores(aData.readInt(), aData.readShort(), aData.readInt(), aData.readShort());
+ }
+
+ public void process(IBlockAccess aWorld)
+ {
+ if (aWorld != null)
+ {
+ TileEntity tTileEntity = aWorld.getTileEntity(this.mX, this.mY, this.mZ);
+ if ((tTileEntity instanceof GT_TileEntity_Ores)) {
+ ((GT_TileEntity_Ores)tTileEntity).mMetaData = this.mMetaData;
+ }
+ if (((aWorld instanceof World)) && (((World)aWorld).isRemote)) {
+ ((World)aWorld).markBlockForUpdate(this.mX, this.mY, this.mZ);
+ }
+ }
+ }
+
+ public byte getPacketID()
+ {
+ return 3;
+ }
+}
/* Location: F:\Torrent\minecraft\jd-gui-0.3.6.windows\gregtech_1.7.10-5.07.07-dev.jar
diff --git a/main/java/gregtech/common/blocks/GT_TileEntity_Ores.java b/main/java/gregtech/common/blocks/GT_TileEntity_Ores.java index cb844dcbb2..ebe64977a0 100644 --- a/main/java/gregtech/common/blocks/GT_TileEntity_Ores.java +++ b/main/java/gregtech/common/blocks/GT_TileEntity_Ores.java @@ -1,250 +1,250 @@ -/* 1: */ package gregtech.common.blocks;
-/* 2: */
-/* 3: */ import gregtech.api.GregTech_API;
-/* 4: */ import gregtech.api.enums.GT_Values;
-/* 5: */ import gregtech.api.enums.Materials;
-/* 6: */ import gregtech.api.enums.OrePrefixes;
+package gregtech.common.blocks;
+
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.GT_Values;
+import gregtech.api.enums.Materials;
+import gregtech.api.enums.OrePrefixes;
import gregtech.api.enums.Textures;
-/* 7: */ import gregtech.api.enums.Textures.BlockIcons;
-/* 8: */ import gregtech.api.interfaces.ITexture;
-/* 9: */ import gregtech.api.interfaces.tileentity.ITexturedTileEntity;
-/* 10: */ import gregtech.api.net.IGT_NetworkHandler;
-/* 11: */ import gregtech.api.objects.GT_CopiedBlockTexture;
-/* 12: */ import gregtech.api.objects.GT_RenderedTexture;
-/* 13: */ import gregtech.api.util.GT_OreDictUnificator;
-/* 14: */ import gregtech.api.util.GT_Utility;
+import gregtech.api.enums.Textures.BlockIcons;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.interfaces.tileentity.ITexturedTileEntity;
+import gregtech.api.net.IGT_NetworkHandler;
+import gregtech.api.objects.GT_CopiedBlockTexture;
+import gregtech.api.objects.GT_RenderedTexture;
+import gregtech.api.util.GT_OreDictUnificator;
+import gregtech.api.util.GT_Utility;
+
+import java.util.ArrayList;
+import java.util.Random;
+
+import net.minecraft.block.Block;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.network.Packet;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.world.World;
-/* 15: */ import java.util.ArrayList;
-/* 16: */ import java.util.Random;
+public class GT_TileEntity_Ores
+ extends TileEntity
+ implements ITexturedTileEntity
+{
+ private static final ITexture[] mStoneTextures = { new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.netherrack, 0, 0), new GT_CopiedBlockTexture(Blocks.end_stone, 0, 0), new GT_RenderedTexture(Textures.BlockIcons.GRANITE_BLACK_STONE), new GT_RenderedTexture(Textures.BlockIcons.GRANITE_RED_STONE), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0) };
+ public short mMetaData = 0;
+ public boolean mNatural = false;
+ public boolean mBlocked = true;
+
+ public void readFromNBT(NBTTagCompound aNBT)
+ {
+ super.readFromNBT(aNBT);
+ this.mMetaData = aNBT.getShort("m");
+ this.mNatural = aNBT.getBoolean("n");
+ }
+
+ public void writeToNBT(NBTTagCompound aNBT)
+ {
+ super.writeToNBT(aNBT);
+ aNBT.setShort("m", this.mMetaData);
+ aNBT.setBoolean("n", this.mNatural);
+ }
+
+ public void onUpdated()
+ {
+ if ((!this.worldObj.isRemote) && (this.mBlocked))
+ {
+ this.mBlocked = false;
+ GT_Values.NW.sendPacketToAllPlayersInRange(this.worldObj, new GT_Packet_Ores(this.xCoord, (short)this.yCoord, this.zCoord, this.mMetaData), this.xCoord, this.zCoord);
+ }
+ }
+
+ public Packet getDescriptionPacket()
+ {
+ if (!this.worldObj.isRemote) {
+ if ((this.mBlocked == (GT_Utility.isOpaqueBlock(this.worldObj, this.xCoord + 1, this.yCoord, this.zCoord)) && (GT_Utility.isOpaqueBlock(this.worldObj, this.xCoord - 1, this.yCoord, this.zCoord)) && (GT_Utility.isOpaqueBlock(this.worldObj, this.xCoord, this.yCoord + 1, this.zCoord)) && (GT_Utility.isOpaqueBlock(this.worldObj, this.xCoord, this.yCoord - 1, this.zCoord)) && (GT_Utility.isOpaqueBlock(this.worldObj, this.xCoord, this.yCoord, this.zCoord + 1)) && (GT_Utility.isOpaqueBlock(this.worldObj, this.xCoord, this.yCoord, this.zCoord - 1)) ? 1 : 0) == 0) {
+ GT_Values.NW.sendPacketToAllPlayersInRange(this.worldObj, new GT_Packet_Ores(this.xCoord, (short)this.yCoord, this.zCoord, this.mMetaData), this.xCoord, this.zCoord);
+ }
+ }
+ return null;
+ }
+
+ 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)));
+ }
+
+ public void overrideOreBlockMaterial(Block aOverridingStoneBlock, byte aOverridingStoneMeta)
+ {
+ this.mMetaData = ((short)(int)(this.mMetaData % 1000L + this.mMetaData / 16000L * 16000L));
+ if (aOverridingStoneBlock.isReplaceableOreGen(this.worldObj, this.xCoord, this.yCoord, this.zCoord, Blocks.netherrack)) {
+ this.mMetaData = ((short)(this.mMetaData + 1000));
+ } else if (aOverridingStoneBlock.isReplaceableOreGen(this.worldObj, this.xCoord, this.yCoord, this.zCoord, Blocks.end_stone)) {
+ this.mMetaData = ((short)(this.mMetaData + 2000));
+ } else if (aOverridingStoneBlock.isReplaceableOreGen(this.worldObj, this.xCoord, this.yCoord, this.zCoord, GregTech_API.sBlockGranites)) {
+ if (aOverridingStoneBlock == GregTech_API.sBlockGranites)
+ {
+ if (aOverridingStoneMeta < 8) {
+ this.mMetaData = ((short)(this.mMetaData + 3000));
+ } else {
+ this.mMetaData = ((short)(this.mMetaData + 4000));
+ }
+ }
+ else {
+ this.mMetaData = ((short)(this.mMetaData + 3000));
+ }
+ }
+ this.worldObj.setBlockMetadataWithNotify(this.xCoord, this.yCoord, this.zCoord, getHarvestData(this.mMetaData), 0);
+ }
+
+ public static boolean setOreBlock(World aWorld, int aX, int aY, int aZ, int aMetaData)
+ {
+ aY = Math.min(aWorld.getActualHeight(), Math.max(aY, 1));
+ Block tBlock = aWorld.getBlock(aX, aY, aZ);
+ if ((aMetaData > 0) && (tBlock != Blocks.air))
+ {
+ if (tBlock.isReplaceableOreGen(aWorld, aX, aY, aZ, Blocks.netherrack)) {
+ aMetaData += 1000;
+ } else if (tBlock.isReplaceableOreGen(aWorld, aX, aY, aZ, Blocks.end_stone)) {
+ aMetaData += 2000;
+ } else if (tBlock.isReplaceableOreGen(aWorld, aX, aY, aZ, GregTech_API.sBlockGranites))
+ {
+ if (tBlock == GregTech_API.sBlockGranites)
+ {
+ if (aWorld.getBlockMetadata(aX, aY, aZ) < 8) {
+ aMetaData += 3000;
+ } else {
+ aMetaData += 4000;
+ }
+ }
+ else {
+ aMetaData += 3000;
+ }
+ }
+ else if (!tBlock.isReplaceableOreGen(aWorld, aX, aY, aZ, Blocks.stone)) {
+ return false;
+ }
+ aWorld.setBlock(aX, aY, aZ, GregTech_API.sBlockOres1, getHarvestData((short)aMetaData), 0);
+ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
+ if ((tTileEntity instanceof GT_TileEntity_Ores))
+ {
+ ((GT_TileEntity_Ores)tTileEntity).mMetaData = ((short)aMetaData);
+ ((GT_TileEntity_Ores)tTileEntity).mNatural = true;
+ }
+ return true;
+ }
+ return false;
+ }
+
+ public short getMetaData()
+ {
+ return this.mMetaData;
+ }
+
+ public boolean canUpdate()
+ {
+ return false;
+ }
+
+ public ArrayList<ItemStack> getDrops(int aFortune)
+ {
+ ArrayList<ItemStack> rList = new ArrayList();
+ if (this.mMetaData <= 0)
+ {
+ rList.add(new ItemStack(Blocks.cobblestone, 1, 0));
+ return rList;
+ }
+ if (this.mMetaData < 16000)
+ {
+ rList.add(new ItemStack(GregTech_API.sBlockOres1, 1, this.mMetaData));
+ return rList;
+ }
+ Materials aMaterial = GregTech_API.sGeneratedMaterials[(this.mMetaData % 1000)];
+ if (!this.mNatural) {
+ aFortune = 0;
+ }
+ if (aMaterial != null)
+ {
+ Random tRandom = new Random(this.xCoord ^ this.yCoord ^ this.zCoord);
+ ArrayList<ItemStack> tSelector = new ArrayList();
+
-/* 17: */ import net.minecraft.block.Block;
-/* 18: */ import net.minecraft.init.Blocks;
-/* 19: */ import net.minecraft.item.ItemStack;
-/* 20: */ import net.minecraft.nbt.NBTTagCompound;
-/* 21: */ import net.minecraft.network.Packet;
-/* 22: */ import net.minecraft.tileentity.TileEntity;
-/* 23: */ import net.minecraft.world.World;
-/* 24: */
-/* 25: */ public class GT_TileEntity_Ores
-/* 26: */ extends TileEntity
-/* 27: */ implements ITexturedTileEntity
-/* 28: */ {
-/* 29: 28 */ private static final ITexture[] mStoneTextures = { new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.netherrack, 0, 0), new GT_CopiedBlockTexture(Blocks.end_stone, 0, 0), new GT_RenderedTexture(Textures.BlockIcons.GRANITE_BLACK_STONE), new GT_RenderedTexture(Textures.BlockIcons.GRANITE_RED_STONE), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0), new GT_CopiedBlockTexture(Blocks.stone, 0, 0) };
-/* 30: 47 */ public short mMetaData = 0;
-/* 31: 48 */ public boolean mNatural = false;
-/* 32: 48 */ public boolean mBlocked = true;
-/* 33: */
-/* 34: */ public void readFromNBT(NBTTagCompound aNBT)
-/* 35: */ {
-/* 36: 52 */ super.readFromNBT(aNBT);
-/* 37: 53 */ this.mMetaData = aNBT.getShort("m");
-/* 38: 54 */ this.mNatural = aNBT.getBoolean("n");
-/* 39: */ }
-/* 40: */
-/* 41: */ public void writeToNBT(NBTTagCompound aNBT)
-/* 42: */ {
-/* 43: 59 */ super.writeToNBT(aNBT);
-/* 44: 60 */ aNBT.setShort("m", this.mMetaData);
-/* 45: 61 */ aNBT.setBoolean("n", this.mNatural);
-/* 46: */ }
-/* 47: */
-/* 48: */ public void onUpdated()
-/* 49: */ {
-/* 50: 65 */ if ((!this.worldObj.isRemote) && (this.mBlocked))
-/* 51: */ {
-/* 52: 66 */ this.mBlocked = false;
-/* 53: 67 */ GT_Values.NW.sendPacketToAllPlayersInRange(this.worldObj, new GT_Packet_Ores(this.xCoord, (short)this.yCoord, this.zCoord, this.mMetaData), this.xCoord, this.zCoord);
-/* 54: */ }
-/* 55: */ }
-/* 56: */
-/* 57: */ public Packet getDescriptionPacket()
-/* 58: */ {
-/* 59: 73 */ if (!this.worldObj.isRemote) {
-/* 60: 73 */ if ((this.mBlocked == (GT_Utility.isOpaqueBlock(this.worldObj, this.xCoord + 1, this.yCoord, this.zCoord)) && (GT_Utility.isOpaqueBlock(this.worldObj, this.xCoord - 1, this.yCoord, this.zCoord)) && (GT_Utility.isOpaqueBlock(this.worldObj, this.xCoord, this.yCoord + 1, this.zCoord)) && (GT_Utility.isOpaqueBlock(this.worldObj, this.xCoord, this.yCoord - 1, this.zCoord)) && (GT_Utility.isOpaqueBlock(this.worldObj, this.xCoord, this.yCoord, this.zCoord + 1)) && (GT_Utility.isOpaqueBlock(this.worldObj, this.xCoord, this.yCoord, this.zCoord - 1)) ? 1 : 0) == 0) {
-/* 61: 74 */ GT_Values.NW.sendPacketToAllPlayersInRange(this.worldObj, new GT_Packet_Ores(this.xCoord, (short)this.yCoord, this.zCoord, this.mMetaData), this.xCoord, this.zCoord);
-/* 62: */ }
-/* 63: */ }
-/* 64: 76 */ return null;
-/* 65: */ }
-/* 66: */
-/* 67: */ public static byte getHarvestData(short aMetaData)
-/* 68: */ {
-/* 69: 86 */ Materials aMaterial = GregTech_API.sGeneratedMaterials[(aMetaData % 1000)];
-/* 70: 87 */ 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)));
-/* 71: */ }
-/* 72: */
-/* 73: */ public void overrideOreBlockMaterial(Block aOverridingStoneBlock, byte aOverridingStoneMeta)
-/* 74: */ {
-/* 75: 91 */ this.mMetaData = ((short)(int)(this.mMetaData % 1000L + this.mMetaData / 16000L * 16000L));
-/* 76: 92 */ if (aOverridingStoneBlock.isReplaceableOreGen(this.worldObj, this.xCoord, this.yCoord, this.zCoord, Blocks.netherrack)) {
-/* 77: 93 */ this.mMetaData = ((short)(this.mMetaData + 1000));
-/* 78: 94 */ } else if (aOverridingStoneBlock.isReplaceableOreGen(this.worldObj, this.xCoord, this.yCoord, this.zCoord, Blocks.end_stone)) {
-/* 79: 95 */ this.mMetaData = ((short)(this.mMetaData + 2000));
-/* 80: 96 */ } else if (aOverridingStoneBlock.isReplaceableOreGen(this.worldObj, this.xCoord, this.yCoord, this.zCoord, GregTech_API.sBlockGranites)) {
-/* 81: 97 */ if (aOverridingStoneBlock == GregTech_API.sBlockGranites)
-/* 82: */ {
-/* 83: 98 */ if (aOverridingStoneMeta < 8) {
-/* 84: 99 */ this.mMetaData = ((short)(this.mMetaData + 3000));
-/* 85: */ } else {
-/* 86:101 */ this.mMetaData = ((short)(this.mMetaData + 4000));
-/* 87: */ }
-/* 88: */ }
-/* 89: */ else {
-/* 90:104 */ this.mMetaData = ((short)(this.mMetaData + 3000));
-/* 91: */ }
-/* 92: */ }
-/* 93:107 */ this.worldObj.setBlockMetadataWithNotify(this.xCoord, this.yCoord, this.zCoord, getHarvestData(this.mMetaData), 0);
-/* 94: */ }
-/* 95: */
-/* 96: */ public static boolean setOreBlock(World aWorld, int aX, int aY, int aZ, int aMetaData)
-/* 97: */ {
-/* 98:111 */ aY = Math.min(aWorld.getActualHeight(), Math.max(aY, 1));
-/* 99:112 */ Block tBlock = aWorld.getBlock(aX, aY, aZ);
-/* 100:114 */ if ((aMetaData > 0) && (tBlock != Blocks.air))
-/* 101: */ {
-/* 102:115 */ if (tBlock.isReplaceableOreGen(aWorld, aX, aY, aZ, Blocks.netherrack)) {
-/* 103:116 */ aMetaData += 1000;
-/* 104:117 */ } else if (tBlock.isReplaceableOreGen(aWorld, aX, aY, aZ, Blocks.end_stone)) {
-/* 105:118 */ aMetaData += 2000;
-/* 106:119 */ } else if (tBlock.isReplaceableOreGen(aWorld, aX, aY, aZ, GregTech_API.sBlockGranites))
-/* 107: */ {
-/* 108:120 */ if (tBlock == GregTech_API.sBlockGranites)
-/* 109: */ {
-/* 110:121 */ if (aWorld.getBlockMetadata(aX, aY, aZ) < 8) {
-/* 111:122 */ aMetaData += 3000;
-/* 112: */ } else {
-/* 113:124 */ aMetaData += 4000;
-/* 114: */ }
-/* 115: */ }
-/* 116: */ else {
-/* 117:127 */ aMetaData += 3000;
-/* 118: */ }
-/* 119: */ }
-/* 120:129 */ else if (!tBlock.isReplaceableOreGen(aWorld, aX, aY, aZ, Blocks.stone)) {
-/* 121:129 */ return false;
-/* 122: */ }
-/* 123:130 */ aWorld.setBlock(aX, aY, aZ, GregTech_API.sBlockOres1, getHarvestData((short)aMetaData), 0);
-/* 124:131 */ TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
-/* 125:132 */ if ((tTileEntity instanceof GT_TileEntity_Ores))
-/* 126: */ {
-/* 127:133 */ ((GT_TileEntity_Ores)tTileEntity).mMetaData = ((short)aMetaData);
-/* 128:134 */ ((GT_TileEntity_Ores)tTileEntity).mNatural = true;
-/* 129: */ }
-/* 130:136 */ return true;
-/* 131: */ }
-/* 132:138 */ return false;
-/* 133: */ }
-/* 134: */
-/* 135: */ public short getMetaData()
-/* 136: */ {
-/* 137:145 */ return this.mMetaData;
-/* 138: */ }
-/* 139: */
-/* 140: */ public boolean canUpdate()
-/* 141: */ {
-/* 142:150 */ return false;
-/* 143: */ }
-/* 144: */
-/* 145: */ public ArrayList<ItemStack> getDrops(int aFortune)
-/* 146: */ {
-/* 147:157 */ ArrayList<ItemStack> rList = new ArrayList();
-/* 148:158 */ if (this.mMetaData <= 0)
-/* 149: */ {
-/* 150:159 */ rList.add(new ItemStack(Blocks.cobblestone, 1, 0));
-/* 151:160 */ return rList;
-/* 152: */ }
-/* 153:162 */ if (this.mMetaData < 16000)
-/* 154: */ {
-/* 155:163 */ rList.add(new ItemStack(GregTech_API.sBlockOres1, 1, this.mMetaData));
-/* 156:164 */ return rList;
-/* 157: */ }
-/* 158:166 */ Materials aMaterial = GregTech_API.sGeneratedMaterials[(this.mMetaData % 1000)];
-/* 159:167 */ if (!this.mNatural) {
-/* 160:167 */ aFortune = 0;
-/* 161: */ }
-/* 162:168 */ if (aMaterial != null)
-/* 163: */ {
-/* 164:169 */ Random tRandom = new Random(this.xCoord ^ this.yCoord ^ this.zCoord);
-/* 165:170 */ ArrayList<ItemStack> tSelector = new ArrayList();
-/* 166: */
-/* 167: */
-/* 168:173 */ ItemStack tStack = GT_OreDictUnificator.get(OrePrefixes.gemExquisite, aMaterial, GT_OreDictUnificator.get(OrePrefixes.gem, aMaterial, 1L), 1L);
-/* 169:174 */ if (tStack != null) {
-/* 170:174 */ for (int i = 0; i < 1; i++) {
-/* 171:174 */ tSelector.add(tStack);
-/* 172: */ }
-/* 173: */ }
-/* 174:175 */ tStack = GT_OreDictUnificator.get(OrePrefixes.gemFlawless, aMaterial, GT_OreDictUnificator.get(OrePrefixes.gem, aMaterial, 1L), 1L);
-/* 175:176 */ if (tStack != null) {
-/* 176:176 */ for (int i = 0; i < 2; i++) {
-/* 177:176 */ tSelector.add(tStack);
-/* 178: */ }
-/* 179: */ }
-/* 180:177 */ tStack = GT_OreDictUnificator.get(OrePrefixes.gem, aMaterial, 1L);
-/* 181:178 */ if (tStack != null) {
-/* 182:178 */ for (int i = 0; i < 12; i++) {
-/* 183:178 */ tSelector.add(tStack);
-/* 184: */ }
-/* 185: */ }
-/* 186:180 */ tStack = GT_OreDictUnificator.get(OrePrefixes.gemFlawed, aMaterial, GT_OreDictUnificator.get(OrePrefixes.crushed, aMaterial, 1L), 1L);
-/* 187:181 */ if (tStack != null) {
-/* 188:181 */ for (int i = 0; i < 5; i++) {
-/* 189:181 */ tSelector.add(tStack);
-/* 190: */ }
-/* 191: */ }
-/* 192:182 */ tStack = GT_OreDictUnificator.get(OrePrefixes.crushed, aMaterial, 1L);
-/* 193:183 */ if (tStack != null) {
-/* 194:183 */ for (int i = 0; i < 10; i++) {
-/* 195:183 */ tSelector.add(tStack);
-/* 196: */ }
-/* 197: */ }
-/* 198:185 */ tStack = GT_OreDictUnificator.get(OrePrefixes.gemChipped, aMaterial, GT_OreDictUnificator.get(OrePrefixes.dustImpure, aMaterial, 1L), 1L);
-/* 199:186 */ if (tStack != null) {
-/* 200:186 */ for (int i = 0; i < 5; i++) {
-/* 201:186 */ tSelector.add(tStack);
-/* 202: */ }
-/* 203: */ }
-/* 204:187 */ tStack = GT_OreDictUnificator.get(OrePrefixes.dustImpure, aMaterial, 1L);
-/* 205:188 */ if (tStack != null) {
-/* 206:188 */ for (int i = 0; i < 10; i++) {
-/* 207:188 */ tSelector.add(tStack);
-/* 208: */ }
-/* 209: */ }
-/* 210:190 */ if (tSelector.size() > 0)
-/* 211: */ {
-/* 212:191 */ int i = 0;
-/* 213:191 */ for (int j = Math.max(1, aMaterial.mOreMultiplier + (aFortune > 0 ? tRandom.nextInt(1 + aFortune * aMaterial.mOreMultiplier) : 0) / 2); i < j; i++) {
-/* 214:192 */ rList.add(GT_Utility.copyAmount(1L, new Object[] { tSelector.get(tRandom.nextInt(tSelector.size())) }));
-/* 215: */ }
-/* 216: */ }
-/* 217:195 */ if (tRandom.nextInt(3 + aFortune) > 1) {
-/* 218:196 */ switch (this.mMetaData / 1000 % 16)
-/* 219: */ {
-/* 220: */ case 0:
-/* 221:197 */ rList.add(GT_OreDictUnificator.get(tRandom.nextInt(3) > 0 ? OrePrefixes.dustImpure : OrePrefixes.dust, Materials.Stone, 1L)); break;
-/* 222: */ case 1:
-/* 223:198 */ rList.add(GT_OreDictUnificator.get(tRandom.nextInt(3) > 0 ? OrePrefixes.dustImpure : OrePrefixes.dust, Materials.Netherrack, 1L)); break;
-/* 224: */ case 2:
-/* 225:199 */ rList.add(GT_OreDictUnificator.get(tRandom.nextInt(3) > 0 ? OrePrefixes.dustImpure : OrePrefixes.dust, Materials.Endstone, 1L)); break;
-/* 226: */ case 3:
-/* 227:200 */ rList.add(GT_OreDictUnificator.get(tRandom.nextInt(3) > 0 ? OrePrefixes.dustImpure : OrePrefixes.dust, Materials.GraniteBlack, 1L)); break;
-/* 228: */ case 4:
-/* 229:201 */ rList.add(GT_OreDictUnificator.get(tRandom.nextInt(3) > 0 ? OrePrefixes.dustImpure : OrePrefixes.dust, Materials.GraniteRed, 1L));
-/* 230: */ }
-/* 231: */ }
-/* 232: */ }
-/* 233:205 */ return rList;
-/* 234: */ }
-/* 235: */
-/* 236: */ public ITexture[] getTexture(byte aSide)
-/* 237: */ {
-/* 238:210 */ Materials aMaterial = GregTech_API.sGeneratedMaterials[(this.mMetaData % 1000)];
-/* 239:211 */ if ((aMaterial != null) && (this.mMetaData < 32000)) {
-/* 240:211 */ return new ITexture[] { mStoneTextures[(this.mMetaData / 1000 % 16)], new GT_RenderedTexture(aMaterial.mIconSet.mTextures[this.mMetaData/16000 ==0 ? OrePrefixes.ore.mTextureIndex:OrePrefixes.oreSmall.mTextureIndex], aMaterial.mRGBa) };
-/* 241: */ }
-/* 242:212 */ return new ITexture[] { mStoneTextures[0], new GT_RenderedTexture(gregtech.api.enums.TextureSet.SET_NONE.mTextures[OrePrefixes.ore.mTextureIndex]) };
-/* 243: */ }
-/* 244: */ }
+ ItemStack tStack = GT_OreDictUnificator.get(OrePrefixes.gemExquisite, aMaterial, GT_OreDictUnificator.get(OrePrefixes.gem, aMaterial, 1L), 1L);
+ if (tStack != null) {
+ for (int i = 0; i < 1; i++) {
+ tSelector.add(tStack);
+ }
+ }
+ tStack = GT_OreDictUnificator.get(OrePrefixes.gemFlawless, aMaterial, GT_OreDictUnificator.get(OrePrefixes.gem, aMaterial, 1L), 1L);
+ if (tStack != null) {
+ for (int i = 0; i < 2; i++) {
+ tSelector.add(tStack);
+ }
+ }
+ tStack = GT_OreDictUnificator.get(OrePrefixes.gem, aMaterial, 1L);
+ if (tStack != null) {
+ for (int i = 0; i < 12; i++) {
+ tSelector.add(tStack);
+ }
+ }
+ tStack = GT_OreDictUnificator.get(OrePrefixes.gemFlawed, aMaterial, GT_OreDictUnificator.get(OrePrefixes.crushed, aMaterial, 1L), 1L);
+ if (tStack != null) {
+ for (int i = 0; i < 5; i++) {
+ tSelector.add(tStack);
+ }
+ }
+ tStack = GT_OreDictUnificator.get(OrePrefixes.crushed, aMaterial, 1L);
+ if (tStack != null) {
+ for (int i = 0; i < 10; i++) {
+ tSelector.add(tStack);
+ }
+ }
+ tStack = GT_OreDictUnificator.get(OrePrefixes.gemChipped, aMaterial, GT_OreDictUnificator.get(OrePrefixes.dustImpure, aMaterial, 1L), 1L);
+ if (tStack != null) {
+ for (int i = 0; i < 5; i++) {
+ tSelector.add(tStack);
+ }
+ }
+ tStack = GT_OreDictUnificator.get(OrePrefixes.dustImpure, aMaterial, 1L);
+ if (tStack != null) {
+ for (int i = 0; i < 10; i++) {
+ tSelector.add(tStack);
+ }
+ }
+ if (tSelector.size() > 0)
+ {
+ int i = 0;
+ for (int j = Math.max(1, aMaterial.mOreMultiplier + (aFortune > 0 ? tRandom.nextInt(1 + aFortune * aMaterial.mOreMultiplier) : 0) / 2); i < j; i++) {
+ rList.add(GT_Utility.copyAmount(1L, new Object[] { tSelector.get(tRandom.nextInt(tSelector.size())) }));
+ }
+ }
+ if (tRandom.nextInt(3 + aFortune) > 1) {
+ switch (this.mMetaData / 1000 % 16)
+ {
+ case 0:
+ rList.add(GT_OreDictUnificator.get(tRandom.nextInt(3) > 0 ? OrePrefixes.dustImpure : OrePrefixes.dust, Materials.Stone, 1L)); break;
+ case 1:
+ rList.add(GT_OreDictUnificator.get(tRandom.nextInt(3) > 0 ? OrePrefixes.dustImpure : OrePrefixes.dust, Materials.Netherrack, 1L)); break;
+ case 2:
+ rList.add(GT_OreDictUnificator.get(tRandom.nextInt(3) > 0 ? OrePrefixes.dustImpure : OrePrefixes.dust, Materials.Endstone, 1L)); break;
+ case 3:
+ rList.add(GT_OreDictUnificator.get(tRandom.nextInt(3) > 0 ? OrePrefixes.dustImpure : OrePrefixes.dust, Materials.GraniteBlack, 1L)); break;
+ case 4:
+ rList.add(GT_OreDictUnificator.get(tRandom.nextInt(3) > 0 ? OrePrefixes.dustImpure : OrePrefixes.dust, Materials.GraniteRed, 1L));
+ }
+ }
+ }
+ return rList;
+ }
+
+ public ITexture[] getTexture(byte aSide)
+ {
+ Materials aMaterial = GregTech_API.sGeneratedMaterials[(this.mMetaData % 1000)];
+ if ((aMaterial != null) && (this.mMetaData < 32000)) {
+ return new ITexture[] { mStoneTextures[(this.mMetaData / 1000 % 16)], new GT_RenderedTexture(aMaterial.mIconSet.mTextures[this.mMetaData/16000 ==0 ? OrePrefixes.ore.mTextureIndex:OrePrefixes.oreSmall.mTextureIndex], aMaterial.mRGBa) };
+ }
+ return new ITexture[] { mStoneTextures[0], new GT_RenderedTexture(gregtech.api.enums.TextureSet.SET_NONE.mTextures[OrePrefixes.ore.mTextureIndex]) };
+ }
+}
|