public static enum Item.ToolMaterial extends java.lang.Enum<Item.ToolMaterial>
Modifier and Type | Method and Description |
---|---|
float |
getDamageVsEntity()
Returns the damage against a given entity.
|
float |
getEfficiencyOnProperMaterial()
The strength of this tool material against blocks which it is effective against.
|
int |
getEnchantability()
Return the natural enchantability factor of the material.
|
int |
getHarvestLevel()
The level of material this tool can harvest (3 = DIAMOND, 2 = IRON, 1 = STONE, 0 = IRON/GOLD)
|
int |
getMaxUses()
The number of uses this material allows.
|
Item |
getRepairItem()
Deprecated.
|
ItemStack |
getRepairItemStack() |
Item.ToolMaterial |
setRepairItem(ItemStack stack) |
static Item.ToolMaterial |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static Item.ToolMaterial[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Item.ToolMaterial WOOD
public static final Item.ToolMaterial STONE
public static final Item.ToolMaterial IRON
public static final Item.ToolMaterial DIAMOND
public static final Item.ToolMaterial GOLD
public static Item.ToolMaterial[] values()
for (Item.ToolMaterial c : Item.ToolMaterial.values()) System.out.println(c);
public static Item.ToolMaterial valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is nullpublic int getMaxUses()
public float getEfficiencyOnProperMaterial()
public float getDamageVsEntity()
public int getHarvestLevel()
public int getEnchantability()
@Deprecated public Item getRepairItem()
public Item.ToolMaterial setRepairItem(ItemStack stack)
public ItemStack getRepairItemStack()