30 lines
677 B
Java
30 lines
677 B
Java
|
package biomesoplenty.items;
|
||
|
|
||
|
import net.minecraft.block.Block;
|
||
|
import net.minecraft.item.ItemBlock;
|
||
|
import net.minecraft.item.ItemStack;
|
||
|
import biomesoplenty.blocks.BlockBOPLeaves;
|
||
|
|
||
|
public class ItemBOPLeaves extends ItemBlock
|
||
|
{
|
||
|
public ItemBOPLeaves(int par1)
|
||
|
{
|
||
|
super(par1);
|
||
|
setMaxDamage(0);
|
||
|
setHasSubtypes(true);
|
||
|
}
|
||
|
|
||
|
@Override
|
||
|
public int getMetadata(int meta)
|
||
|
{
|
||
|
return meta;
|
||
|
}
|
||
|
|
||
|
@Override
|
||
|
public String getUnlocalizedName(ItemStack itemStack)
|
||
|
{
|
||
|
BlockBOPLeaves block = (BlockBOPLeaves)Block.blocksList[itemStack.itemID];
|
||
|
return block.getLeafType(itemStack.getItemDamage());
|
||
|
}
|
||
|
}
|