-
-
Notifications
You must be signed in to change notification settings - Fork 682
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Map new Mace enchantments for Bedrock clients #4653
Map new Mace enchantments for Bedrock clients #4653
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR! Until Bedrock adds these enchantments itself, this seems like an okay temporary fix.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good to me! thanks :)
if (enchantment == Enchantment.JavaEnchantment.SWEEPING_EDGE) { | ||
addSweeping(session, builder, level); | ||
return null; | ||
if (ENCHANTMENT_TRANSLATION_KEYS.containsKey(enchantment)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This can be replaced by moving the below get() above here then a null check.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed, thanks
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks fine otherwise.
* Map new Mace enchantments for Bedrock clients * Move to using a map for Java-only enchantments. * Change to using null check for translationKey
This PR fixes the new Mace enchantments, Breach, Density and Wind Burst not being mapped to Bedrock clients, causing users to be unable to see the contents of their inventory.
Prior to this PR, this would get spammed in console whenever a Bedrock user had one of these enchantments in their inventory: