Broad tool fixes, Drawbridge and Igniter

This commit is contained in:
mDiyo committed 2013-06-29 09:38:36 -07:00
1 parent aab20a98fc
commit c32b755bf5
101 files changed
+2521 -792

No files matched your search

@@ -0,0 +1,31 @@
package mods.tinker.tconstruct.items.blocks;
import net.minecraft.item.ItemBlock;
import net.minecraft.item.ItemStack;
import net.minecraft.util.MathHelper;
public class RedstoneMachineItem extends ItemBlock
{
public static final String blockType[] =
{
"drawbridge", "firestarter"
};
public RedstoneMachineItem(int id)
{
super(id);
setMaxDamage(0);
setHasSubtypes(true);
}
public int getMetadata(int meta)
{
return meta;
}
public String getUnlocalizedName(ItemStack itemstack)
{
int pos = MathHelper.clamp_int(itemstack.getItemDamage(), 0, blockType.length-1);
return (new StringBuilder()).append("block.").append(blockType[pos]).toString();
}
}