Uses of Class
org.bukkit.enchantments.Enchantment
Package
Description
Collection of registry entry types that may be created or modified via the
RegistryEvent
.The root package of the Bukkit API, contains generalized API classes.
Classes relating to the specialized enhancements to
item stacks
, as part of the meta data
.Events
triggered from an enchantment table
.Classes involved in manipulating player inventories and item interactions.
The interfaces used when manipulating extra data can can be stored inside
item stacks
.-
Uses of Enchantment in io.papermc.paper.registry
Modifier and TypeFieldDescriptionstatic final RegistryKey
<Enchantment> RegistryKey.ENCHANTMENT
Data-driven registry for enchantments. -
Uses of Enchantment in io.papermc.paper.registry.data
Modifier and TypeMethodDescriptionEnchantmentRegistryEntry.exclusiveWith()
Provides the registry key set of enchantments that this enchantment is exclusive with.Modifier and TypeMethodDescriptionEnchantmentRegistryEntry.Builder.exclusiveWith
(RegistryKeySet<Enchantment> exclusiveWith) Configures the registry key set of enchantments that this enchantment is exclusive with. -
Uses of Enchantment in io.papermc.paper.registry.event
Modifier and TypeFieldDescriptionstatic final RegistryEventProvider
<Enchantment, EnchantmentRegistryEntry.Builder> RegistryEvents.ENCHANTMENT
-
Uses of Enchantment in io.papermc.paper.registry.keys
Modifier and TypeFieldDescriptionstatic final TypedKey
<Enchantment> EnchantmentKeys.AQUA_AFFINITY
minecraft:aqua_affinity
static final TypedKey
<Enchantment> EnchantmentKeys.BANE_OF_ARTHROPODS
minecraft:bane_of_arthropods
static final TypedKey
<Enchantment> EnchantmentKeys.BINDING_CURSE
minecraft:binding_curse
static final TypedKey
<Enchantment> EnchantmentKeys.BLAST_PROTECTION
minecraft:blast_protection
static final TypedKey
<Enchantment> EnchantmentKeys.BREACH
minecraft:breach
static final TypedKey
<Enchantment> EnchantmentKeys.CHANNELING
minecraft:channeling
static final TypedKey
<Enchantment> EnchantmentKeys.DENSITY
minecraft:density
static final TypedKey
<Enchantment> EnchantmentKeys.DEPTH_STRIDER
minecraft:depth_strider
static final TypedKey
<Enchantment> EnchantmentKeys.EFFICIENCY
minecraft:efficiency
static final TypedKey
<Enchantment> EnchantmentKeys.FEATHER_FALLING
minecraft:feather_falling
static final TypedKey
<Enchantment> EnchantmentKeys.FIRE_ASPECT
minecraft:fire_aspect
static final TypedKey
<Enchantment> EnchantmentKeys.FIRE_PROTECTION
minecraft:fire_protection
static final TypedKey
<Enchantment> EnchantmentKeys.FLAME
minecraft:flame
static final TypedKey
<Enchantment> EnchantmentKeys.FORTUNE
minecraft:fortune
static final TypedKey
<Enchantment> EnchantmentKeys.FROST_WALKER
minecraft:frost_walker
static final TypedKey
<Enchantment> EnchantmentKeys.IMPALING
minecraft:impaling
static final TypedKey
<Enchantment> EnchantmentKeys.INFINITY
minecraft:infinity
static final TypedKey
<Enchantment> EnchantmentKeys.KNOCKBACK
minecraft:knockback
static final TypedKey
<Enchantment> EnchantmentKeys.LOOTING
minecraft:looting
static final TypedKey
<Enchantment> EnchantmentKeys.LOYALTY
minecraft:loyalty
static final TypedKey
<Enchantment> EnchantmentKeys.LUCK_OF_THE_SEA
minecraft:luck_of_the_sea
static final TypedKey
<Enchantment> EnchantmentKeys.LURE
minecraft:lure
static final TypedKey
<Enchantment> EnchantmentKeys.MENDING
minecraft:mending
static final TypedKey
<Enchantment> EnchantmentKeys.MULTISHOT
minecraft:multishot
static final TypedKey
<Enchantment> EnchantmentKeys.PIERCING
minecraft:piercing
static final TypedKey
<Enchantment> EnchantmentKeys.POWER
minecraft:power
static final TypedKey
<Enchantment> EnchantmentKeys.PROJECTILE_PROTECTION
minecraft:projectile_protection
static final TypedKey
<Enchantment> EnchantmentKeys.PROTECTION
minecraft:protection
static final TypedKey
<Enchantment> EnchantmentKeys.PUNCH
minecraft:punch
static final TypedKey
<Enchantment> EnchantmentKeys.QUICK_CHARGE
minecraft:quick_charge
static final TypedKey
<Enchantment> EnchantmentKeys.RESPIRATION
minecraft:respiration
static final TypedKey
<Enchantment> EnchantmentKeys.RIPTIDE
minecraft:riptide
static final TypedKey
<Enchantment> EnchantmentKeys.SHARPNESS
minecraft:sharpness
static final TypedKey
<Enchantment> EnchantmentKeys.SILK_TOUCH
minecraft:silk_touch
static final TypedKey
<Enchantment> EnchantmentKeys.SMITE
minecraft:smite
static final TypedKey
<Enchantment> EnchantmentKeys.SOUL_SPEED
minecraft:soul_speed
static final TypedKey
<Enchantment> EnchantmentKeys.SWEEPING_EDGE
minecraft:sweeping_edge
static final TypedKey
<Enchantment> EnchantmentKeys.SWIFT_SNEAK
minecraft:swift_sneak
static final TypedKey
<Enchantment> EnchantmentKeys.THORNS
minecraft:thorns
static final TypedKey
<Enchantment> EnchantmentKeys.UNBREAKING
minecraft:unbreaking
static final TypedKey
<Enchantment> EnchantmentKeys.VANISHING_CURSE
minecraft:vanishing_curse
static final TypedKey
<Enchantment> EnchantmentKeys.WIND_BURST
minecraft:wind_burst
-
Uses of Enchantment in io.papermc.paper.registry.keys.tags
Modifier and TypeFieldDescriptionstatic final TagKey
<Enchantment> EnchantmentTagKeys.CURSE
#minecraft:curse
static final TagKey
<Enchantment> EnchantmentTagKeys.DOUBLE_TRADE_PRICE
#minecraft:double_trade_price
static final TagKey
<Enchantment> EnchantmentTagKeys.EXCLUSIVE_SET_ARMOR
#minecraft:exclusive_set/armor
static final TagKey
<Enchantment> EnchantmentTagKeys.EXCLUSIVE_SET_BOOTS
#minecraft:exclusive_set/boots
static final TagKey
<Enchantment> EnchantmentTagKeys.EXCLUSIVE_SET_BOW
#minecraft:exclusive_set/bow
static final TagKey
<Enchantment> EnchantmentTagKeys.EXCLUSIVE_SET_CROSSBOW
#minecraft:exclusive_set/crossbow
static final TagKey
<Enchantment> EnchantmentTagKeys.EXCLUSIVE_SET_DAMAGE
#minecraft:exclusive_set/damage
static final TagKey
<Enchantment> EnchantmentTagKeys.EXCLUSIVE_SET_MINING
#minecraft:exclusive_set/mining
static final TagKey
<Enchantment> EnchantmentTagKeys.EXCLUSIVE_SET_RIPTIDE
#minecraft:exclusive_set/riptide
static final TagKey
<Enchantment> EnchantmentTagKeys.IN_ENCHANTING_TABLE
#minecraft:in_enchanting_table
static final TagKey
<Enchantment> EnchantmentTagKeys.NON_TREASURE
#minecraft:non_treasure
static final TagKey
<Enchantment> EnchantmentTagKeys.ON_MOB_SPAWN_EQUIPMENT
#minecraft:on_mob_spawn_equipment
static final TagKey
<Enchantment> EnchantmentTagKeys.ON_RANDOM_LOOT
#minecraft:on_random_loot
static final TagKey
<Enchantment> EnchantmentTagKeys.ON_TRADED_EQUIPMENT
#minecraft:on_traded_equipment
static final TagKey
<Enchantment> EnchantmentTagKeys.PREVENTS_BEE_SPAWNS_WHEN_MINING
#minecraft:prevents_bee_spawns_when_mining
static final TagKey
<Enchantment> EnchantmentTagKeys.PREVENTS_DECORATED_POT_SHATTERING
#minecraft:prevents_decorated_pot_shattering
static final TagKey
<Enchantment> EnchantmentTagKeys.PREVENTS_ICE_MELTING
#minecraft:prevents_ice_melting
static final TagKey
<Enchantment> EnchantmentTagKeys.PREVENTS_INFESTED_SPAWNS
#minecraft:prevents_infested_spawns
static final TagKey
<Enchantment> EnchantmentTagKeys.SMELTS_LOOT
#minecraft:smelts_loot
static final TagKey
<Enchantment> EnchantmentTagKeys.TOOLTIP_ORDER
#minecraft:tooltip_order
static final TagKey
<Enchantment> EnchantmentTagKeys.TRADEABLE
#minecraft:tradeable
static final TagKey
<Enchantment> EnchantmentTagKeys.TRADES_DESERT_COMMON
#minecraft:trades/desert_common
static final TagKey
<Enchantment> EnchantmentTagKeys.TRADES_DESERT_SPECIAL
#minecraft:trades/desert_special
static final TagKey
<Enchantment> EnchantmentTagKeys.TRADES_JUNGLE_COMMON
#minecraft:trades/jungle_common
static final TagKey
<Enchantment> EnchantmentTagKeys.TRADES_JUNGLE_SPECIAL
#minecraft:trades/jungle_special
static final TagKey
<Enchantment> EnchantmentTagKeys.TRADES_PLAINS_COMMON
#minecraft:trades/plains_common
static final TagKey
<Enchantment> EnchantmentTagKeys.TRADES_PLAINS_SPECIAL
#minecraft:trades/plains_special
static final TagKey
<Enchantment> EnchantmentTagKeys.TRADES_SAVANNA_COMMON
#minecraft:trades/savanna_common
static final TagKey
<Enchantment> EnchantmentTagKeys.TRADES_SAVANNA_SPECIAL
#minecraft:trades/savanna_special
static final TagKey
<Enchantment> EnchantmentTagKeys.TRADES_SNOW_COMMON
#minecraft:trades/snow_common
static final TagKey
<Enchantment> EnchantmentTagKeys.TRADES_SNOW_SPECIAL
#minecraft:trades/snow_special
static final TagKey
<Enchantment> EnchantmentTagKeys.TRADES_SWAMP_COMMON
#minecraft:trades/swamp_common
static final TagKey
<Enchantment> EnchantmentTagKeys.TRADES_SWAMP_SPECIAL
#minecraft:trades/swamp_special
static final TagKey
<Enchantment> EnchantmentTagKeys.TRADES_TAIGA_COMMON
#minecraft:trades/taiga_common
static final TagKey
<Enchantment> EnchantmentTagKeys.TRADES_TAIGA_SPECIAL
#minecraft:trades/taiga_special
static final TagKey
<Enchantment> EnchantmentTagKeys.TREASURE
#minecraft:treasure
Modifier and TypeMethodDescriptionstatic @NonNull TagKey
<Enchantment> Creates a tag key forEnchantment
in the registryminecraft:enchantment
. -
Uses of Enchantment in org.bukkit
Modifier and TypeFieldDescriptionstatic final Registry
<Enchantment> Registry.ENCHANTMENT
Deprecated. -
Uses of Enchantment in org.bukkit.enchantments
Modifier and TypeClassDescriptionclass
Deprecated.only for backwards compatibility, EnchantmentWrapper is no longer used.Modifier and TypeFieldDescriptionstatic final Enchantment
Enchantment.AQUA_AFFINITY
Increases the speed at which a player may mine underwaterstatic final Enchantment
Enchantment.BANE_OF_ARTHROPODS
Increases damage against arthropod targetsstatic final Enchantment
Enchantment.BINDING_CURSE
Item cannot be removedstatic final Enchantment
Enchantment.BLAST_PROTECTION
Provides protection against explosive damagestatic final Enchantment
Enchantment.BREACH
Reduces armor effectiveness against macesstatic final Enchantment
Enchantment.CHANNELING
Strikes lightning when a mob is hit with a trident if conditions are stormystatic final Enchantment
Enchantment.DENSITY
Increases fall damage of macesstatic final Enchantment
Enchantment.DEPTH_STRIDER
Increases walking speed while in waterstatic final Enchantment
Enchantment.EFFICIENCY
Increases the rate at which you mine/digstatic final Enchantment
Enchantment.FEATHER_FALLING
Provides protection against fall damagestatic final Enchantment
Enchantment.FIRE_ASPECT
When attacking a target, has a chance to set them on firestatic final Enchantment
Enchantment.FIRE_PROTECTION
Provides protection against fire damagestatic final Enchantment
Enchantment.FLAME
Sets entities on fire when hit by arrows shot from a bowstatic final Enchantment
Enchantment.FORTUNE
Provides a chance of gaining extra loot when destroying blocksstatic final Enchantment
Enchantment.FROST_WALKER
Freezes any still water adjacent to ice / frost which player is walking onstatic final Enchantment
Enchantment.IMPALING
Deals more damage to mobs that live in the oceanstatic final Enchantment
Enchantment.INFINITY
Provides infinite arrows when shooting a bowstatic final Enchantment
Enchantment.KNOCKBACK
All damage to other targets will knock them back when hitstatic final Enchantment
Enchantment.LOOTING
Provides a chance of gaining extra loot when killing monstersstatic final Enchantment
Enchantment.LOYALTY
Causes a thrown trident to return to the player who threw itstatic final Enchantment
Enchantment.LUCK_OF_THE_SEA
Decreases odds of catching worthless junkstatic final Enchantment
Enchantment.LURE
Increases rate of fish biting your hookstatic final Enchantment
Enchantment.MENDING
Allows mending the item using experience orbsstatic final Enchantment
Enchantment.MULTISHOT
Shoot multiple arrows from crossbowsstatic final Enchantment
Enchantment.PIERCING
Crossbow projectiles pierce entitiesstatic final Enchantment
Enchantment.POWER
Provides extra damage when shooting arrows from bowsstatic final Enchantment
Enchantment.PROJECTILE_PROTECTION
Provides protection against projectile damagestatic final Enchantment
Enchantment.PROTECTION
Provides protection against environmental damagestatic final Enchantment
Enchantment.PUNCH
Provides a knockback when an entity is hit by an arrow from a bowstatic final Enchantment
Enchantment.QUICK_CHARGE
Charges crossbows quicklystatic final Enchantment
Enchantment.RESPIRATION
Decreases the rate of air loss whilst underwaterstatic final Enchantment
Enchantment.RIPTIDE
When it is rainy, launches the player in the direction their trident is thrownstatic final Enchantment
Enchantment.SHARPNESS
Increases damage against all targetsstatic final Enchantment
Enchantment.SILK_TOUCH
Allows blocks to drop themselves instead of fragments (for example, stone instead of cobblestone)static final Enchantment
Enchantment.SMITE
Increases damage against undead targetsstatic final Enchantment
Enchantment.SOUL_SPEED
Walk quicker on soul blocksstatic final Enchantment
Enchantment.SWEEPING_EDGE
Increases damage against targets when using a sweep attackstatic final Enchantment
Enchantment.SWIFT_SNEAK
Walk quicker while sneakingstatic final Enchantment
Enchantment.THORNS
Damages the attackerstatic final Enchantment
Enchantment.UNBREAKING
Decreases the rate at which a tool looses durabilitystatic final Enchantment
Enchantment.VANISHING_CURSE
Item disappears instead of droppingstatic final Enchantment
Enchantment.WIND_BURST
Emits wind burst upon hitting enemyModifier and TypeMethodDescriptionstatic @Nullable Enchantment
Enchantment.getByKey
(@Nullable NamespacedKey key) Deprecated.only for backwards compatibility, useRegistry.get(NamespacedKey)
insteadstatic @Nullable Enchantment
Deprecated.enchantments are badly named, usegetByKey(org.bukkit.NamespacedKey)
.EnchantmentOffer.getEnchantment()
Get the type of the enchantment.EnchantmentWrapper.getEnchantment()
Deprecated.Gets the enchantment bound to this wrapperstatic @NotNull Enchantment[]
Enchantment.values()
Deprecated.Modifier and TypeMethodDescriptionabstract @NotNull RegistryKeySet
<Enchantment> Enchantment.getExclusiveWith()
Provides the registry key set of enchantments that this enchantment is exclusive with.Modifier and TypeMethodDescriptionabstract boolean
Enchantment.conflictsWith
(@NotNull Enchantment other) Check if this enchantment conflicts with another enchantment.void
EnchantmentOffer.setEnchantment
(@NotNull Enchantment enchantment) Sets the type of the enchantment.ModifierConstructorDescriptionEnchantmentOffer
(@NotNull Enchantment enchantment, int enchantmentLevel, int cost) -
Uses of Enchantment in org.bukkit.event.enchantment
Modifier and TypeMethodDescriptionEnchantItemEvent.getEnchantmentHint()
Get theEnchantment
that was displayed as a hint to the player on the selected enchantment offer.Modifier and TypeMethodDescriptionEnchantItemEvent.getEnchantsToAdd()
Get map of enchantment (levels, keyed by type) to be added to item (modify map returned to change values).ModifierConstructorDescriptionEnchantItemEvent
(@NotNull Player enchanter, @NotNull InventoryView view, @NotNull Block table, @NotNull ItemStack item, int level, @NotNull Map<Enchantment, Integer> enchants, @NotNull Enchantment enchantmentHint, int levelHint, int i) ModifierConstructorDescriptionEnchantItemEvent
(@NotNull Player enchanter, @NotNull InventoryView view, @NotNull Block table, @NotNull ItemStack item, int level, @NotNull Map<Enchantment, Integer> enchants, @NotNull Enchantment enchantmentHint, int levelHint, int i) -
Uses of Enchantment in org.bukkit.inventory
Modifier and TypeMethodDescriptionItemStack.getEnchantments()
Gets a map containing all enchantments and their levels on this item.Modifier and TypeMethodDescriptionvoid
ItemStack.addEnchantment
(@NotNull Enchantment ench, int level) Adds the specifiedEnchantment
to this item stack.void
ItemStack.addUnsafeEnchantment
(@NotNull Enchantment ench, int level) Adds the specifiedEnchantment
to this item stack.boolean
ItemStack.containsEnchantment
(@NotNull Enchantment ench) Checks if this ItemStack contains the givenEnchantment
int
ItemStack.getEnchantmentLevel
(@NotNull Enchantment ench) Gets the level of the specified enchantment on this item stackint
ItemStack.removeEnchantment
(@NotNull Enchantment ench) Removes the specifiedEnchantment
if it exists on this ItemStackModifier and TypeMethodDescriptionvoid
ItemStack.addEnchantments
(@NotNull Map<Enchantment, Integer> enchantments) Adds the specified enchantments to this item stack.void
ItemStack.addUnsafeEnchantments
(@NotNull Map<Enchantment, Integer> enchantments) Adds the specified enchantments to this item stack in an unsafe manner.ItemFactory.enchantWithLevels
(@NotNull ItemStack itemStack, @org.jetbrains.annotations.Range(from=1L, to=30L) int levels, RegistryKeySet<@NotNull Enchantment> keySet, Random random) Randomly enchants a copy of the providedItemStack
using the given experience levels.ItemStack.enchantWithLevels
(@org.jetbrains.annotations.Range(from=1L, to=30L) int levels, RegistryKeySet<@NotNull Enchantment> keySet, Random random) Randomly enchants a copy of thisItemStack
using the given experience levels. -
Uses of Enchantment in org.bukkit.inventory.meta
Modifier and TypeMethodDescriptionItemMeta.getEnchants()
Returns a copy the enchantments in this ItemMeta.EnchantmentStorageMeta.getStoredEnchants()
Gets a copy the stored enchantments in this ItemMeta.Modifier and TypeMethodDescriptionboolean
ItemMeta.addEnchant
(@NotNull Enchantment ench, int level, boolean ignoreLevelRestriction) Adds the specified enchantment to this item meta.boolean
EnchantmentStorageMeta.addStoredEnchant
(@NotNull Enchantment ench, int level, boolean ignoreLevelRestriction) Stores the specified enchantment in this item meta.int
ItemMeta.getEnchantLevel
(@NotNull Enchantment ench) Checks for the level of the specified enchantment.int
EnchantmentStorageMeta.getStoredEnchantLevel
(@NotNull Enchantment ench) Checks for the level of the stored enchantment.boolean
ItemMeta.hasConflictingEnchant
(@NotNull Enchantment ench) Checks if the specified enchantment conflicts with any enchantments in this ItemMeta.boolean
EnchantmentStorageMeta.hasConflictingStoredEnchant
(@NotNull Enchantment ench) Checks if the specified enchantment conflicts with any enchantments in this ItemMeta.boolean
ItemMeta.hasEnchant
(@NotNull Enchantment ench) Checks for existence of the specified enchantment.boolean
EnchantmentStorageMeta.hasStoredEnchant
(@NotNull Enchantment ench) Checks for storage of the specified enchantment.boolean
ItemMeta.removeEnchant
(@NotNull Enchantment ench) Removes the specified enchantment from this item meta.boolean
EnchantmentStorageMeta.removeStoredEnchant
(@NotNull Enchantment ench) Remove the specified stored enchantment from this item meta.
RegistryAccess.getRegistry(io.papermc.paper.registry.RegistryKey)
withRegistryKey.ENCHANTMENT