Skip to content

Pixelmon CheckSpawns Fix

Stops /checkspawns fishing (and other spawn checks that include a spawn collection) from crashing the server.

What it does

  • Pixelmon's SpawnInfoCollection.toString() uses a client-only class (I18n). On a dedicated server, /checkspawns hits it, fails with NoClassDefFoundError, and the error kills the server thread.
  • This mod replaces that one method with the same lookup through Minecraft's server-safe language table.
  • Nothing else changes: no commands, spawn rates, or spawn choices.
  • At startup it calls the fixed method once and logs the result, so if a Pixelmon update breaks the fix, it shows up at boot instead of when someone runs /checkspawns.

Server-side only. Clients install nothing.

How players use it

Players do not interact with this mod. /checkspawns simply works.

Staff guide

There are no commands. If /checkspawns fishing works without crashing the server, the fix is active.

Configuration

None.

Data and storage

None.

Troubleshooting

Symptom Cause Fix
Server crashes with NoClassDefFoundError: net/minecraft/client/resources/language/I18n after /checkspawns Mod missing, or its mixin did not apply Check mods/ and look for mixin errors at boot
Boot fails in this mod's startup check A Pixelmon update changed SpawnInfoCollection Rebuild against the new Pixelmon and recheck the mixin

Boot lines that show it loaded and the startup check passed:

Pixelmon CheckSpawns Fix loaded
Dedicated-server language lookup verified: <label>

Maintainer notes

  • One mixin: SpawnInfoCollectionMixin overwrites SpawnInfoCollection.toString() to use net.minecraft.locale.Language instead of net.minecraft.client.resources.language.I18n.
  • Separate from pixelmon-checkspawns-perms, which handles who may run /checkspawns.
  • MIT licensed.

Building

./gradlew build

Java 21. Output: build/libs/pixelmoncheckspawnsfix-<version>.jar.

Full command, permission and config tables: Reference.