Package net.minecraft.item
Enum ItemTier
- java.lang.Object
-
- java.lang.Enum<ItemTier>
-
- net.minecraft.item.ItemTier
-
-
Field Summary
Fields Modifier and Type Field Description private float
damage
private int
enchantmentValue
private int
level
private LazyValue<Ingredient>
repairIngredient
private float
speed
private int
uses
-
Constructor Summary
Constructors Modifier Constructor Description private
ItemTier(int p_i48458_3_, int p_i48458_4_, float p_i48458_5_, float p_i48458_6_, int p_i48458_7_, java.util.function.Supplier<Ingredient> p_i48458_8_)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description float
getAttackDamageBonus()
int
getEnchantmentValue()
int
getLevel()
Ingredient
getRepairIngredient()
float
getSpeed()
int
getUses()
static ItemTier
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static ItemTier[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Field Detail
-
level
private final int level
-
uses
private final int uses
-
speed
private final float speed
-
damage
private final float damage
-
enchantmentValue
private final int enchantmentValue
-
repairIngredient
private final LazyValue<Ingredient> repairIngredient
-
-
Constructor Detail
-
ItemTier
private ItemTier(int p_i48458_3_, int p_i48458_4_, float p_i48458_5_, float p_i48458_6_, int p_i48458_7_, java.util.function.Supplier<Ingredient> p_i48458_8_)
-
-
Method Detail
-
values
public static ItemTier[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (ItemTier c : ItemTier.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static ItemTier valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
getAttackDamageBonus
public float getAttackDamageBonus()
- Specified by:
getAttackDamageBonus
in interfaceIItemTier
-
getEnchantmentValue
public int getEnchantmentValue()
- Specified by:
getEnchantmentValue
in interfaceIItemTier
-
getRepairIngredient
public Ingredient getRepairIngredient()
- Specified by:
getRepairIngredient
in interfaceIItemTier
-
-