Utility Nexus Fixes (1.2.0)
Curse Maven Snippet
What's new
v1.2.0 - Better Party member-health crash guard
Adds a new optional, server-side compatibility patch for Better Party. Same compatibility-patch philosophy as the rest of this mod: it never touches the affected mod's jar, and the patch only activates when that mod is present.
Added
- Better Party member-health crash guard:
BetterPartyServerApi.memberHealth(ServerPlayer)falls back tonew PartyMemberHealth(player.getHealth(), player.getMaxHealth())whenever no custom health-provider add-on is registered. That record's constructor throws an uncaughtIllegalArgumentExceptionif either value is non-finite ormaxHealth <= 0, which propagates out ofBetterParty#onServerTickand crashes the entire dedicated server mid-tick — for every player online — the instant a single player'sgeneric.max_healthattribute gets corrupted, even momentarily. New soft, server-only mixinBetterPartyMemberHealthGuardMixin(gated byBvaMixinPluginonbetter_partyactually being loaded) wraps the two vanillaServerPlayeraccessor calls that feed the record and substitutes a safe finite value if either reading is currently invalid, logging a warning instead of crashing.
Notes
This patch stops the crash, it does not fix whatever corrupts the player'sgeneric.max_healthattribute in the first place — if it keeps happening, look at what other mod/enchantment is stacking attribute modifiers on that player around the same time. Optional dependency onbetter_party(server side). No new compile-time dependency was added to build this mod: the target class is referenced by name only (@Pseudosoft mixin target), never on the compile classpath. Verified:./gradlew clean buildis green.
JAR: utility_nexus_fixes-1.21.1-neoforge-21.1.249-1.2.0.jar
Tag: 1.21.1-neoforge-1.2.0
This mod has no additional files

