Package net.minecraft.enchantment
Class ThornsEnchantment
java.lang.Object
net.minecraft.enchantment.Enchantment
net.minecraft.enchantment.ThornsEnchantment
public class ThornsEnchantment extends Enchantment
- Mappings:
Namespace Name official bucintermediary net/minecraft/class_1906named net/minecraft/enchantment/ThornsEnchantment
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.enchantment.Enchantment
Enchantment.Rarity -
Field Summary
Fields Modifier and Type Field Description private static floatATTACK_CHANCE_PER_LEVELFields inherited from class net.minecraft.enchantment.Enchantment
translationKey, type -
Constructor Summary
Constructors Constructor Description ThornsEnchantment(Enchantment.Rarity weight, EquipmentSlot[] slotTypes) -
Method Summary
Modifier and Type Method Description static intgetDamageAmount(int level, Random random)intgetMaxLevel()intgetMaxPower(int level)intgetMinPower(int level)booleanisAcceptableItem(ItemStack stack)voidonUserDamaged(LivingEntity user, Entity attacker, int level)static booleanshouldDamageAttacker(int level, Random random)Methods inherited from class net.minecraft.enchantment.Enchantment
byRawId, canAccept, canCombine, getAttackDamage, getEquipment, getMinLevel, getName, getOrCreateTranslationKey, getProtectionAmount, getRarity, getTranslationKey, isAvailableForEnchantedBookOffer, isAvailableForRandomSelection, isCursed, isTreasure, onTargetDamaged
-
Field Details
-
ATTACK_CHANCE_PER_LEVEL
private static final float ATTACK_CHANCE_PER_LEVEL- See Also:
- Constant Field Values
- Mappings:
Namespace Name Mixin selector official aLbuc;a:Fintermediary field_30950Lnet/minecraft/class_1906;field_30950:Fnamed ATTACK_CHANCE_PER_LEVELLnet/minecraft/enchantment/ThornsEnchantment;ATTACK_CHANCE_PER_LEVEL:F
-
-
Constructor Details
-
ThornsEnchantment
- Mappings:
Namespace Name Mixin selector official <init>Lbuc;<init>(Lbtl$a;[Lasq;)Vintermediary <init>Lnet/minecraft/class_1906;<init>(Lnet/minecraft/class_1887$class_1888;[Lnet/minecraft/class_1304;)Vnamed <init>Lnet/minecraft/enchantment/ThornsEnchantment;<init>(Lnet/minecraft/enchantment/Enchantment$Rarity;[Lnet/minecraft/entity/EquipmentSlot;)V
-
-
Method Details
-
getMinPower
public int getMinPower(int level)- Overrides:
getMinPowerin classEnchantment- Mappings:
Namespace Name Mixin selector official aLbtl;a(I)Iintermediary method_8182Lnet/minecraft/class_1887;method_8182(I)Inamed getMinPowerLnet/minecraft/enchantment/Enchantment;getMinPower(I)I
-
getMaxPower
public int getMaxPower(int level)- Overrides:
getMaxPowerin classEnchantment- Mappings:
Namespace Name Mixin selector official bLbtl;b(I)Iintermediary method_20742Lnet/minecraft/class_1887;method_20742(I)Inamed getMaxPowerLnet/minecraft/enchantment/Enchantment;getMaxPower(I)I
-
getMaxLevel
public int getMaxLevel()- Overrides:
getMaxLevelin classEnchantment- Mappings:
Namespace Name Mixin selector official aLbtl;a()Iintermediary method_8183Lnet/minecraft/class_1887;method_8183()Inamed getMaxLevelLnet/minecraft/enchantment/Enchantment;getMaxLevel()I
-
isAcceptableItem
- Overrides:
isAcceptableItemin classEnchantment- Mappings:
Namespace Name Mixin selector official aLbtl;a(Lbpr;)Zintermediary method_8192Lnet/minecraft/class_1887;method_8192(Lnet/minecraft/class_1799;)Znamed isAcceptableItemLnet/minecraft/enchantment/Enchantment;isAcceptableItem(Lnet/minecraft/item/ItemStack;)Z
-
onUserDamaged
- Overrides:
onUserDamagedin classEnchantment- Mappings:
Namespace Name Mixin selector official bLbtl;b(Lasy;Lasl;I)Vintermediary method_8178Lnet/minecraft/class_1887;method_8178(Lnet/minecraft/class_1309;Lnet/minecraft/class_1297;I)Vnamed onUserDamagedLnet/minecraft/enchantment/Enchantment;onUserDamaged(Lnet/minecraft/entity/LivingEntity;Lnet/minecraft/entity/Entity;I)V
-
shouldDamageAttacker
- Mappings:
Namespace Name Mixin selector official aLbuc;a(ILjava/util/Random;)Zintermediary method_8243Lnet/minecraft/class_1906;method_8243(ILjava/util/Random;)Znamed shouldDamageAttackerLnet/minecraft/enchantment/ThornsEnchantment;shouldDamageAttacker(ILjava/util/Random;)Z
-
getDamageAmount
- Mappings:
Namespace Name Mixin selector official bLbuc;b(ILjava/util/Random;)Iintermediary method_8242Lnet/minecraft/class_1906;method_8242(ILjava/util/Random;)Inamed getDamageAmountLnet/minecraft/enchantment/ThornsEnchantment;getDamageAmount(ILjava/util/Random;)I
-