mirror of
https://github.com/GTNewHorizons/TinkersConstruct.git
synced 2026-11-19 19:59:55 +00:00
most of item/block will now compile
This commit is contained in:
1 parent
ad96fbfa61
commit
3bf37fa6a7
66 files changed
+282
-249
No files matched your search
@@ -7,14 +7,15 @@ import tconstruct.common.TRepo;
|
||||
import tconstruct.library.TConstructRegistry;
|
||||
import tconstruct.library.util.IToolPart;
|
||||
import mantle.items.abstracts.CraftingItem;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public class Bowstring extends CraftingItem implements IToolPart
|
||||
{
|
||||
public Bowstring(int id)
|
||||
public Bowstring()
|
||||
{
|
||||
super(id, toolMaterialNames, buildTextureNames("_bowstring"), "parts/", "tinker", TConstructRegistry.materialTab);
|
||||
super(toolMaterialNames, buildTextureNames("_bowstring"), "parts/", "tinker", TConstructRegistry.materialTab);
|
||||
this.setHasSubtypes(true);
|
||||
this.setMaxDamage(0);
|
||||
}
|
||||
@@ -42,12 +43,12 @@ public class Bowstring extends CraftingItem implements IToolPart
|
||||
return stack.getItemDamage();
|
||||
}
|
||||
|
||||
public void getSubItems (int id, CreativeTabs tab, List list)
|
||||
public void getSubItems (Block b, CreativeTabs tab, List list)
|
||||
{
|
||||
list.add(new ItemStack(id, 1, 0));
|
||||
list.add(new ItemStack(b, 1, 0));
|
||||
if (TRepo.thaumcraftAvailable)
|
||||
list.add(new ItemStack(id, 1, 1));
|
||||
list.add(new ItemStack(b, 1, 1));
|
||||
if (Loader.isModLoaded("Natura"))
|
||||
list.add(new ItemStack(id, 1, 2));
|
||||
list.add(new ItemStack(b, 1, 2));
|
||||
}
|
||||
}
|
||||
@@ -10,6 +10,7 @@ import net.minecraft.block.Block;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.init.Items;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemBucket;
|
||||
import net.minecraft.item.ItemStack;
|
||||
@@ -30,7 +31,7 @@ public class FilledBucket extends ItemBucket
|
||||
//setTextureFile(TRepo.craftingTexture);
|
||||
//setIconIndex(224);
|
||||
setUnlocalizedName("tconstruct.bucket");
|
||||
setContainerItem(Item.bucketEmpty);
|
||||
setContainerItem(Items.bucket);
|
||||
this.setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -123,7 +124,7 @@ public class FilledBucket extends ItemBucket
|
||||
|
||||
if (this.tryPlaceContainedLiquid(world, clickX, clickY, clickZ, stack.getItemDamage()) && !player.capabilities.isCreativeMode)
|
||||
{
|
||||
return new ItemStack(Item.bucketEmpty);
|
||||
return new ItemStack(Items.bucket);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -144,7 +145,7 @@ public class FilledBucket extends ItemBucket
|
||||
if (TRepo.fluidBlocks[type] instanceof BlockFluidFinite)
|
||||
metadata = 7;
|
||||
|
||||
world.setBlock(clickX, clickY, clickZ, TRepo.fluidBlocks[type].blockID, metadata, 3); //TODO: Merge liquids
|
||||
world.setBlock(clickX, clickY, clickZ, TRepo.fluidBlocks[type], metadata, 3); //TODO: Merge liquids
|
||||
} catch (ArrayIndexOutOfBoundsException ex) {
|
||||
TConstruct.logger.warning("AIOBE occured when placing bucket into world; " + ex);
|
||||
return false;
|
||||
|
||||
@@ -7,9 +7,9 @@ import net.minecraft.item.ItemStack;
|
||||
|
||||
public class Fletching extends CraftingItem implements IToolPart
|
||||
{
|
||||
public Fletching(int id)
|
||||
public Fletching()
|
||||
{
|
||||
super(id, toolMaterialNames, buildTextureNames("_fletching"), "parts/", "tinker", TConstructRegistry.materialTab);
|
||||
super(toolMaterialNames, buildTextureNames("_fletching"), "parts/", "tinker", TConstructRegistry.materialTab);
|
||||
this.setHasSubtypes(true);
|
||||
this.setMaxDamage(0);
|
||||
}
|
||||
|
||||
@@ -22,9 +22,9 @@ public class Jerky extends SpecialFood
|
||||
public static float[] saturation = new float[] { 1.0f, 0.8f, 1.0f, 0.8f, 0.8f, 0.4f, 1.0f, 0.25f };
|
||||
public static int[] overhaulHunger = new int[] { 1, 1, 1, 1, 1, 1, 1, 1 };
|
||||
|
||||
public Jerky(int id, boolean hungerOverhaul)
|
||||
public Jerky(boolean hungerOverhaul)
|
||||
{
|
||||
super(id, hungerOverhaul ? overhaulHunger : hunger, saturation, itemNames, textureNames);
|
||||
super(hungerOverhaul ? overhaulHunger : hunger, saturation, itemNames, textureNames);
|
||||
this.setHasSubtypes(true);
|
||||
}
|
||||
|
||||
|
||||
@@ -19,9 +19,9 @@ public class Manual extends CraftingItem
|
||||
static String[] name = new String[] { "beginner", "toolstation", "smeltery", "diary" };
|
||||
static String[] textureName = new String[] { "tinkerbook_diary", "tinkerbook_toolstation", "tinkerbook_smeltery", "tinkerbook_blue" };
|
||||
|
||||
public Manual(int id)
|
||||
public Manual()
|
||||
{
|
||||
super(id, name, textureName, "", "tinker", TConstructRegistry.materialTab);
|
||||
super(name, textureName, "", "tinker", TConstructRegistry.materialTab);
|
||||
setUnlocalizedName("tconstruct.manual");
|
||||
}
|
||||
|
||||
|
||||
@@ -6,9 +6,9 @@ import mantle.items.abstracts.CraftingItem;
|
||||
public class MaterialItem extends CraftingItem
|
||||
{
|
||||
|
||||
public MaterialItem(int id)
|
||||
public MaterialItem()
|
||||
{
|
||||
super(id, materialNames, getTextures(), "materials/", "tinker", TConstructRegistry.materialTab);
|
||||
super(materialNames, getTextures(), "materials/", "tinker", TConstructRegistry.materialTab);
|
||||
}
|
||||
|
||||
private static String[] getTextures ()
|
||||
|
||||
@@ -2,15 +2,16 @@ package tconstruct.items;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
public class MetalPattern extends Pattern
|
||||
{
|
||||
|
||||
public MetalPattern(int id, String patternType, String folder)
|
||||
public MetalPattern(String patternType, String folder)
|
||||
{
|
||||
super(id, patternName, getPatternNames(patternType), folder);
|
||||
super(patternName, getPatternNames(patternType), folder);
|
||||
}
|
||||
|
||||
protected static String[] getPatternNames (String partType)
|
||||
@@ -27,10 +28,10 @@ public class MetalPattern extends Pattern
|
||||
private static final String[] patternName = new String[] { "ingot", "rod", "pickaxe", "shovel", "axe", "swordblade", "largeguard", "mediumguard", "crossbar", "binding", "frypan", "sign",
|
||||
"knifeblade", "chisel", "largerod", "toughbinding", "largeplate", "broadaxe", "scythe", "excavator", "largeblade", "hammerhead", "fullguard", "", "", "arrowhead", "gem" };
|
||||
|
||||
public void getSubItems (int id, CreativeTabs tab, List list)
|
||||
public void getSubItems (Block b)
|
||||
{
|
||||
for (int i = 0; i < patternName.length; i++)
|
||||
if (!(patternName[i].equals("")))
|
||||
list.add(new ItemStack(id, 1, i));
|
||||
list.add(new ItemStack(b, 1, i));
|
||||
}
|
||||
}
|
||||
@@ -18,9 +18,9 @@ public class OreBerries extends CraftingItem
|
||||
static String[] names = new String[] { "iron", "gold", "copper", "tin", "aluminum", "essence" };
|
||||
static String[] tex = new String[] { "oreberry_iron", "oreberry_gold", "oreberry_copper", "oreberry_tin", "oreberry_aluminum", "oreberry_essence" };
|
||||
|
||||
public OreBerries(int id)
|
||||
public OreBerries()
|
||||
{
|
||||
super(id, names, tex, "oreberries/", "tinker", TConstructRegistry.materialTab);
|
||||
super(names, tex, "oreberries/", "tinker", TConstructRegistry.materialTab);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -5,8 +5,10 @@ import cpw.mods.fml.relauncher.*;
|
||||
import java.util.List;
|
||||
|
||||
import mantle.items.abstracts.CraftingItem;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.StatCollector;
|
||||
import tconstruct.library.TConstructRegistry;
|
||||
@@ -17,12 +19,12 @@ public class Pattern extends CraftingItem implements IPattern
|
||||
{
|
||||
public Pattern(int id, String patternType, String folder)
|
||||
{
|
||||
this(id, patternName, getPatternNames(patternType), folder);
|
||||
this(patternName, getPatternNames(patternType), folder);
|
||||
}
|
||||
|
||||
public Pattern(int id, String[] names, String[] patternTypes, String folder)
|
||||
public Pattern(String[] names, String[] patternTypes, String folder)
|
||||
{
|
||||
super(id, names, patternTypes, folder, "tinker", TConstructRegistry.materialTab);
|
||||
super(names, patternTypes, folder, "tinker", TConstructRegistry.materialTab);
|
||||
this.setHasSubtypes(true);
|
||||
this.setMaxDamage(0);
|
||||
this.setContainerItem(this);
|
||||
@@ -41,12 +43,12 @@ public class Pattern extends CraftingItem implements IPattern
|
||||
"knifeblade", "chisel", "largerod", "toughbinding", "largeplate", "broadaxe", "scythe", "excavator", "largeblade", "hammerhead", "fullguard", "bowstring", "fletching", "arrowhead" };
|
||||
|
||||
@Override
|
||||
public void getSubItems (int id, CreativeTabs tab, List list)
|
||||
public void getSubItems (Block b, CreativeTabs tab, List list)
|
||||
{
|
||||
for (int i = 1; i < patternName.length; i++)
|
||||
{
|
||||
//if (i != 23)
|
||||
list.add(new ItemStack(id, 1, i));
|
||||
list.add(new ItemStack(b, 1, i));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -145,6 +147,6 @@ public class Pattern extends CraftingItem implements IPattern
|
||||
@Override
|
||||
public ItemStack getPatternOutput (ItemStack stack, ItemStack input, MaterialSet set)
|
||||
{
|
||||
return TConstructRegistry.getPartMapping(this.itemID, stack.getItemDamage(), set.materialID);
|
||||
return TConstructRegistry.getPartMapping((Item)this, stack.getItemDamage(), set.materialID);
|
||||
}
|
||||
}
|
||||
@@ -20,7 +20,7 @@ public class SpecialFood extends ItemFood
|
||||
float[] saturation;
|
||||
String[] unlocalizedNames;
|
||||
String[] iconNames;
|
||||
Icon[] icons;
|
||||
IIcon[] icons;
|
||||
|
||||
public SpecialFood(int[] hunger, float[] saturation, String[] textureNames, String[] iconNames)
|
||||
{
|
||||
@@ -45,7 +45,7 @@ public class SpecialFood extends ItemFood
|
||||
@SideOnly(Side.CLIENT)
|
||||
public IIcon getIconFromDamage (int meta)
|
||||
{
|
||||
return iicons[0];
|
||||
return icons[0];
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
|
||||
@@ -13,9 +13,9 @@ import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class StrangeFood extends SpecialFood
|
||||
{
|
||||
public StrangeFood(int id)
|
||||
public StrangeFood()
|
||||
{
|
||||
super(id, new int[] { 2, 2 }, new float[] { 1f, 1f }, new String[] { "edibleslime", "edibleblood" }, new String[] { "food/edibleslime", "food/edibleblood" });
|
||||
super(new int[] { 2, 2 }, new float[] { 1f, 1f }, new String[] { "edibleslime", "edibleblood" }, new String[] { "food/edibleslime", "food/edibleblood" });
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -7,9 +7,9 @@ import net.minecraft.creativetab.CreativeTabs;
|
||||
public class ToolPartHidden extends ToolPart
|
||||
{
|
||||
|
||||
public ToolPartHidden(int id, String textureType, String name)
|
||||
public ToolPartHidden(String textureType, String name)
|
||||
{
|
||||
super(id, textureType, name);
|
||||
super(textureType, name);
|
||||
}
|
||||
|
||||
public void getSubItems (int id, CreativeTabs tab, List list)
|
||||
|
||||
@@ -5,7 +5,8 @@ import java.util.UUID;
|
||||
|
||||
import com.google.common.collect.Multimap;
|
||||
|
||||
import net.minecraft.client.renderer.texture.IconRegister;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.SharedMonsterAttributes;
|
||||
@@ -31,7 +32,7 @@ public class ExoArmor extends ArmorCore
|
||||
}
|
||||
|
||||
@Override
|
||||
public void registerIcons (IconRegister par1IconRegister)
|
||||
public void registerIcons (IIconRegister par1IconRegister)
|
||||
{
|
||||
this.itemIcon = par1IconRegister.registerIcon("tinker:armor/" + textureName + "_"
|
||||
+ (this.armorType == 0 ? "helmet" : this.armorType == 1 ? "chestplate" : this.armorType == 2 ? "leggings" : this.armorType == 3 ? "boots" : "helmet"));
|
||||
@@ -43,9 +44,9 @@ public class ExoArmor extends ArmorCore
|
||||
return "tinker:textures/armor/" + textureName + "_" + layer + ".png";
|
||||
}
|
||||
|
||||
public void getSubItems (int par1, CreativeTabs par2CreativeTabs, List par3List)
|
||||
public void getSubItems (Block b, CreativeTabs par2CreativeTabs, List par3List)
|
||||
{
|
||||
ItemStack armor = new ItemStack(par1, 1, 0);
|
||||
ItemStack armor = new ItemStack(b, 1, 0);
|
||||
NBTTagCompound baseTag = new NBTTagCompound();
|
||||
NBTTagList list = new NBTTagList();
|
||||
|
||||
|
||||
@@ -17,9 +17,9 @@ import cpw.mods.fml.relauncher.SideOnly;
|
||||
public class HeartCanister extends CraftingItem
|
||||
{
|
||||
|
||||
public HeartCanister(int id)
|
||||
public HeartCanister()
|
||||
{
|
||||
super(id, new String[] { "empty", "miniheart.red", "heart" }, new String[] { "canister_empty", "miniheart_red", "canister_heart" }, "", "tinker", TConstructRegistry.materialTab );
|
||||
super(new String[] { "empty", "miniheart.red", "heart" }, new String[] { "canister_empty", "miniheart_red", "canister_heart" }, "", "tinker", TConstructRegistry.materialTab );
|
||||
this.setMaxStackSize(10);
|
||||
}
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@ import cpw.mods.fml.relauncher.SideOnly;
|
||||
public class Knapsack extends CraftingItem
|
||||
{
|
||||
|
||||
public Knapsack(int id)
|
||||
public Knapsack()
|
||||
{
|
||||
super(new String[] { "knapsack" }, new String[] { "knapsack" }, "armor/", "tinker", TConstructRegistry.materialTab);
|
||||
this.setMaxStackSize(10);
|
||||
|
||||
@@ -23,9 +23,9 @@ public class TArmorBase extends ItemArmor
|
||||
//static Minecraft mc = Minecraft.getMinecraft();
|
||||
//private ModelBiped modelArmor;
|
||||
|
||||
public TArmorBase(int id, int armorSlot)
|
||||
public TArmorBase(int armorSlot)
|
||||
{
|
||||
super(id, EnumArmorMaterial.CLOTH, 0, armorSlot);
|
||||
super(EnumArmorMaterial.CLOTH, 0, armorSlot);
|
||||
this.maxStackSize = 1;
|
||||
this.setMaxDamage(100);
|
||||
setNoRepair();
|
||||
|
||||
@@ -6,6 +6,7 @@ import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.MathHelper;
|
||||
@@ -16,10 +17,9 @@ public class BarricadeItem extends ItemBlock
|
||||
{
|
||||
private int bID;
|
||||
|
||||
public BarricadeItem(int id)
|
||||
public BarricadeItem(Block b)
|
||||
{
|
||||
super(id);
|
||||
this.bID = id + 256;
|
||||
super(b);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -31,13 +31,13 @@ public class BarricadeItem extends ItemBlock
|
||||
|
||||
public boolean onItemUse (ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side, float hitX, float hitY, float hitZ)
|
||||
{
|
||||
int i1 = world.getBlockId(x, y, z);
|
||||
Block i1 = world.getBlock(x, y, z);
|
||||
|
||||
if (i1 == Block.snow.blockID && (world.getBlockMetadata(x, y, z) & 7) < 1)
|
||||
if (i1 == Blocks.snow && (world.getBlockMetadata(x, y, z) & 7) < 1)
|
||||
{
|
||||
side = 1;
|
||||
}
|
||||
else if (i1 != Block.vine.blockID && i1 != Block.tallGrass.blockID && i1 != Block.deadBush.blockID
|
||||
else if (i1 != Blocks.vine && i1 != Blocks.tallgrass && i1 != Blocks.deadbush
|
||||
&& (Block.blocksList[i1] == null || !Block.blocksList[i1].isBlockReplaceable(world, x, y, z)))
|
||||
{
|
||||
if (side == 0)
|
||||
|
||||
@@ -1,14 +1,15 @@
|
||||
package tconstruct.items.blocks;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
|
||||
public class CastingChannelItem extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "Channel" };
|
||||
|
||||
public CastingChannelItem(int id)
|
||||
public CastingChannelItem(Block b)
|
||||
{
|
||||
super(id, "Smeltery", blockTypes);
|
||||
super(b, "Smeltery", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -5,6 +5,7 @@ import java.util.List;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.MathHelper;
|
||||
@@ -14,9 +15,9 @@ public class CraftedSoilItemBlock extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "Slime", "Grout", "BlueSlime", "GraveyardSoil", "ConsecratedSoil", "blue", "dirt", "Grout" };
|
||||
|
||||
public CraftedSoilItemBlock(int id)
|
||||
public CraftedSoilItemBlock(Block b)
|
||||
{
|
||||
super(id, "CraftedSoil", blockTypes);
|
||||
super(b, "CraftedSoil", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package tconstruct.items.blocks;
|
||||
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.MathHelper;
|
||||
|
||||
@@ -8,9 +9,9 @@ public class CraftingSlabItemBlock extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "tile.CraftingStation", "Crafter", "Parts", "PatternShaper", "PatternChest", "tile.ToolForge" };
|
||||
|
||||
public CraftingSlabItemBlock(int id)
|
||||
public CraftingSlabItemBlock(Block b)
|
||||
{
|
||||
super(id, "ToolStation", blockTypes);
|
||||
super(b, "ToolStation", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ package tconstruct.items.blocks;
|
||||
import java.util.List;
|
||||
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
@@ -11,9 +12,9 @@ public class GlassBlockItem extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "pure" };//, "soul", "soul.pure" };
|
||||
|
||||
public GlassBlockItem(int id)
|
||||
public GlassBlockItem(Block b)
|
||||
{
|
||||
super(id, "block.glass", blockTypes);
|
||||
super(b, "block.glass", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -1,14 +1,15 @@
|
||||
package tconstruct.items.blocks;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
|
||||
public class GlassPaneItem extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "pure", "soul", "soul.pure" };
|
||||
|
||||
public GlassPaneItem(int id)
|
||||
public GlassPaneItem(Block b)
|
||||
{
|
||||
super(id, "block.glass", "pane", blockTypes);
|
||||
super(b, "block.glass", "pane", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package tconstruct.items.blocks;
|
||||
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.MathHelper;
|
||||
@@ -9,9 +10,9 @@ public class GravelOreItem extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "iron", "gold", "copper", "tin", "aluminum", "cobalt" };
|
||||
|
||||
public GravelOreItem(int id)
|
||||
public GravelOreItem(Block b)
|
||||
{
|
||||
super(id, "block.ore.gravel", blockTypes);
|
||||
super(b, "block.ore.gravel", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -2,6 +2,7 @@ package tconstruct.items.blocks;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.EnumAction;
|
||||
@@ -18,9 +19,9 @@ import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class HamboneItemBlock extends ItemBlock
|
||||
{
|
||||
public HamboneItemBlock(int id)
|
||||
public HamboneItemBlock(Block b)
|
||||
{
|
||||
super(id);
|
||||
super(b);
|
||||
itemUseDuration = 32;
|
||||
if (Loader.isModLoaded("HungerOverhaul"))
|
||||
{
|
||||
|
||||
@@ -3,6 +3,7 @@ package tconstruct.items.blocks;
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
@@ -19,9 +20,9 @@ import tconstruct.common.TRepo;
|
||||
public class ItemBlockLandmine extends ItemBlock
|
||||
{
|
||||
|
||||
public ItemBlockLandmine(int par1)
|
||||
public ItemBlockLandmine(Block b)
|
||||
{
|
||||
super(par1);
|
||||
super(b);
|
||||
this.setHasSubtypes(true);
|
||||
}
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@ package tconstruct.items.blocks;
|
||||
import java.util.List;
|
||||
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
@@ -14,9 +15,9 @@ public class LavaTankItemBlock extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "Tank", "Gague", "Window" };
|
||||
|
||||
public LavaTankItemBlock(int id)
|
||||
public LavaTankItemBlock(Block b)
|
||||
{
|
||||
super(id, "LavaTank", blockTypes);
|
||||
super(b, "LavaTank", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ package tconstruct.items.blocks;
|
||||
import java.util.List;
|
||||
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.StatCollector;
|
||||
@@ -11,9 +12,9 @@ public class MetalItemBlock extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "Cobalt", "Ardite", "Manyullyn", "Copper", "Bronze", "Tin", "Aluminum", "AlBrass", "Alumite", "Steel", "Ender" };
|
||||
|
||||
public MetalItemBlock(int id)
|
||||
public MetalItemBlock(Block b)
|
||||
{
|
||||
super(id, "StorageMetals", blockTypes);
|
||||
super(b, "StorageMetals", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ package tconstruct.items.blocks;
|
||||
import java.util.List;
|
||||
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
@@ -13,9 +14,9 @@ public class MetalOreItemBlock extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "NetherSlag", "Cobalt", "Ardite", "Copper", "Tin", "Aluminum", "Slag" };
|
||||
|
||||
public MetalOreItemBlock(int id)
|
||||
public MetalOreItemBlock(Block b)
|
||||
{
|
||||
super(id, "MetalOre", blockTypes);
|
||||
super(b, "MetalOre", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ package tconstruct.items.blocks;
|
||||
import java.util.List;
|
||||
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.StatCollector;
|
||||
@@ -14,9 +15,9 @@ public class MultiBrickFancyItem extends MultiItemBlock
|
||||
static String blockTypes[] = { "obsidian", "sandstone", "netherrack", "stone.refined", "iron", "gold", "lapis", "diamond", "redstone", "bone", "slime", "blueslime", "endstone", "obsidian.ingot",
|
||||
"stone", "stone.road" };
|
||||
|
||||
public MultiBrickFancyItem(int id)
|
||||
public MultiBrickFancyItem(Block b)
|
||||
{
|
||||
super(id, "block.fancybrick", blockTypes);
|
||||
super(b, "block.fancybrick", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ package tconstruct.items.blocks;
|
||||
import java.util.List;
|
||||
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
@@ -16,9 +17,9 @@ public class MultiBrickItem extends MultiItemBlock
|
||||
static String blockTypes[] = { "obsidian", "sandstone", "netherrack", "stone.refined", "iron", "gold", "lapis", "diamond", "redstone", "bone", "slime", "blueslime", "endstone", "obsidian.ingot",
|
||||
"stone.road", "stone.refined.road" };
|
||||
|
||||
public MultiBrickItem(int id)
|
||||
public MultiBrickItem(Block b)
|
||||
{
|
||||
super(id, "block.brick", blockTypes);
|
||||
super(b, "block.brick", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -8,7 +8,7 @@ import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
import net.minecraftforge.common.IPlantable;
|
||||
import net.minecraft.util.StatCollector;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
@@ -19,10 +19,9 @@ public class OreberryBushItem extends MultiItemBlock
|
||||
public int blockID;
|
||||
public static final String blockTypes[] = { "iron", "gold", "copper", "tin", "iron", "gold", "copper", "tin", "iron", "gold", "copper", "tin", "iron", "gold", "copper", "tin" };
|
||||
|
||||
public OreberryBushItem(int id)
|
||||
public OreberryBushItem(Block b)
|
||||
{
|
||||
super(id, "block.oreberry", blockTypes);
|
||||
blockID = id + 256;
|
||||
super(b, "block.oreberry", blockTypes);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.MathHelper;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
import net.minecraftforge.common.IPlantable;
|
||||
import net.minecraft.util.StatCollector;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
@@ -21,10 +21,9 @@ public class OreberryBushSecondItem extends MultiItemBlock
|
||||
public int blockID;
|
||||
public static final String blockTypes[] = { "aluminum", "essence", "", "", "aluminum", "essence", "", "", "aluminum", "essence", "", "", "aluminum", "essence", "", "" };
|
||||
|
||||
public OreberryBushSecondItem(int id)
|
||||
public OreberryBushSecondItem(Block b)
|
||||
{
|
||||
super(id, "block.oreberry", blockTypes);
|
||||
blockID = id + 256;
|
||||
super(b, "block.oreberry", blockTypes);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package tconstruct.items.blocks;
|
||||
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.MathHelper;
|
||||
@@ -9,9 +10,9 @@ public class SearedSlabItem extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "brick", "stone", "cobble", "paver", "road", "fancy", "square", "creeper" };
|
||||
|
||||
public SearedSlabItem(int id)
|
||||
public SearedSlabItem(Block b)
|
||||
{
|
||||
super(id, "block.searedstone.slab", blockTypes);
|
||||
super(b, "block.searedstone.slab", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -1,14 +1,15 @@
|
||||
package tconstruct.items.blocks;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
|
||||
public class SearedTableItemBlock extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "Table", "Faucet", "Basin" };
|
||||
|
||||
public SearedTableItemBlock(int id)
|
||||
public SearedTableItemBlock(Block b)
|
||||
{
|
||||
super(id, "SearedBlock", blockTypes);
|
||||
super(b, "SearedBlock", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -1,14 +1,15 @@
|
||||
package tconstruct.items.blocks;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
|
||||
public class SlimeGelItemBlock extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "blue", "green", "purple", "magma", "yellow", "red", "metal" };
|
||||
|
||||
public SlimeGelItemBlock(int id)
|
||||
public SlimeGelItemBlock(Block b)
|
||||
{
|
||||
super(id, "block.slime.congealed", blockTypes);
|
||||
super(b, "block.slime.congealed", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -1,14 +1,15 @@
|
||||
package tconstruct.items.blocks;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
|
||||
public class SlimeGrassItemBlock extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "blue", "dirt" };
|
||||
|
||||
public SlimeGrassItemBlock(int id)
|
||||
public SlimeGrassItemBlock(Block b)
|
||||
{
|
||||
super(id, "block.slime.grass", blockTypes);
|
||||
super(b, "block.slime.grass", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -5,6 +5,7 @@ import java.util.List;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
@@ -14,9 +15,9 @@ public class SlimeLeavesItemBlock extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "blue" };
|
||||
|
||||
public SlimeLeavesItemBlock(int id)
|
||||
public SlimeLeavesItemBlock(Block b)
|
||||
{
|
||||
super(id, "block.slime.leaves", blockTypes);
|
||||
super(b, "block.slime.leaves", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package tconstruct.items.blocks;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
|
||||
|
||||
@@ -7,9 +8,9 @@ public class SlimeSaplingItemBlock extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "bluegreen" };
|
||||
|
||||
public SlimeSaplingItemBlock(int id)
|
||||
public SlimeSaplingItemBlock(Block b)
|
||||
{
|
||||
super(id, "block.slime.sapling", blockTypes);
|
||||
super(b, "block.slime.sapling", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -5,6 +5,7 @@ import java.util.List;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.StatCollector;
|
||||
@@ -13,9 +14,9 @@ public class SmelteryItemBlock extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "Controller", "Drain", "Brick", "Furnace", "Stone", "Cobblestone", "Paver", "Brick.Cracked", "Road", "Brick.Fancy", "Brick.Square" };
|
||||
|
||||
public SmelteryItemBlock(int id)
|
||||
public SmelteryItemBlock(Block b)
|
||||
{
|
||||
super(id, "Smeltery", blockTypes);
|
||||
super(b, "Smeltery", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ package tconstruct.items.blocks;
|
||||
import java.util.List;
|
||||
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.StatCollector;
|
||||
@@ -13,9 +14,9 @@ public class SoilSlabItem extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "grass", "dirt", "mycelium", "slime", "grout", "blueslime", "graveyardsoil", "consecratedsoil" };
|
||||
|
||||
public SoilSlabItem(int id)
|
||||
public SoilSlabItem(Block b)
|
||||
{
|
||||
super(id, "block.soil.slab", blockTypes );
|
||||
super(b, "block.soil.slab", blockTypes );
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ package tconstruct.items.blocks;
|
||||
import java.util.List;
|
||||
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemBlock;
|
||||
import net.minecraft.item.ItemStack;
|
||||
@@ -14,9 +15,9 @@ public class SpeedBlockItem extends MultiItemBlock
|
||||
public static final String blockTypes[] = { "brownstone.rough", "brownstone.rough.road", "brownstone.smooth", "brownstone.smooth.brick", "brownstone.smooth.road", "brownstone.smooth.fancy",
|
||||
"brownstone.smooth.chiseled" };
|
||||
|
||||
public SpeedBlockItem(int id)
|
||||
public SpeedBlockItem(Block b)
|
||||
{
|
||||
super(id, "block", blockTypes);
|
||||
super(b, "block", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ package tconstruct.items.blocks;
|
||||
import java.util.List;
|
||||
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.StatCollector;
|
||||
@@ -12,9 +13,9 @@ public class SpeedSlabItem extends MultiItemBlock
|
||||
public static final String blockTypes[] = { "brownstone.rough", "brownstone.rough.road", "brownstone.smooth", "brownstone.smooth.brick", "brownstone.smooth.road",
|
||||
"brownstone.smooth.fancy", "brownstone.smooth.chiseled" };
|
||||
|
||||
public SpeedSlabItem(int id)
|
||||
public SpeedSlabItem(Block b)
|
||||
{
|
||||
super(id, "block", "slab", blockTypes);
|
||||
super(b, "block", "slab", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -1,14 +1,15 @@
|
||||
package tconstruct.items.blocks;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
|
||||
public class StainedGlassClearItem extends MultiItemBlock
|
||||
{
|
||||
public static final String blockTypes[] = { "white", "orange", "magenta", "lightblue", "yellow", "lime", "pink", "gray", "lightgray", "cyan", "purple", "blue", "brown", "green", "red", "black" };
|
||||
|
||||
public StainedGlassClearItem(int id)
|
||||
public StainedGlassClearItem(Block b)
|
||||
{
|
||||
super(id, "block.stainedglass", blockTypes);
|
||||
super(b, "block.stainedglass", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package tconstruct.items.blocks;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
|
||||
public class StainedGlassClearPaneItem extends MultiItemBlock
|
||||
@@ -7,9 +8,9 @@ public class StainedGlassClearPaneItem extends MultiItemBlock
|
||||
public static final String blockTypes[] = { "white", "orange", "magenta", "lightblue", "yellow", "lime", "pink", "gray", "lightgray", "cyan",
|
||||
"purple", "blue", "brown", "green", "red", "black" };
|
||||
|
||||
public StainedGlassClearPaneItem(int id)
|
||||
public StainedGlassClearPaneItem(Block b)
|
||||
{
|
||||
super(id, "block.stainedglass", "pane", blockTypes);
|
||||
super(b, "block.stainedglass", "pane", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package tconstruct.items.blocks;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
|
||||
public class ToolStationItemBlock extends MultiItemBlock
|
||||
@@ -7,9 +8,9 @@ public class ToolStationItemBlock extends MultiItemBlock
|
||||
public static final String blockTypes[] = { "Crafter", "Parts", "Parts", "Parts", "Parts", "PatternChest", "PatternChest", "PatternChest", "PatternChest", "PatternChest", "PatternShaper",
|
||||
"PatternShaper", "PatternShaper", "PatternShaper", "CastingTable" };
|
||||
|
||||
public ToolStationItemBlock(int id)
|
||||
public ToolStationItemBlock(Block b)
|
||||
{
|
||||
super(id, "ToolStation", blockTypes);
|
||||
super(b, "ToolStation", blockTypes);
|
||||
setMaxDamage(0);
|
||||
setHasSubtypes(true);
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ package tconstruct.items.blocks;
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.ItemDye;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
@@ -12,9 +13,9 @@ public class WoolSlab1Item extends MultiItemBlock
|
||||
int blockID;
|
||||
Block block;
|
||||
|
||||
public WoolSlab1Item(int id)
|
||||
public WoolSlab1Item(Block b)
|
||||
{
|
||||
super(id, "", "slab", ItemDye.dyeColorNames);
|
||||
super(b, "", "slab", ItemDye.dyeColorNames);
|
||||
this.setSpecialIndex(7, 15);
|
||||
this.blockID = id + 256;
|
||||
this.block = Block.blocksList[id + 256];
|
||||
@@ -32,7 +33,7 @@ public class WoolSlab1Item extends MultiItemBlock
|
||||
|
||||
if ((side == 1 && flag || side == 0 && !flag) && id == this.blockID && trueMeta == stack.getItemDamage())
|
||||
{
|
||||
if (world.setBlock(x, y, z, Block.cloth.blockID, trueMeta, 3))
|
||||
if (world.setBlock(x, y, z, Blocks.wool.blockID, trueMeta, 3))
|
||||
{
|
||||
world.playSoundEffect((double) ((float) x + 0.5F), (double) ((float) y + 0.5F), (double) ((float) z + 0.5F), this.block.stepSound.getPlaceSound(),
|
||||
(this.block.stepSound.getVolume() + 1.0F) / 2.0F, this.block.stepSound.getPitch() * 0.8F);
|
||||
|
||||
@@ -3,6 +3,7 @@ package tconstruct.items.blocks;
|
||||
import mantle.blocks.abstracts.MultiItemBlock;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.item.*;
|
||||
import net.minecraft.util.MathHelper;
|
||||
import net.minecraft.world.World;
|
||||
@@ -12,9 +13,9 @@ public class WoolSlab2Item extends MultiItemBlock
|
||||
int blockID;
|
||||
Block block;
|
||||
|
||||
public WoolSlab2Item(int id)
|
||||
public WoolSlab2Item(Block b)
|
||||
{
|
||||
super(id, "", "slab" ,ItemDye.dyeColorNames);
|
||||
super(b, "", "slab" ,ItemDye.dyeColorNames);
|
||||
this.setSpecialIndex(7,7);
|
||||
this.blockID = id + 256;
|
||||
this.block = Block.blocksList[id + 256];
|
||||
@@ -33,7 +34,7 @@ public class WoolSlab2Item extends MultiItemBlock
|
||||
|
||||
if ((side == 1 && flag || side == 0 && !flag) && id == this.blockID && trueMeta == stack.getItemDamage())
|
||||
{
|
||||
if (world.setBlock(x, y, z, Block.cloth.blockID, trueMeta + 8, 3))
|
||||
if (world.setBlock(x, y, z, Blocks.wool.blockID, trueMeta + 8, 3))
|
||||
{
|
||||
world.playSoundEffect((double) ((float) x + 0.5F), (double) ((float) y + 0.5F), (double) ((float) z + 0.5F), this.block.stepSound.getPlaceSound(),
|
||||
(this.block.stepSound.getVolume() + 1.0F) / 2.0F, this.block.stepSound.getPitch() * 0.8F);
|
||||
|
||||
Reference in new issue
Block a user