Mopped up dat purple drank

This commit is contained in:
oitsjustjose 2013-08-14 23:23:07 -05:00
commit a03d865d4d
13 changed files with 340 additions and 605 deletions

View file

@ -12,23 +12,26 @@ import net.minecraft.item.ItemStack;
import net.minecraft.util.Icon;
import net.minecraft.util.MathHelper;
public class ItemBlockBase extends ItemBlock {
public class ItemBlockBase extends ItemBlock
{
public static String[] BLOCK_NAMES = new String[] {"Adamantine Ore", "Amethyst Ore", "Iridium Ore", "Mithril Ore", "Tourmaline Ore", "Topaz Ore", "Verdite Ore", "Bloodstone", "Black Soulstone",
"Blue Soulstone", "Red Soulstone", "Agate Ore", "Reinforced Glass"};
public ItemBlockBase(int par1) {
public ItemBlockBase(int par1)
{
super(par1);
setMaxDamage(0);
setHasSubtypes(true);
}
@Override
public String getUnlocalizedName(ItemStack itemStack) {
public String getUnlocalizedName(ItemStack itemStack)
{
int meta = MathHelper.clamp_int(itemStack.getItemDamage(), 0, BLOCK_NAMES.length);
return super.getUnlocalizedName() + BLOCK_NAMES[meta];
}
@Override
public int getMetadata(int par1)
{
return par1;