AHilyard / EquipmentCompare

A mod for Minecraft 1.16.5 that makes it easier to compare equipment.
Other
10 stars 9 forks source link

Unconditionally cancelled inject causing compatibility issues on Fabric #31

Open enjarai opened 1 year ago

enjarai commented 1 year ago

The Fabric version of this mod contains an inject mixin in KeyMapping that is unconditionally cancelled. This is effectively the same as using an overwrite mixin, and is very bad practice:

https://github.com/AHilyard/EquipmentCompare/blob/0e1fb082ef49a6ff92c8d3dbed72588f36cedbf2/src/main/java/com/anthonyhilyard/equipmentcompare/mixin/KeyMappingMixin.java#L29-L44

Doing your mixin this way creates incompatibilities with one of my mods (specifically here (uses Yarn)) and is likely to create issues with other mods that modify keybind behaviour.

If possible, it'd be great if you could switch to a more limited injection scope, potentially making use of the excellent @WrapWithCondition provided by MixinExtras.

enjarai commented 1 year ago

Is a fix planned for this? If not, mind if I create a PR for it?

SettingDust commented 1 year ago

https://modrinth.com/mod/equipment-compare-keybind-fix (Under review 2023-11-13)