From ae5dd4ea4745498c57b7bc95483eacd113bb5dc1 Mon Sep 17 00:00:00 2001 From: Arthur Uzulin Date: Sat, 19 Oct 2013 18:32:41 +1100 Subject: [PATCH] Various fixes/changes - Return false for isAirBlock in TankAirBlock(fixes ability to replace the blocks with lava/water) - Changed tankAir material from Material.air to Material.leaves(fixes ability to replace the blocks with lava/water) - Clean up imports in TankLayerScan removing the import for scala.compat.Platform$ (fixes crash when there is no scala library) - Add wooden armor recipes --- src/tconstruct/blocks/TankAirBlock.java | 2 +- src/tconstruct/common/TContent.java | 9 ++++++++- .../library/component/TankLayerScan.java | 18 +++--------------- 3 files changed, 12 insertions(+), 17 deletions(-) diff --git a/src/tconstruct/blocks/TankAirBlock.java b/src/tconstruct/blocks/TankAirBlock.java index 37f911ba..69a2b8f6 100644 --- a/src/tconstruct/blocks/TankAirBlock.java +++ b/src/tconstruct/blocks/TankAirBlock.java @@ -94,6 +94,6 @@ public class TankAirBlock extends BlockContainer @Override public boolean isAirBlock(World world, int x, int y, int z) { - return true; + return false; } } diff --git a/src/tconstruct/common/TContent.java b/src/tconstruct/common/TContent.java index d1fd3cfd..a30aab26 100644 --- a/src/tconstruct/common/TContent.java +++ b/src/tconstruct/common/TContent.java @@ -1,5 +1,7 @@ package tconstruct.common; +import net.minecraftforge.oredict.ShapedOreRecipe; + import net.minecraftforge.common.EnumHelper; import cpw.mods.fml.common.*; @@ -414,7 +416,7 @@ public class TContent implements IFuelHandler GameRegistry.registerBlock(castingChannel, CastingChannelItem.class, "CastingChannel"); GameRegistry.registerTileEntity(CastingChannelLogic.class, "CastingChannel"); - tankAir = new TankAirBlock(PHConstruct.airTank, Material.air).setBlockUnbreakable().setUnlocalizedName("tconstruct.tank.air"); + tankAir = new TankAirBlock(PHConstruct.airTank, Material.leaves).setBlockUnbreakable().setUnlocalizedName("tconstruct.tank.air"); GameRegistry.registerBlock(tankAir, "TankAir"); GameRegistry.registerTileEntity(TankAirLogic.class, "tconstruct.tank.air"); @@ -1545,6 +1547,11 @@ public class TContent implements IFuelHandler GameRegistry.addRecipe(new ItemStack(materials, 1, 25), "sss", "sns", "sss", 'n', new ItemStack(Item.goldNugget), 's', new ItemStack(Item.silk)); GameRegistry.addRecipe(new ItemStack(materials, 1, 26), " c ", "cec", " c ", 'c', new ItemStack(materials, 1, 25), 'e', new ItemStack(Item.emerald)); //Silky Jewel + GameRegistry.addRecipe(new ShapedOreRecipe(helmetWood, new Object[]{"www", "w w", 'w', "logWood"})); + GameRegistry.addRecipe(new ShapedOreRecipe(chestplateWood, new Object[]{"w w", "www", "www", 'w', "logWood"})); + GameRegistry.addRecipe(new ShapedOreRecipe(leggingsWood, new Object[]{"www", "w w", "w w", 'w', "logWood"})); + GameRegistry.addRecipe(new ShapedOreRecipe(bootsWood, new Object[]{"w w", "w w", 'w', "logWood"})); + //FurnaceRecipes.smelting().addSmelting(oreSlag.blockID, 1, new ItemStack(materials, 1, 3), 3f); //FurnaceRecipes.smelting().addSmelting(oreSlag.blockID, 2, new ItemStack(materials, 1, 4), 3f); FurnaceRecipes.smelting().addSmelting(oreSlag.blockID, 3, new ItemStack(materials, 1, 9), 0.5f); diff --git a/src/tconstruct/library/component/TankLayerScan.java b/src/tconstruct/library/component/TankLayerScan.java index b3a929f1..e8c376c3 100644 --- a/src/tconstruct/library/component/TankLayerScan.java +++ b/src/tconstruct/library/component/TankLayerScan.java @@ -1,23 +1,11 @@ package tconstruct.library.component; -import java.util.ArrayList; -import java.util.Collections; -import java.util.Iterator; -import java.util.HashSet; - +import java.util.*; import net.minecraft.block.Block; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.nbt.NBTTagIntArray; -import net.minecraft.nbt.NBTTagList; +import net.minecraft.nbt.*; import net.minecraft.tileentity.TileEntity; -import net.minecraftforge.classloading.FMLForgePlugin; -import scala.compat.Platform$; import tconstruct.TConstruct; -import tconstruct.library.util.CoordTuple; -import tconstruct.library.util.CoordTupleSort; -import tconstruct.library.util.IFacingLogic; -import tconstruct.library.util.IMasterLogic; -import tconstruct.library.util.IServantLogic; +import tconstruct.library.util.*; public class TankLayerScan extends LogicComponent {