Plan-first chunk pre-generation for Paper 1.21.11 — shows what will generate before it starts.
Changelog
Unreleased
Fixed:
/fwg script runwas calling the synchronous, blockingWorld#getChunkAtonce per chunk (1024 times per region) to force-load terrain before runninggenerateRegion, causing repeated Watchdog "server has not responded" timeouts/freezes on any ungenerated area. Script regions are now loaded viaWorld#getChunkAtAsync(Paper's supported non-blocking API, same pattern already used by normal/fwg startjobs) and the script only runs once all of a region's chunks are confirmed ready.Added
docs/SCRIPTING.md: a dedicated Custom Generation scripting guide (bindings, fullapireference, region-coordinate math, patterns, troubleshooting table). README's scripting section now summarizes and links to it instead of duplicating it.Added update checking: on enable, FastWorldGen asynchronously queries Hangar (
hangar.papermc.io/firesmasher/FastWorldGen) for the latest release and compares it against the running version. Result is logged to console in color; if an update is available, operators (andfastworldgen.adminholders) get a colored chat notice shortly after joining.Added the wand:
/fwg wand givehands out a named Blaze Rod; left-click sets position 1, right-click sets position 2 (WorldEdit-style, clicks are cancelled so nothing breaks or places)./fwg wand save <name>fills a vanillaStructurefrom the selection and writes it todata/structures/<name>.nbt. Also adds/fwg wand pos1|pos2|info|clear.- New
fastworldgen.wandpermission (defaults toop, included infastworldgen.admin). - Selections capped at 2,000,000 blocks and must stay within a single world.
- New
FastWorldGen 1.1.0
- Added
/fwg continue [world]to explicitly re-plan and continue a saved job after a restart, instead of that only happening automatically when another command triggered it. - Memory: regions are now streamed as compact bitmasks instead of per-chunk objects during
planning, and generated chunks are unloaded once a configurable number stay loaded at once
(
safety.max-loaded-chunks), bounding memory growth on large-radius jobs. - Default config and built-in fallbacks retuned for a 4 GB heap / 2 CPU cores: lower
chunks-per-tick-batch,max-chunks-per-tick-batch,max-inflight-chunk-tasks,max-loaded-chunks, andregions-per-batch, with adjusted MSPT watermarks. - Added Custom Generation: embeds Mozilla Rhino (ES6 JavaScript) for scripted generation.
- New
/fwg script run <script.js> [world ...] [radius|bounds ...] [--fresh],/fwg script list,/fwg script status [world],/fwg script cancel [world]. - New
scripts/folder for.jsscripts anddata/structures/folder for.nbtstructures, created under the plugin's data folder on startup. - Scripts get
world,seed,area,random, and anapiobject for block placement,.nbtstructure placement (via Paper'sStructureManager), deterministic per-region randomness, and logging. - Script jobs run on the main thread with the same chunk force-load/unload discipline as normal generation, and share the one-job-per-world limit.
- Per-call execution timeout (
scripting.max-script-execution-ms, default 5000ms) guards against a runaway script hanging the server;scripting.enabledcan disable the feature entirely. - New
fastworldgen.scriptpermission (defaults toop, included infastworldgen.admin).
- New
Requirements: Paper 1.21.11, Java 21+.
FastWorldGen 1.0.0
Initial release.
- Plan-first pipeline:
/fwg planshows total chunks, existing chunks, chunks to generate, and region count before any generation happens. /fwg startbegins generation immediately after planning; works with just a world name (uses a configurable default radius) or explicitradius/bounds+ optionalcenter.- Existing chunks are skipped by default; pass
--freshto force regeneration. - Work is grouped into 32×32 chunk regions and batches, ordered for spatial locality.
- Adaptive throughput throttles generation based on live server tick time (MSPT).
/fwg statusshows live progress, speed, ETA, region/batch counts, and MSPT.- Detailed logging: per-region and per-batch completion lines as generation runs, plus a full summary (chunks generated/failed, elapsed time, average speed) when a job finishes.
/fwg pause//fwg resume//fwg cancel, all graceful — in-flight chunk operations are allowed to finish rather than being interrupted.- Job state survives server restarts; the world is re-inspected on startup rather than trusting stored progress.
- Full permission set, all defaulting to
op.
Requirements: Paper 1.21.11, Java 21+.