Skip to content

Fix incompatibility issue with Boze - #151

Open
sonhoang780 wants to merge 1 commit into
Luna5ama:devfrom
sonhoang780:fix/boze-gamerenderer-priority
Open

Fix incompatibility issue with Boze#151
sonhoang780 wants to merge 1 commit into
Luna5ama:devfrom
sonhoang780:fix/boze-gamerenderer-priority

Conversation

@sonhoang780

Copy link
Copy Markdown

Problem

Client crashes on startup when TrollHack runs alongside Boze:

InjectionError: Redirector applyCameraTransformationsMathHelperLerpProxy(FFF)F
in trollhack.mixins.json:render.MixinGameRenderer from mod trollhack failed
injection check, (0/1) succeeded. Scanned 0 target(s). No refMap loaded.

Root cause

MixinGameRenderer (targeting GameRenderer) had no explicit priority, so it
fell back to the config-level default (2100000000 in trollhack.mixins.json)
-- applied essentially last among all mixins. Boze's own loader transforms
GameRenderer.renderLevel earlier (lower/default priority), restructuring the
method before TrollHack's @Redirect scans it -- by the time it runs, the
literal Mth.lerp(FFF)F call site it targets no longer exists in that exact
form, so injection finds 0 targets and mixin throws. Verified via javap against
MC 26.1.2's real GameRenderer bytecode: the method + lerp call do exist
unmodified -- this isn't a wrong signature, it's an apply-order conflict.

Fix

  • @Mixin(value = GameRenderer.class, priority = 500) -- apply before
    third-party mods with default/higher priority mutate the target method.
  • require = 0 on the @Redirect as a safety net, so a similar conflict with
    some other mod degrades (feature silently no-ops) instead of crashing the
    whole client.

Testing

  • :fabric:compileJava passes.
  • Not yet retested live against Boze end-to-end (needs rebuild + relaunch).

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

Successfully merging this pull request may close these issues.

1 participant