mirror of
https://github.com/MinecraftForge/MinecraftForge
synced 2026-08-22 04:26:10 -04:00
Fix bookshelves having too much enchanting power. Fixes #10770
This commit is contained in:
parent
d29524bac3
commit
558e7d754e
1 changed files with 2 additions and 2 deletions
|
|
@ -9,7 +9,7 @@
|
|||
}
|
||||
|
||||
@Override
|
||||
@@ -90,23 +_,25 @@
|
||||
@@ -90,23 +_,24 @@
|
||||
if (!itemstack.isEmpty() && itemstack.isEnchantable()) {
|
||||
this.access.execute((p_449765_, p_449766_) -> {
|
||||
IdMap<Holder<Enchantment>> idmap = p_449765_.registryAccess().lookupOrThrow(Registries.ENCHANTMENT).asHolderIdMap();
|
||||
|
|
@ -18,7 +18,7 @@
|
|||
|
||||
for (BlockPos blockpos : EnchantingTableBlock.BOOKSHELF_OFFSETS) {
|
||||
if (EnchantingTableBlock.isValidBookShelf(p_449765_, p_449766_, blockpos)) {
|
||||
j++;
|
||||
- j++;
|
||||
+ j += p_449765_.getBlockState(p_449766_.offset(blockpos)).getEnchantPowerBonus(p_449765_, p_449766_.offset(blockpos));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue