Class ProtectionEnchantment

java.lang.Object
net.minecraft.enchantment.Enchantment
net.minecraft.enchantment.ProtectionEnchantment

public class ProtectionEnchantment extends Enchantment
Mappings:
Namespace Name
official ckt
intermediary net/minecraft/class_1900
named net/minecraft/enchantment/ProtectionEnchantment
  • Field Details

    • protectionType

      public final ProtectionEnchantment.Type protectionType
      Mappings:
      Namespace Name Mixin selector
      official a Lckt;a:Lckt$a;
      intermediary field_9133 Lnet/minecraft/class_1900;field_9133:Lnet/minecraft/class_1900$class_1901;
      named protectionType Lnet/minecraft/enchantment/ProtectionEnchantment;protectionType:Lnet/minecraft/enchantment/ProtectionEnchantment$Type;
  • Constructor Details

    • ProtectionEnchantment

      public ProtectionEnchantment(Enchantment.Rarity weight, ProtectionEnchantment.Type protectionType, EquipmentSlot[] slotTypes)
      Mappings:
      Namespace Name Mixin selector
      official <init> Lckt;<init>(Lckg$a;Lckt$a;[Lbfo;)V
      intermediary <init> Lnet/minecraft/class_1900;<init>(Lnet/minecraft/class_1887$class_1888;Lnet/minecraft/class_1900$class_1901;[Lnet/minecraft/class_1304;)V
      named <init> Lnet/minecraft/enchantment/ProtectionEnchantment;<init>(Lnet/minecraft/enchantment/Enchantment$Rarity;Lnet/minecraft/enchantment/ProtectionEnchantment$Type;[Lnet/minecraft/entity/EquipmentSlot;)V
  • Method Details

    • getMinPower

      public int getMinPower(int level)
      Overrides:
      getMinPower in class Enchantment
      Mappings:
      Namespace Name Mixin selector
      official a Lckg;a(I)I
      intermediary method_8182 Lnet/minecraft/class_1887;method_8182(I)I
      named getMinPower Lnet/minecraft/enchantment/Enchantment;getMinPower(I)I
    • getMaxPower

      public int getMaxPower(int level)
      Overrides:
      getMaxPower in class Enchantment
      Mappings:
      Namespace Name Mixin selector
      official b Lckg;b(I)I
      intermediary method_20742 Lnet/minecraft/class_1887;method_20742(I)I
      named getMaxPower Lnet/minecraft/enchantment/Enchantment;getMaxPower(I)I
    • getMaxLevel

      public int getMaxLevel()
      Overrides:
      getMaxLevel in class Enchantment
      Mappings:
      Namespace Name Mixin selector
      official a Lckg;a()I
      intermediary method_8183 Lnet/minecraft/class_1887;method_8183()I
      named getMaxLevel Lnet/minecraft/enchantment/Enchantment;getMaxLevel()I
    • getProtectionAmount

      public int getProtectionAmount(int level, DamageSource source)
      Overrides:
      getProtectionAmount in class Enchantment
      Mappings:
      Namespace Name Mixin selector
      official a Lckg;a(ILben;)I
      intermediary method_8181 Lnet/minecraft/class_1887;method_8181(ILnet/minecraft/class_1282;)I
      named getProtectionAmount Lnet/minecraft/enchantment/Enchantment;getProtectionAmount(ILnet/minecraft/entity/damage/DamageSource;)I
    • canAccept

      public boolean canAccept(Enchantment other)
      Returns whether this enchantment can exist on an item stack with the other enchantment.
      Overrides:
      canAccept in class Enchantment
      Returns:
      whether this enchantment can exist on an item stack with the other enchantment
      Mappings:
      Namespace Name Mixin selector
      official a Lckg;a(Lckg;)Z
      intermediary method_8180 Lnet/minecraft/class_1887;method_8180(Lnet/minecraft/class_1887;)Z
      named canAccept Lnet/minecraft/enchantment/Enchantment;canAccept(Lnet/minecraft/enchantment/Enchantment;)Z
    • transformFireDuration

      public static int transformFireDuration(LivingEntity entity, int duration)
      Mappings:
      Namespace Name Mixin selector
      official a Lckt;a(Lbfz;I)I
      intermediary method_8238 Lnet/minecraft/class_1900;method_8238(Lnet/minecraft/class_1309;I)I
      named transformFireDuration Lnet/minecraft/enchantment/ProtectionEnchantment;transformFireDuration(Lnet/minecraft/entity/LivingEntity;I)I
    • transformExplosionKnockback

      public static double transformExplosionKnockback(LivingEntity entity, double velocity)
      Mappings:
      Namespace Name Mixin selector
      official a Lckt;a(Lbfz;D)D
      intermediary method_8237 Lnet/minecraft/class_1900;method_8237(Lnet/minecraft/class_1309;D)D
      named transformExplosionKnockback Lnet/minecraft/enchantment/ProtectionEnchantment;transformExplosionKnockback(Lnet/minecraft/entity/LivingEntity;D)D