summaryrefslogtreecommitdiffstats
path: root/nms-patches/ContainerEnchantTable.patch
diff options
context:
space:
mode:
Diffstat (limited to 'nms-patches/ContainerEnchantTable.patch')
-rw-r--r--nms-patches/ContainerEnchantTable.patch4
1 files changed, 2 insertions, 2 deletions
diff --git a/nms-patches/ContainerEnchantTable.patch b/nms-patches/ContainerEnchantTable.patch
index 7f21527e..4fd8a19a 100644
--- a/nms-patches/ContainerEnchantTable.patch
+++ b/nms-patches/ContainerEnchantTable.patch
@@ -147,11 +147,11 @@
+ }
- if (flag) {
-- Items.ENCHANTED_BOOK.a(itemstack, weightedrandomenchant);
+- ItemEnchantedBook.a(itemstack, weightedrandomenchant);
- } else {
- itemstack.addEnchantment(weightedrandomenchant.enchantment, weightedrandomenchant.level);
+ WeightedRandomEnchant weightedrandomenchant = new WeightedRandomEnchant(Enchantment.c(enchantId), entry.getValue());
-+ Items.ENCHANTED_BOOK.a(itemstack, weightedrandomenchant);
++ ItemEnchantedBook.a(itemstack, weightedrandomenchant);
+ } else {
+ item.addUnsafeEnchantment(entry.getKey(), entry.getValue());
+ }