promotional bannermobile promotional banner

Dwurdy Sharks

All the sharks. Maintained.** A credited community fork of Ben's Sharks for NeoForge 1.21.1, with 26 registered marine entity types and the wild-shark despawn fix.
Back to Files

Dwurdy Sharks 1.4.0 for Minecraft 1.21.1

File namedwurdysharks-1.4.0.jar
Uploader
dwurdydwurdy
Uploaded
Sep 22, 2026
Downloads
73
Size
2.3 MB
Mod Loaders
NeoForge
File ID
8945537
Type
R
Release
Supported game versions
  • 1.21.1

Curse Maven Snippet

NeoForge

implementation "curse.maven:dwurdy-sharks-1693295:8945537"

Learn more about Curse Maven

What's new

Dwurdy Sharks 1.4.0 — Minecraft 1.21.1

Dwurdy Sharks 1.4.0 is a stability and performance release. It fixes every server-degrading defect found in a production incident report (CPU escalation, heap growth 15→17 GB, sharks spawning in rivers and lakes, and a ~2000-entity stress event) and proves the fixes with an automated GameTest regression suite and five 5-minute stress profiles.

⚠️ Migration notes

  • SavedData keys renamed. Internal world/map variable stores moved from benssharks_mapvars/benssharks_worldvars to dwurdysharks_mapvars/dwurdysharks_worldvars. These hold transient mod counters only; stored values reset on first load under 1.4.0. Entity, item, and block IDs are unchanged from 1.3.0 (dwurdysharks:*).
  • Creative tab ID renamed dwurdysharks:bens_sharks → dwurdysharks:dwurdy_sharks; the tab display name is now "Dwurdy Sharks" in all shipped locales.
  • All remaining internal Benssharks* class names were renamed to DwurdySharks*. This is invisible to players; it matters only to forks or tooling that referenced the old class names.

Fixed

  • Initial-spawn procedures ran every tick. Fourteen *OnInitialEntitySpawnProcedure classes were EntityTickEvent.Pre subscribers running a 25-block getEntitiesOfClass query plus a full sort on every server tick. They now run once at spawn. (#23)
  • Dryout work-queue storm. Nineteen per-tick procedures called queueServerWork(300–600) every tick for each shark out of water — roughly 600 queued lambdas per beached shark, each pinning the entity in memory. Replaced with a per-entity dryout counter; no queue growth. (#24)
  • Wild sharks spawned outside oceans. Bull shark spawn data listed river, swamp, mangrove_swamp, beach, and stony_shore; the Java spawn predicate checked only for water. Natural spawns are now restricted to the dwurdysharks:shark_spawning_oceans biome tag (seeded from #minecraft:is_ocean), across all 21 biome-modifier files and the Java predicate. Datapacks and modded biomes extend the tag without a rebuild. (#25)
  • Wrong mob category. Blacktip reef shark, bonnethead, and barracuda were registered as WATER_AMBIENT — uncapped and exempt from water-creature despawn rules. They are now WATER_CREATURE. (#30)
  • Global entity-tick subscribers retired. The remaining global EntityTickEvent.Pre pattern is gone; RollParticleEntity's 44 target goals were stripped. (#32)

Added

  • Local population caps and density shaping. New mobs-category gamerules: largeSharkLocalCap (default 24), ambientFishLocalCap (default 64), sharkSpawnCapRadius (default 128), and enforceCapForManualSpawns (default true). Spawn costs shape density before the hard cap is reached; tamed, named, and persistence-required sharks are exempt. (#26)
  • Server config dwurdysharks-server.toml (DwurdySharksConfig): spawningEnabled master switch, oceanOnly toggle, per-species natural spawn toggles, sharkDamageMultiplier, megalodonDamage, and megalodonArmorBypass (default false). (#31)
  • GameTest regression + stress suite in net.mcreator.sharks.gametest.DwurdySharksGameTests, run via gradlew runGameTestServer. Seventeen required tests cover aggression toggles, tamed-follow behavior, ocean-biome spawn predicates, dryout countdown, wild despawn beyond 128 blocks, cap plateau/exemptions, and cap-disabled cleanup. Five optional stress profiles each run for five wall-clock minutes and report spawn counts, alive counts, tick-time average/p95, work-queue depth, and heap delta. (#33, #34, #35)

Performance

  • Per-tick refreshDimensions() removed from all 24 entity baseTicks. (#28)
  • Per-class target-goal lists collapsed into entity-type tag goals — 30–77 target goals reduced to at most 8 per species. (#27)
  • Hot-path entity queries (EatKrillProcedure, BarracudaSprintProcedure, EatDroppedItemProcedure, and friends) made single-pass and throttled. (#29)
  • Release-gate measurements on the GameTest server (five ≥300 s wall-clock profiles): sustained ~470/500 live sharks at p95 tick 5–13 ms; empty-world baseline p95 0.15 ms; 2000-attempt cap-abuse run plateaued at 8 admitted with post-settle p95 0.51 ms; cap-disabled despawn+GC heap delta +4 MB with zero mod entities remaining.

Verification

  • gradlew.bat clean build passes on Java 21 with NeoForge 21.1.248 (pre-existing deprecation warnings only).
  • gradlew.bat runGameTestServer: all 17 required tests passed, zero optional failures. Every timed stress profile ran ≥300 s wall-clock: stress_item_eat 300.4 s, stress_dryout_beached 300.1 s, stress_population_500 300.6 s, stress_baseline 300.5 s, stress_population_100 300.4 s.
  • All ten static guard scripts in tools/ pass (verify-ai-goals, verify-config, verify-dimensions, verify-dryout, verify-global-events, verify-hot-path, verify-ocean-spawns, verify-persistence, verify-spawn-caps, verify-spawn-procedures).
  • Spark CPU/allocation profiling against a live production server remains a manual step (see docs/TESTING.md); the automated gate ran on the real GameTest server.

This release is for Minecraft 1.21.1 + NeoForge only. Other Minecraft versions and loaders require separate ports and verification.

This mod has no additional files