Skip to content

Commit

Permalink
Update enchantment_table.js
Browse files Browse the repository at this point in the history
  • Loading branch information
zisis912 authored Sep 20, 2024
1 parent 5ac3372 commit d144456
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/plugins/enchantment_table.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,11 @@ function inject (bot) {
const slot = slots[packet.property - 4]
if (bot.majorVersion === "1.8" ) { slot.expected.enchant = packet.value }
else {

if (packet.value === -1) { slot.expected.enchant = null }
}
else {
slot.expected.enchant = bot.registry.enchantments[packet.value].name
}
else { slot.expected.enchant = bot.registry.enchantments[packet.value].name }

}
} else if (packet.property < 10) {
const slot = slots[packet.property - 7]
slot.expected.level = packet.value
Expand Down

0 comments on commit d144456

Please sign in to comment.