Shadows-of-Fire / Apothic-Attributes

Attributes library for Minecraft, used by Apotheosis.
MIT License
7 stars 9 forks source link

Replace @Overwrite with @ModifyReturnValue, fixing mod incompats. #23

Closed nvb-uy closed 3 months ago

nvb-uy commented 3 months ago

This mixin uses @Overwrite to return its own damage values, but sadly overwrite is bad for these cases, due to incompatibilities.

This specifically breaks my mod, Protection Balancer, which also mixins in the same place to modify the protection and armor values. It may break other mods too but i'm not aware of any.

I simply added mixin extras (because even if it's included inside neoforge,it wouldn't let me compile without adding it into the build gradle), and changed the overwrite to work with mixinextra's @ModifyReturnValue, giving out the exact same result but without breaking other mods that try to do a similar thing.