Ref methods have no implementation in released jars (AbstractMethodError) #47

Closed
opened 2026-09-30 16:02:28 +00:00 by selimaj-dev · 0 comments
Owner

Several mixins in impl/mixins implement a common Ref interface only through a vanilla method that happens to have the same Yarn name (usually a bare @Shadow). Released jars run on intermediary names, so Loom renames those vanilla methods (getDamage → method_7919, …) and the Ref method is left without an implementation. Calling it throws AbstractMethodError.

Checked in the published saturn-client-0.1.4-beta+1.21.11.jar with javap. For example, ItemStackMixin only has method_7960, method_7936 and method_7919, and nothing named isEmpty/getMaxDamage/getDamage.

Affected methods and what calls them:

  • ItemStackRef.isEmpty/getMaxDamage/getDamage: Armor Display mod
  • EffectRef.shouldShowIcon/isInfinite: Status Effects mod
  • WindowRef.getWidth/getHeight/getFramebufferWidth/getFramebufferHeight: ImageTexture (SVG textures)
  • MinecraftClientRef.scheduleStop: the title screen's close button
  • MatrixStackRef.push/pop (1.21.4 and 1.21.5 only): every Saturn screen. In dev on Mojang names, 1.21.4 crashes on the title screen with AbstractMethodError: ... PoseStack does not define or inherit an implementation of ... push()

I haven't reproduced the crash in a production install; this comes from the jar contents plus the dev crash.

Fix: each mixin shadows the vanilla method and implements the Ref method explicitly. WindowRef and ItemStackRef methods that share a name with a vanilla method are renamed (saturnclientmc/common#13, then the mojang-mappings branch for #39).

🤖 Generated with Claude Code

Several mixins in `impl/mixins` implement a `common` Ref interface only through a vanilla method that happens to have the same Yarn name (usually a bare `@Shadow`). Released jars run on intermediary names, so Loom renames those vanilla methods (`getDamage` → `method_7919`, …) and the Ref method is left without an implementation. Calling it throws `AbstractMethodError`. Checked in the published `saturn-client-0.1.4-beta+1.21.11.jar` with `javap`. For example, `ItemStackMixin` only has `method_7960`, `method_7936` and `method_7919`, and nothing named `isEmpty`/`getMaxDamage`/`getDamage`. Affected methods and what calls them: - `ItemStackRef.isEmpty/getMaxDamage/getDamage`: Armor Display mod - `EffectRef.shouldShowIcon/isInfinite`: Status Effects mod - `WindowRef.getWidth/getHeight/getFramebufferWidth/getFramebufferHeight`: `ImageTexture` (SVG textures) - `MinecraftClientRef.scheduleStop`: the title screen's close button - `MatrixStackRef.push/pop` (1.21.4 and 1.21.5 only): every Saturn screen. In dev on Mojang names, 1.21.4 crashes on the title screen with `AbstractMethodError: ... PoseStack does not define or inherit an implementation of ... push()` I haven't reproduced the crash in a production install; this comes from the jar contents plus the dev crash. Fix: each mixin shadows the vanilla method and implements the Ref method explicitly. `WindowRef` and `ItemStackRef` methods that share a name with a vanilla method are renamed (saturnclientmc/common#13, then the `mojang-mappings` branch for #39). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
selimaj-dev added the area/modsarea/uiarea/versions
type
bug
labels 2026-09-30 16:02:33 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: saturnclientmc/saturnclient#47