Compatibility
Minecraft: Java Edition
Platforms
Supported environments
Creators
Details
Changelog
What's new in v4.0.0
Crash Fixes
Recall Crash Fix — When a Pokemon is recalled to its ball (e.g. after a battle ends or manually), the entity removal could happen on a background thread. This caused random server crashes that were hard to reproduce. Now the recall always runs safely on the main thread.
Battle Challenge Crash Fix — When a player sends a battle challenge to another player, the packet handler could execute off the main thread. Since battle logic isn't thread-safe, this could corrupt data or crash the server. Now queued to the main thread before processing.
Mount/Dismount Crash Fix — When a player mounts or dismounts a rideable Pokemon, the riding state update could run off-thread. Since it modifies entity state, this could crash the server. Now safely runs on the main thread.
Bug Fixes
Command Position Fix — When plugins or Cobblemon run commands targeting a Pokemon entity, the position used was from when the command source was created, not where the entity actually is now. This caused commands to miss moving targets. Now always returns the entity's real-time position.
Performance Patches
Showdown ID Cache — Cobblemon builds a string ID for every Pokemon and Species every time it's accessed (used heavily in battles). Now calculated once and reused. Automatically refreshes when the Pokemon changes species or form.
Battle Lookup O(1) — Finding a player's battle used to iterate through every active battle on the server. Now uses three hash maps for instant lookup by battle ID, player UUID, or player entity.
Battle Data Cache — getSides(), getActors(), getActivePokemon(), getPlayers(), isPvP(), isPvN(), isPvW() were all recalculated from scratch on every call. Now cached per battle, invalidated when battle state changes.
Berry Block Cache — Every berry block looked up its berry type from the registry every tick. Now cached once per block. Berry growth timer updates are also throttled from 20/sec to 1/sec — same growth behavior, far less CPU.
Pasture Cache — Finding a pastured Pokemon scanned every slot of every PC box. Now remembers the last known position and checks there first. Falls back to full scan only if the Pokemon moved.
PC Storage UUID Cache — PokemonStore.get(UUID) iterated through every stored Pokemon to find a match. Now uses a ConcurrentHashMap for instant lookup.
PC Box & PC Store Iterators — Iterating through PC contents created intermediate lists and collections. Now iterates directly over the underlying data, producing zero garbage.
Compatibility
All new patches use defaultRequire = 0, meaning they silently skip if the target method doesn't exist in your Cobblemon version. Works on Cobblemon 1.7.0 through 1.7.3+ without crashing.
Files
Metadata
Release channel
ReleaseVersion number
4.0.0Loaders
Game versions
1.21.1Environment
Downloads
71Publication date
March 8, 2026 at 11:08 AMPublisher
MarcoErCarrozza
Member


