Uses of Class
net.minecraft.enchantment.Enchantment
Packages that use Enchantment
Package
Description
-
Uses of Enchantment in net.minecraft.command.argument
Methods in net.minecraft.command.argument that return EnchantmentModifier and TypeMethodDescriptionstatic EnchantmentEnchantmentArgumentType.getEnchantment(com.mojang.brigadier.context.CommandContext<ServerCommandSource> context, String name)EnchantmentArgumentType.parse(com.mojang.brigadier.StringReader stringReader) -
Uses of Enchantment in net.minecraft.enchantment
Subclasses of Enchantment in net.minecraft.enchantmentModifier and TypeClassDescriptionclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassclassFields in net.minecraft.enchantment declared as EnchantmentModifier and TypeFieldDescriptionstatic EnchantmentEnchantments.AQUA_AFFINITYstatic EnchantmentEnchantments.BANE_OF_ARTHROPODSstatic EnchantmentEnchantments.BINDING_CURSEstatic EnchantmentEnchantments.BLAST_PROTECTIONstatic EnchantmentEnchantments.CHANNELINGstatic EnchantmentEnchantments.DEPTH_STRIDERstatic EnchantmentEnchantments.EFFICIENCYEnchantmentLevelEntry.enchantmentstatic EnchantmentEnchantments.FEATHER_FALLINGstatic EnchantmentEnchantments.FIRE_ASPECTstatic EnchantmentEnchantments.FIRE_PROTECTIONstatic EnchantmentEnchantments.FLAMEstatic EnchantmentEnchantments.FORTUNEstatic EnchantmentEnchantments.FROST_WALKERstatic EnchantmentEnchantments.IMPALINGstatic EnchantmentEnchantments.INFINITYstatic EnchantmentEnchantments.KNOCKBACKstatic EnchantmentEnchantments.LOOTINGstatic EnchantmentEnchantments.LOYALTYstatic EnchantmentEnchantments.LUCK_OF_THE_SEAstatic EnchantmentEnchantments.LUREstatic EnchantmentEnchantments.MENDINGstatic EnchantmentEnchantments.MULTISHOTstatic EnchantmentEnchantments.PIERCINGstatic EnchantmentEnchantments.POWERstatic EnchantmentEnchantments.PROJECTILE_PROTECTIONstatic EnchantmentEnchantments.PROTECTIONstatic EnchantmentEnchantments.PUNCHstatic EnchantmentEnchantments.QUICK_CHARGEstatic EnchantmentEnchantments.RESPIRATIONstatic EnchantmentEnchantments.RIPTIDEstatic EnchantmentEnchantments.SHARPNESSstatic EnchantmentEnchantments.SILK_TOUCHstatic EnchantmentEnchantments.SMITEstatic EnchantmentEnchantments.SOUL_SPEEDstatic EnchantmentEnchantments.SWEEPINGstatic EnchantmentEnchantments.THORNSstatic EnchantmentEnchantments.UNBREAKINGstatic EnchantmentEnchantments.VANISHING_CURSEMethods in net.minecraft.enchantment that return EnchantmentModifier and TypeMethodDescriptionstatic @Nullable EnchantmentEnchantment.byRawId(int id)private static EnchantmentEnchantments.register(String name, Enchantment enchantment)Methods in net.minecraft.enchantment that return types with arguments of type EnchantmentModifier and TypeMethodDescriptionstatic Map<Enchantment,Integer>Loads enchantments from an NBT list.static Map<Enchantment,Integer>Gets the enchantments on an item stack.Methods in net.minecraft.enchantment with parameters of type EnchantmentModifier and TypeMethodDescriptionvoidEnchantmentHelper.Consumer.accept(Enchantment enchantment, int level)booleanDamageEnchantment.canAccept(Enchantment other)Returns whether this enchantment can exist on an item stack with theotherenchantment.booleanDepthStriderEnchantment.canAccept(Enchantment other)Returns whether this enchantment can exist on an item stack with theotherenchantment.protected booleanEnchantment.canAccept(Enchantment other)Returns whether this enchantment can exist on an item stack with theotherenchantment.booleanFrostWalkerEnchantment.canAccept(Enchantment other)Returns whether this enchantment can exist on an item stack with theotherenchantment.booleanInfinityEnchantment.canAccept(Enchantment other)Returns whether this enchantment can exist on an item stack with theotherenchantment.booleanLuckEnchantment.canAccept(Enchantment other)Returns whether this enchantment can exist on an item stack with theotherenchantment.booleanMultishotEnchantment.canAccept(Enchantment other)Returns whether this enchantment can exist on an item stack with theotherenchantment.booleanPiercingEnchantment.canAccept(Enchantment other)Returns whether this enchantment can exist on an item stack with theotherenchantment.booleanProtectionEnchantment.canAccept(Enchantment other)Returns whether this enchantment can exist on an item stack with theotherenchantment.booleanRiptideEnchantment.canAccept(Enchantment other)Returns whether this enchantment can exist on an item stack with theotherenchantment.booleanSilkTouchEnchantment.canAccept(Enchantment other)Returns whether this enchantment can exist on an item stack with theotherenchantment.booleanEnchantment.canCombine(Enchantment other)Returns whether this enchantment can exist on an item stack with theotherenchantment and theotherenchantment can exist with this enchantment.static Map.Entry<EquipmentSlot,ItemStack>EnchantmentHelper.chooseEquipmentWith(Enchantment enchantment, LivingEntity entity)Returns a pair of an equipment slot and the item stack in the supplied entity's slot, indicating the item stack has the enchantment supplied.static Map.Entry<EquipmentSlot,ItemStack>EnchantmentHelper.chooseEquipmentWith(Enchantment enchantment, LivingEntity entity, Predicate<ItemStack> condition)Returns a pair of an equipment slot and the item stack in the supplied entity's slot, indicating the item stack has the enchantment supplied and fulfills the extra condition.static intEnchantmentHelper.getEquipmentLevel(Enchantment enchantment, LivingEntity entity)Returns the highest level of the passed enchantment in the enchantment's applicable equipment slots' item stacks.static intEnchantmentHelper.getLevel(Enchantment enchantment, ItemStack stack)Gets the level of an enchantment on an item stack.static booleanEnchantmentHelper.isCompatible(Collection<Enchantment> existing, Enchantment candidate)Returns whether thecandidateenchantment is compatible with theexistingenchantments.private static EnchantmentEnchantments.register(String name, Enchantment enchantment)Method parameters in net.minecraft.enchantment with type arguments of type EnchantmentModifier and TypeMethodDescriptionstatic booleanEnchantmentHelper.isCompatible(Collection<Enchantment> existing, Enchantment candidate)Returns whether thecandidateenchantment is compatible with theexistingenchantments.static voidEnchantmentHelper.set(Map<Enchantment,Integer> enchantments, ItemStack stack)Sets the enchantments on an item stack.Constructors in net.minecraft.enchantment with parameters of type Enchantment -
Uses of Enchantment in net.minecraft.item
Methods in net.minecraft.item with parameters of type EnchantmentModifier and TypeMethodDescriptionvoidItemStack.addEnchantment(Enchantment enchantment, int level) -
Uses of Enchantment in net.minecraft.loot.condition
Fields in net.minecraft.loot.condition declared as EnchantmentModifier and TypeFieldDescription(package private) EnchantmentTableBonusLootCondition.enchantmentMethods in net.minecraft.loot.condition with parameters of type EnchantmentModifier and TypeMethodDescriptionstatic LootCondition.BuilderTableBonusLootCondition.builder(Enchantment enchantment, float[] chances)Constructors in net.minecraft.loot.condition with parameters of type EnchantmentModifierConstructorDescription(package private)TableBonusLootCondition(Enchantment enchantment, float[] float2) -
Uses of Enchantment in net.minecraft.loot.function
Fields in net.minecraft.loot.function declared as EnchantmentModifier and TypeFieldDescription(package private) EnchantmentApplyBonusLootFunction.enchantmentFields in net.minecraft.loot.function with type parameters of type EnchantmentModifier and TypeFieldDescriptionprivate Set<Enchantment>EnchantRandomlyLootFunction.Builder.enchantments(package private) List<Enchantment>EnchantRandomlyLootFunction.enchantmentsprivate Map<Enchantment,LootNumberProvider>SetEnchantmentsLootFunction.Builder.enchantments(package private) Map<Enchantment,LootNumberProvider>SetEnchantmentsLootFunction.enchantmentsMethods in net.minecraft.loot.function with parameters of type EnchantmentModifier and TypeMethodDescriptionEnchantRandomlyLootFunction.Builder.add(Enchantment enchantment)private static voidSetEnchantmentsLootFunction.addEnchantmentToMap(Map<Enchantment,Integer> map, Enchantment enchantment, int level)private static ItemStackEnchantRandomlyLootFunction.addEnchantmentToStack(ItemStack stack, Enchantment enchantment, Random random)static ConditionalLootFunction.Builder<?>ApplyBonusLootFunction.binomialWithBonusCount(Enchantment enchantment, float probability, int extra)SetEnchantmentsLootFunction.Builder.enchantment(Enchantment enchantment, LootNumberProvider level)static ConditionalLootFunction.Builder<?>ApplyBonusLootFunction.oreDrops(Enchantment enchantment)static ConditionalLootFunction.Builder<?>ApplyBonusLootFunction.uniformBonusCount(Enchantment enchantment)static ConditionalLootFunction.Builder<?>ApplyBonusLootFunction.uniformBonusCount(Enchantment enchantment, int bonusMultiplier)Method parameters in net.minecraft.loot.function with type arguments of type EnchantmentModifier and TypeMethodDescriptionprivate static voidSetEnchantmentsLootFunction.addEnchantmentToMap(Map<Enchantment,Integer> map, Enchantment enchantment, int level)Constructors in net.minecraft.loot.function with parameters of type EnchantmentModifierConstructorDescription(package private)ApplyBonusLootFunction(LootCondition[] lootCondition, Enchantment enchantment, ApplyBonusLootFunction.Formula formula)Constructor parameters in net.minecraft.loot.function with type arguments of type EnchantmentModifierConstructorDescription(package private)EnchantRandomlyLootFunction(LootCondition[] lootCondition, Collection<Enchantment> collection)(package private)SetEnchantmentsLootFunction(LootCondition[] lootCondition, Map<Enchantment,LootNumberProvider> map, boolean bool) -
Uses of Enchantment in net.minecraft.predicate.item
Fields in net.minecraft.predicate.item declared as EnchantmentMethod parameters in net.minecraft.predicate.item with type arguments of type EnchantmentModifier and TypeMethodDescriptionbooleanEnchantmentPredicate.test(Map<Enchantment,Integer> enchantments)Constructors in net.minecraft.predicate.item with parameters of type EnchantmentModifierConstructorDescriptionEnchantmentPredicate(@Nullable Enchantment enchantment, NumberRange.IntRange levels) -
Uses of Enchantment in net.minecraft.server.command
Methods in net.minecraft.server.command with parameters of type EnchantmentModifier and TypeMethodDescriptionprivate static intEnchantCommand.execute(ServerCommandSource source, Collection<? extends Entity> targets, Enchantment enchantment, int level) -
Uses of Enchantment in net.minecraft.util.registry
Fields in net.minecraft.util.registry with type parameters of type EnchantmentModifier and TypeFieldDescriptionstatic Registry<Enchantment>Registry.ENCHANTMENTstatic RegistryKey<Registry<Enchantment>>Registry.ENCHANTMENT_KEY