Skip to content
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

Method overwrite conflict #7

Open
TheDGOfficial opened this issue Aug 24, 2024 · 0 comments
Open

Method overwrite conflict #7

TheDGOfficial opened this issue Aug 24, 2024 · 0 comments

Comments

@TheDGOfficial
Copy link

TheDGOfficial commented Aug 24, 2024

Seemingly 2 different mixins to the same class and same method conflict from Redaction.

[16:06:04] [Client thread/WARN]: Method overwrite conflict for resetFOV in mixins.redaction.json:EntityRendererMixin_OptiFine, previously written by org.polyfrost.redaction.mixin.EntityRendererMixin. Skipping method.

After looking to the source of both Mixins, I see that no @Overwrite is used and instead @Inject is used so I'm really suprised why this warning appears. However I guess this can be fixed by conditionally applying Mixins. In the class of the mod that extends IMixinConfigPlugin, in @Override shouldApplyMixin(String targetClassName, String mixinClassName) the mixinClassName can be checked and depending on if Optifine is installed or not, the optifine version of the Mixin or the regular version will be allowed to apply and the other one will return false from shouldApplyMixin, fixing the warning (hopefully).

For reference, I have Optifine installed but it says "previously written by org.polyfrost.redaction.mixin.EntityRendererMixin. Skipping method.", I don't know if this would cause any incompatibility with Optifine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant