-
Notifications
You must be signed in to change notification settings - Fork 0
Armors
VadamDev edited this page Oct 7, 2022
·
2 revisions
public class ExempleHelmetItem extends CustomArmorPart {
public ExempleHelmetItem() {
//Note 1: The armor type is the base material of the armor (DIAMOND, IRON, etc...)
super(ArmorType.DIAMOND, ArmorPart.HELMET, "Exemple Custom Helmet", "lorem", "%bar%");
}
@Override
public boolean onHolderDamaged(Player player, Entity damager, ItemStack item) {
//Note: If you're overriding this method, dont forget to keep this super.
super.onHolderDamaged(player, damager, item);
return false;
}
//The custom armor max durability
@Override
public int getMaxDurability() {
return 1100;
}
//An optional method for handling durability bars, see the wiki for more informations.
@Override
public IDurabilityBar getDurabilityBar() {
return new NumberMinecraftDurabilityBar("%bar%");
}
@Override
public String getRegistryName() {
return "demonite_helmet";
}
}- Items
- Foods
- Armors Parts
-
- Armor Sets
- Durability Provider
-
- Durability Bar
- Blocks
-
- Block (Soon...)
-
- Tile Entity (Soon...)
- Shaped Recipe
- Shapeless Recipe