net.minecraft.world.item.enchantment

public class EnchantmentHelper

chs
net.minecraft.world.item.enchantment.EnchantmentHelper
net.minecraft.class_1890
net.minecraft.unmapped.C_jakrppis
net.minecraft.enchantment.EnchantmentHelper
net.minecraft.enchantment.EnchantmentHelper
net.minecraft.src.C_1522_
net.minecraft.world.item.enchantment.EnchantmentManager

Field summary

Modifier and TypeField
private static final String
a
TAG_ENCH_ID
field_34025
f_rlppivpx
ID_KEY
ID_KEY
f_182430_
private static final String
b
TAG_ENCH_LEVEL
field_34026
f_yomtzqup
LEVEL_KEY
LEVEL_KEY
f_182431_
private static final float
c
SWIFT_SNEAK_EXTRA_FACTOR
field_38222
f_afoqjohi
field_38222
SWIFT_SNEAK_EXTRA_FACTOR
f_220286_

Constructor summary

ModifierConstructor
public ()

Method summary

Modifier and TypeMethod
public static CompoundTag
a(acf arg0, int arg1)
storeEnchantment(ResourceLocation arg0, int arg1)
method_37426(class_2960 arg0, int arg1)
m_akimufno(C_ncpywfca arg0, int arg1)
createNbt(Identifier id, int lvl)
createNbt(Identifier id, int lvl)
m_182443_(C_5265_ p_182444_, int p_182445_)
public static void
a(qp arg0, int arg1)
setEnchantmentLevel(CompoundTag arg0, int arg1)
method_37425(class_2487 arg0, int arg1)
m_ckuzsaet(C_hhlwcnih arg0, int arg1)
writeLevelToNbt(NbtCompound nbt, int lvl)
writeLevelToNbt(NbtCompound nbt, int lvl)
m_182440_(C_4917_ p_182441_, int p_182442_)
public static int
a(qp arg0)
getEnchantmentLevel(CompoundTag arg0)
method_37424(class_2487 arg0)
m_zkwupylq(C_hhlwcnih arg0)
getLevelFromNbt(NbtCompound nbt)
getLevelFromNbt(NbtCompound nbt)
m_182438_(C_4917_ p_182439_)
public static ResourceLocation
b(qp arg0)
getEnchantmentId(CompoundTag arg0)
method_37427(class_2487 arg0)
m_ilwqaoek(C_hhlwcnih arg0)
getIdFromNbt(NbtCompound nbt)
getIdFromNbt(NbtCompound nbt)
m_182446_(C_4917_ p_182447_)
public static ResourceLocation
a(chq arg0)
getEnchantmentId(Enchantment arg0)
method_37423(class_1887 arg0)
m_bwzjzjqu(C_jxtrubuh arg0)
getEnchantmentId(Enchantment enchantment)
getEnchantmentId(Enchantment enchantment)
m_182432_(C_1505_ p_182433_)
public static int
a(chq arg0, cdt arg1)
getItemEnchantmentLevel(Enchantment arg0, ItemStack arg1)
method_8225(class_1887 arg0, class_1799 arg1)
m_byjosehc(C_jxtrubuh arg0, C_sddaxwyk arg1)
getLevel(Enchantment enchantment, ItemStack stack)
getLevel(Enchantment enchantment, ItemStack stack)
m_44843_(C_1505_ p_44844_, C_1391_ p_44845_)
public static Map<Enchantment, Integer>
a(cdt arg0)
getEnchantments(ItemStack arg0)
method_8222(class_1799 arg0)
m_nvnojfze(C_sddaxwyk arg0)
get(ItemStack stack)
get(ItemStack stack)
m_44831_(C_1391_ p_44832_)
public static Map<Enchantment, Integer>
a(qv arg0)
deserializeEnchantments(ListTag arg0)
method_22445(class_2499 arg0)
m_uiyvmdhm(C_hqhtfwlr arg0)
fromNbt(NbtList list)
fromNbt(NbtList list)
m_44882_(C_4930_ p_44883_)
public static void
a(Map<chq, Integer> arg0, cdt arg1)
setEnchantments(Map<Enchantment, Integer> arg0, ItemStack arg1)
method_8214(Map<class_1887, Integer> arg0, class_1799 arg1)
m_ybhxtwqv(Map<C_jxtrubuh, Integer> arg0, C_sddaxwyk arg1)
set(Map<Enchantment, Integer> enchantments, ItemStack stack)
set(Map<Enchantment, Integer> enchantments, ItemStack stack)
m_44865_(Map<C_1505_, Integer> p_44866_, C_1391_ p_44867_)
private static void
a(chs$a arg0, cdt arg1)
runIterationOnItem(EnchantmentHelper$EnchantmentVisitor arg0, ItemStack arg1)
method_8220(class_1890$class_1891 arg0, class_1799 arg1)
m_mnatputa(C_jakrppis$C_jdhxivxn arg0, C_sddaxwyk arg1)
forEachEnchantment(EnchantmentHelper$Consumer consumer, ItemStack stack)
forEachEnchantment(EnchantmentHelper$Consumer consumer, ItemStack stack)
m_44850_(C_1522_$C_1523_ p_44851_, C_1391_ p_44852_)
private static void
a(chs$a arg0, Iterable<cdt> arg1)
runIterationOnInventory(EnchantmentHelper$EnchantmentVisitor arg0, Iterable<ItemStack> arg1)
method_8209(class_1890$class_1891 arg0, Iterable<class_1799> arg1)
m_jewispmg(C_jakrppis$C_jdhxivxn arg0, Iterable<C_sddaxwyk> arg1)
forEachEnchantment(EnchantmentHelper$Consumer consumer, Iterable<ItemStack> stacks)
forEachEnchantment(EnchantmentHelper$Consumer consumer, Iterable<ItemStack> stacks)
m_44853_(C_1522_$C_1523_ p_44854_, Iterable<C_1391_> p_44855_)
public static int
a(Iterable<cdt> arg0, bcz arg1)
getDamageProtection(Iterable<ItemStack> arg0, DamageSource arg1)
method_8219(Iterable<class_1799> arg0, class_1282 arg1)
m_jfbiswcz(Iterable<C_sddaxwyk> arg0, C_sbxfkpyv arg1)
getProtectionAmount(Iterable<ItemStack> equipment, DamageSource source)
getProtectionAmount(Iterable<ItemStack> equipment, DamageSource source)
m_44856_(Iterable<C_1391_> p_44857_, C_489_ p_44858_)
public static float
a(cdt arg0, bel arg1)
getDamageBonus(ItemStack arg0, MobType arg1)
method_8218(class_1799 arg0, class_1310 arg1)
m_pdpzdulw(C_sddaxwyk arg0, C_amnulxyk arg1)
getAttackDamage(ItemStack stack, EntityGroup group)
getAttackDamage(ItemStack stack, EntityGroup group)
m_44833_(C_1391_ p_44834_, C_530_ p_44835_)
public static float
a(beg arg0)
getSweepingDamageRatio(LivingEntity arg0)
method_8217(class_1309 arg0)
m_joncevqu(C_usxaxydn arg0)
getSweepingMultiplier(LivingEntity entity)
getSweepingMultiplier(LivingEntity entity)
m_44821_(C_524_ p_44822_)
public static void
a(beg arg0, bdr arg1)
doPostHurtEffects(LivingEntity arg0, Entity arg1)
method_8210(class_1309 arg0, class_1297 arg1)
m_gfmalqgf(C_usxaxydn arg0, C_astfners arg1)
onUserDamaged(LivingEntity user, Entity attacker)
onUserDamaged(LivingEntity user, Entity attacker)
m_44823_(C_524_ p_44824_, C_507_ p_44825_)
public static void
b(beg arg0, bdr arg1)
doPostDamageEffects(LivingEntity arg0, Entity arg1)
method_8213(class_1309 arg0, class_1297 arg1)
m_ysxfxsjj(C_usxaxydn arg0, C_astfners arg1)
onTargetDamaged(LivingEntity user, Entity target)
onTargetDamaged(LivingEntity user, Entity target)
m_44896_(C_524_ p_44897_, C_507_ p_44898_)
public static int
a(chq arg0, beg arg1)
getEnchantmentLevel(Enchantment arg0, LivingEntity arg1)
method_8203(class_1887 arg0, class_1309 arg1)
m_lmhmcuxl(C_jxtrubuh arg0, C_usxaxydn arg1)
getEquipmentLevel(Enchantment enchantment, LivingEntity entity)
getEquipmentLevel(Enchantment enchantment, LivingEntity entity)
m_44836_(C_1505_ p_44837_, C_524_ p_44838_)
public static float
b(beg arg0)
getSneakingSpeedBonus(LivingEntity arg0)
method_42304(class_1309 arg0)
m_zmhvmqxg(C_usxaxydn arg0)
getSwiftSneakSpeedBoost(LivingEntity arg0)
getSwiftSneak(LivingEntity entity)
m_220302_(C_524_ p_220303_)
public static int
c(beg arg0)
getKnockbackBonus(LivingEntity arg0)
method_8205(class_1309 arg0)
m_ktvqzwtx(C_usxaxydn arg0)
getKnockback(LivingEntity entity)
getKnockback(LivingEntity entity)
m_44894_(C_524_ p_44895_)
public static int
d(beg arg0)
getFireAspect(LivingEntity arg0)
method_8199(class_1309 arg0)
m_knenpeym(C_usxaxydn arg0)
getFireAspect(LivingEntity entity)
getFireAspect(LivingEntity entity)
m_44914_(C_524_ p_44915_)
public static int
e(beg arg0)
getRespiration(LivingEntity arg0)
method_8211(class_1309 arg0)
m_iaspatfp(C_usxaxydn arg0)
getRespiration(LivingEntity entity)
getRespiration(LivingEntity entity)
m_44918_(C_524_ p_44919_)
public static int
f(beg arg0)
getDepthStrider(LivingEntity arg0)
method_8232(class_1309 arg0)
m_txkgdgaa(C_usxaxydn arg0)
getDepthStrider(LivingEntity entity)
getDepthStrider(LivingEntity entity)
m_44922_(C_524_ p_44923_)
public static int
g(beg arg0)
getBlockEfficiency(LivingEntity arg0)
method_8234(class_1309 arg0)
m_qlkrewkt(C_usxaxydn arg0)
getEfficiency(LivingEntity entity)
getEfficiency(LivingEntity entity)
m_44926_(C_524_ p_44927_)
public static int
b(cdt arg0)
getFishingLuckBonus(ItemStack arg0)
method_8223(class_1799 arg0)
m_qhyhygvf(C_sddaxwyk arg0)
getLuckOfTheSea(ItemStack stack)
getLuckOfTheSea(ItemStack stack)
m_44904_(C_1391_ p_44905_)
public static int
c(cdt arg0)
getFishingSpeedBonus(ItemStack arg0)
method_8215(class_1799 arg0)
m_kfuscpev(C_sddaxwyk arg0)
getLure(ItemStack stack)
getLure(ItemStack stack)
m_44916_(C_1391_ p_44917_)
public static int
h(beg arg0)
getMobLooting(LivingEntity arg0)
method_8226(class_1309 arg0)
m_jfzsayrx(C_usxaxydn arg0)
getLooting(LivingEntity entity)
getLooting(LivingEntity entity)
m_44930_(C_524_ p_44931_)
public static boolean
i(beg arg0)
hasAquaAffinity(LivingEntity arg0)
method_8200(class_1309 arg0)
m_zpauplkq(C_usxaxydn arg0)
hasAquaAffinity(LivingEntity entity)
hasAquaAffinity(LivingEntity entity)
m_44934_(C_524_ p_44935_)
public static boolean
j(beg arg0)
hasFrostWalker(LivingEntity arg0)
method_8216(class_1309 arg0)
m_cwzufrfa(C_usxaxydn arg0)
hasFrostWalker(LivingEntity entity)
hasFrostWalker(LivingEntity entity)
m_44938_(C_524_ p_44939_)
public static boolean
k(beg arg0)
hasSoulSpeed(LivingEntity arg0)
method_25951(class_1309 arg0)
m_vonozfhq(C_usxaxydn arg0)
hasSoulSpeed(LivingEntity entity)
hasSoulSpeed(LivingEntity entity)
m_44942_(C_524_ p_44943_)
public static boolean
d(cdt arg0)
hasBindingCurse(ItemStack arg0)
method_8224(class_1799 arg0)
m_nmfzbmmv(C_sddaxwyk arg0)
hasBindingCurse(ItemStack stack)
hasBindingCurse(ItemStack stack)
m_44920_(C_1391_ p_44921_)
public static boolean
e(cdt arg0)
hasVanishingCurse(ItemStack arg0)
method_8221(class_1799 arg0)
m_kkmhqorr(C_sddaxwyk arg0)
hasVanishingCurse(ItemStack stack)
hasVanishingCurse(ItemStack stack)
m_44924_(C_1391_ p_44925_)
public static int
f(cdt arg0)
getLoyalty(ItemStack arg0)
method_8206(class_1799 arg0)
m_ebcyaldp(C_sddaxwyk arg0)
getLoyalty(ItemStack stack)
getLoyalty(ItemStack stack)
m_44928_(C_1391_ p_44929_)
public static int
g(cdt arg0)
getRiptide(ItemStack arg0)
method_8202(class_1799 arg0)
m_ogntvpbr(C_sddaxwyk arg0)
getRiptide(ItemStack stack)
getRiptide(ItemStack stack)
m_44932_(C_1391_ p_44933_)
public static boolean
h(cdt arg0)
hasChanneling(ItemStack arg0)
method_8228(class_1799 arg0)
m_aeqkynka(C_sddaxwyk arg0)
hasChanneling(ItemStack stack)
hasChanneling(ItemStack stack)
m_44936_(C_1391_ p_44937_)
public static Map$Entry<EquipmentSlot, ItemStack>
b(chq arg0, beg arg1)
getRandomItemWith(Enchantment arg0, LivingEntity arg1)
method_8204(class_1887 arg0, class_1309 arg1)
m_ymaphuvh(C_jxtrubuh arg0, C_usxaxydn arg1)
chooseEquipmentWith(Enchantment enchantment, LivingEntity entity)
chooseEquipmentWith(Enchantment enchantment, LivingEntity entity)
m_44906_(C_1505_ p_44907_, C_524_ p_44908_)
public static Map$Entry<EquipmentSlot, ItemStack>
a(chq arg0, beg arg1, Predicate<cdt> arg2)
getRandomItemWith(Enchantment arg0, LivingEntity arg1, Predicate<ItemStack> arg2)
method_24365(class_1887 arg0, class_1309 arg1, Predicate<class_1799> arg2)
m_mieewhwi(C_jxtrubuh arg0, C_usxaxydn arg1, Predicate<C_sddaxwyk> arg2)
chooseEquipmentWith(Enchantment enchantment, LivingEntity entity, Predicate<ItemStack> condition)
chooseEquipmentWith(Enchantment enchantment, LivingEntity entity, Predicate<ItemStack> condition)
m_44839_(C_1505_ p_44840_, C_524_ p_44841_, Predicate<C_1391_> p_44842_)
public static int
a(aoh arg0, int arg1, int arg2, cdt arg3)
getEnchantmentCost(RandomSource arg0, int arg1, int arg2, ItemStack arg3)
method_8227(class_5819 arg0, int arg1, int arg2, class_1799 arg3)
m_pcunrpng(C_rlomrsco arg0, int arg1, int arg2, C_sddaxwyk arg3)
calculateRequiredExperienceLevel(Random random, int slotIndex, int bookshelfCount, ItemStack stack)
calculateRequiredExperienceLevel(RandomGenerator random, int slotIndex, int bookshelfCount, ItemStack stack)
m_220287_(C_212974_ p_220288_, int p_220289_, int p_220290_, C_1391_ p_220291_)
public static ItemStack
a(aoh arg0, cdt arg1, int arg2, boolean arg3)
enchantItem(RandomSource arg0, ItemStack arg1, int arg2, boolean arg3)
method_8233(class_5819 arg0, class_1799 arg1, int arg2, boolean arg3)
m_naelqumb(C_rlomrsco arg0, C_sddaxwyk arg1, int arg2, boolean arg3)
enchant(Random random, ItemStack target, int level, boolean treasureAllowed)
enchant(RandomGenerator random, ItemStack target, int level, boolean treasureAllowed)
m_220292_(C_212974_ p_220293_, C_1391_ p_220294_, int p_220295_, boolean p_220296_)
public static List<EnchantmentInstance>
b(aoh arg0, cdt arg1, int arg2, boolean arg3)
selectEnchantment(RandomSource arg0, ItemStack arg1, int arg2, boolean arg3)
method_8230(class_5819 arg0, class_1799 arg1, int arg2, boolean arg3)
m_udfcqeza(C_rlomrsco arg0, C_sddaxwyk arg1, int arg2, boolean arg3)
generateEnchantments(Random random, ItemStack stack, int level, boolean treasureAllowed)
generateEnchantments(RandomGenerator random, ItemStack stack, int level, boolean treasureAllowed)
m_220297_(C_212974_ p_220298_, C_1391_ p_220299_, int p_220300_, boolean p_220301_)
public static void
a(List<cht> arg0, cht arg1)
filterCompatibleEnchantments(List<EnchantmentInstance> arg0, EnchantmentInstance arg1)
method_8231(List<class_1889> arg0, class_1889 arg1)
m_pdlnvjwf(List<C_gsnkkurc> arg0, C_gsnkkurc arg1)
removeConflicts(List<EnchantmentLevelEntry> possibleEntries, EnchantmentLevelEntry pickedEntry)
removeConflicts(List<EnchantmentLevelEntry> possibleEntries, EnchantmentLevelEntry pickedEntry)
m_44862_(List<C_1524_> p_44863_, C_1524_ p_44864_)
public static boolean
a(Collection<chq> arg0, chq arg1)
isEnchantmentCompatible(Collection<Enchantment> arg0, Enchantment arg1)
method_8201(Collection<class_1887> arg0, class_1887 arg1)
m_ecxgwxiu(Collection<C_jxtrubuh> arg0, C_jxtrubuh arg1)
isCompatible(Collection<Enchantment> existing, Enchantment candidate)
isCompatible(Collection<Enchantment> existing, Enchantment candidate)
m_44859_(Collection<C_1505_> p_44860_, C_1505_ p_44861_)
public static List<EnchantmentInstance>
a(int arg0, cdt arg1, boolean arg2)
getAvailableEnchantmentResults(int arg0, ItemStack arg1, boolean arg2)
method_8229(int arg0, class_1799 arg1, boolean arg2)
m_pngonrhw(int arg0, C_sddaxwyk arg1, boolean arg2)
getPossibleEntries(int power, ItemStack stack, boolean treasureAllowed)
getPossibleEntries(int power, ItemStack stack, boolean treasureAllowed)
m_44817_(int p_44818_, C_1391_ p_44819_, boolean p_44820_)