packetevents
packetevents copied to clipboard
Enchantment component issue
Describe the bug Incorrect enchantments are applied after ItemStack building.
Software brand Paper 1.21.1 PacketEvents 2.6.0
Plugins no one except mine
How To Reproduce
- Build any item using ItemStack.builder()
- Set any enchantment to it with components, for example .component(ComponentTypes.ENCHANTMENTS, ItemEnchantments(mutableMapOf(EnchantmentTypes.FIRE_ASPECT to 1), true))
- Check how it looks in the game
Expected behavior Correct enchantments
Screenshots
Additional context no
This is caused by an ItemStack not having access to the enchantment registry, which is dynamically loaded