Package dev.jaxydog.astral.content.item
Class AstralArmorItem.Material
java.lang.Object
dev.jaxydog.astral.content.item.AstralArmorItem.Material
- All Implemented Interfaces:
net.minecraft.item.ArmorMaterial
- Enclosing class:
AstralArmorItem
public static class AstralArmorItem.Material
extends Object
implements net.minecraft.item.ArmorMaterial
Implements the
ArmorMaterial interface as a buildable class.- Since:
- 2.0.0
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classBuilds and constructs an instance of a newAstralArmorItem.Material. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedMaterial(Map<net.minecraft.item.ArmorItem.Type, Integer> durability, Map<net.minecraft.item.ArmorItem.Type, Integer> protection, int enchantability, net.minecraft.sound.SoundEvent equipSound, net.minecraft.recipe.Ingredient repairIngredient, String name, float toughness, float knockbackResistance) Creates a new armor material. -
Method Summary
Modifier and TypeMethodDescriptionstatic @NotNull AstralArmorItem.Material.BuilderReturns a new builder for anAstralArmorItem.Material.intgetDurability(net.minecraft.item.ArmorItem.Type type) intnet.minecraft.sound.SoundEventfloatgetName()intgetProtection(net.minecraft.item.ArmorItem.Type type) net.minecraft.recipe.Ingredientfloat
-
Constructor Details
-
Material
protected Material(Map<net.minecraft.item.ArmorItem.Type, Integer> durability, Map<net.minecraft.item.ArmorItem.Type, Integer> protection, int enchantability, net.minecraft.sound.SoundEvent equipSound, net.minecraft.recipe.Ingredient repairIngredient, String name, float toughness, float knockbackResistance) Creates a new armor material.- Parameters:
durability- The armor's durability.protection- The armor's protection.enchantability- The armor's enchantability.equipSound- The armor's equipping sound.repairIngredient- The armor's repair ingredient.name- The armor's name.toughness- The armor's toughness.knockbackResistance- The armor's knockback resistance.- Since:
- 2.0.0
-
-
Method Details
-
builder
@Contract("_ -> new") @NotNull public static @NotNull AstralArmorItem.Material.Builder builder(String path) Returns a new builder for anAstralArmorItem.Material.- Parameters:
path- The identifier path.- Returns:
- A new builder.
- Since:
- 2.0.0
-
getDurability
public int getDurability(net.minecraft.item.ArmorItem.Type type) - Specified by:
getDurabilityin interfacenet.minecraft.item.ArmorMaterial
-
getProtection
public int getProtection(net.minecraft.item.ArmorItem.Type type) - Specified by:
getProtectionin interfacenet.minecraft.item.ArmorMaterial
-
getEnchantability
public int getEnchantability()- Specified by:
getEnchantabilityin interfacenet.minecraft.item.ArmorMaterial
-
getEquipSound
public net.minecraft.sound.SoundEvent getEquipSound()- Specified by:
getEquipSoundin interfacenet.minecraft.item.ArmorMaterial
-
getRepairIngredient
public net.minecraft.recipe.Ingredient getRepairIngredient()- Specified by:
getRepairIngredientin interfacenet.minecraft.item.ArmorMaterial
-
getName
- Specified by:
getNamein interfacenet.minecraft.item.ArmorMaterial
-
getToughness
public float getToughness()- Specified by:
getToughnessin interfacenet.minecraft.item.ArmorMaterial
-
getKnockbackResistance
public float getKnockbackResistance()- Specified by:
getKnockbackResistancein interfacenet.minecraft.item.ArmorMaterial
-