Skip to content

Fix startup crash#13

Merged
omtoi101 merged 2 commits into
mainfrom
fix-startup-crash
Sep 21, 2025
Merged

Fix startup crash#13
omtoi101 merged 2 commits into
mainfrom
fix-startup-crash

Conversation

@omtoi101

Copy link
Copy Markdown
Owner

No description provided.

google-labs-jules Bot and others added 2 commits September 21, 2025 08:41
The mod was crashing on startup due to a Mixin error in `ClientPlayNetworkHandlerMixin`. The mixin was attempting to inject into the `onDisconnected` method, which no longer exists in the target version of Minecraft.

This change fixes the crash by removing the problematic mixin and replacing its functionality with a listener for the `ClientPlayConnectionEvents.DISCONNECT` event from the Fabric API. This is a more robust and future-proof solution.

The following changes were made:
- Added the Fabric API as a dependency in `build.gradle.kts` and `fabric.mod.json`.
- Removed `ClientPlayNetworkHandlerMixin.java`.
- Removed the reference to the mixin from `addon-template.mixins.json`.
- Added an event listener for `ClientPlayConnectionEvents.DISCONNECT` in `BaseFinder.java` to post the `PlayerDisconnectEvent`.
@omtoi101 omtoi101 merged commit b3e1f60 into main Sep 21, 2025
1 of 2 checks passed
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