-
-
Notifications
You must be signed in to change notification settings - Fork 345
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Fix armor level checking #9786
Fix armor level checking #9786
Conversation
/** | ||
* Implementation for the IArmorMaterial interface so we can add custom armor types. | ||
* Implementation for the ArmorMaterial interface, so we can add custom armor types. | ||
*/ | ||
public class MineColoniesArmorMaterial implements ArmorMaterial |
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.
just side question: side you edit this class anyway how about making it true record?
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.
I prefer to not hide code :D
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.
My intention was to leave it the same implementation as the ArmorMaterials enum so it's easy to spot differences.
src/main/java/com/minecolonies/core/items/MineColoniesArmorMaterial.java
Outdated
Show resolved
Hide resolved
When checking for armor level, the entire armor set + toughness is taken into consideration as opposed to only the armor level of the chestplate. Fixed the MinecoloniesArmorMaterial to updated ArmorMaterials Mojang implementation, so that armor values are applied in the correct order to each armor type. Updated plate armor: Durability raised from 20 to 37 Armor levels updated from 4,9,7,4 to 3,8,6,3 (helmet, chestplate, leggings, boots) Toughness reduced from 2 to 0 Enchantment level raised from 6 to 9 Updated pirates armors: Pirate armor 1 is now identical to iron with durability of diamond Pirate armor 2 is now identical to diamond with durability of iron Fixed other armors in the mod to use the new armor material constructor (santa hat and build goggles)
Changes proposed in this pull request:
[X] Yes I tested this before submitting it.
[ ] I also did a multiplayer test.
Review please