Pregen
在不损害服务器性能的前提下预生成你的世界。
Pregen 会提前生成地形,确保玩家在探索时不会遇到卡顿。它操作安全:它会监控服务器的 Tick 时间,在 TPS 下降前自动减速,且修剪区块绝不会影响已加载的世界。
一个 Jar 包适用于 Paper、Folia 和 Purpur,支持从 1.21 到 26.3。无依赖项。无遥测数据收集。
✨ 为什么选择 Pregen
? 自主保护你的 TPS
大多数预生成工具无论情况如何都会推送固定数量的区块。Pregen 每秒读取服务器的 Tick 时间并自动调整速度:当 Tick 变慢时它会退让,当有空闲资源时再加速。你也可以在玩家在线时暂停生成,仅在服务器空闲时运行。
?️ 不会损坏世界的修剪功能
在加载世界时直接删除区域文件中的区块是有风险的。Pregen 通过三个安全步骤执行此操作:
- 试运行:
/pregen trim outside 会显示将删除多少区块和区域,以及能释放多少空间。此时不会触碰任何文件。
- 确认:
/pregen confirm 安排修剪任务。
- 下次重启:修剪会在任何世界加载之前运行,并在对每个受影响的区域进行自动备份之后执行。
如果因崩溃中断?它会再次运行:它是幂等的,永远不会覆盖原始备份。你甚至可以只保留玩家实际访问过的区块(inhabited <ticks>)。
? 专为团队设计
每位管理员(以及控制台)都有自己的独立选区。两名工作人员可以同时设置不同的区域而不会互相覆盖。
⌨️ 现代化命令
原生 Brigadier 命令,支持 Tab 补全、红色内联错误提示及子命令级权限控制,因此玩家只能看到他们有权使用的命令。提供可点击的帮助信息。半径单位支持方块、区块、区域或千位计数法:500、32c、2r、5k、+100。
? 实时查看进度
- 带有每个世界实时进度的Boss 栏(
/pregen watch)
- 速度(区块/秒)、预计剩余时间 (ETA) 和跨重启保持的已用时间
/pregen doctor 检查你的服务器设置,并告诉你是什么拖慢了生成速度
? 支持玩家的语言
内置西班牙语和英语。每位玩家看到的消息都使用其客户端语言。所有文本均可使用 MiniMessage 进行编辑(支持渐变、悬停、点击效果)。
? 永不丢失进度
进度每几秒自动保存一次,并在关闭服务器时保存。任务在重启后(即使发生崩溃)自动恢复。
? 形状与模式
9 种形状: 正方形、矩形、圆形、椭圆、菱形、三角形、五边形、六边形、星形。
6 种生成顺序:
| 模式 |
适用场景 |
region (默认) |
一次性完成每个 32×32 的区域文件:对磁盘最友好 |
spiral |
每个区块紧邻上一个区块 |
concentric |
从中心向外扩散的正方形环 |
loop |
逐行扫描 |
csv |
自定义区块列表 |
world |
重新加载所有现有区块(例如升级旧世界) |
? 快速开始
/pregen center spawn
/pregen radius 5k
/pregen shape circle
/pregen start
/pregen watch
或者一行搞定:/pregen start world circle 5k 0 0
? 命令
| 命令 |
描述 |
/pregen start [world] [shape] [radius] [x z] |
开始生成 |
/pregen pause | resume | cancel [world] |
控制任务 |
/pregen status · /pregen watch |
在聊天框或 Boss 栏中查看进度 |
/pregen world | center | radius | corners | worldborder | shape | pattern |
构建你的选区 |
/pregen trim <outside|inside> [inhabited <ticks>] |
试运行,然后安排修剪 |
/pregen trim pending | unschedule <world> |
管理待处理的修剪任务 |
/pregen doctor · /pregen reload |
诊断工具和重载配置 |
别名:/pg
? 权限
pregen.admin: 所有权限,包括修剪
pregen.operator: 仅生成权限,无破坏性或管理命令(非常适合版主)
pregen.command.<name>: 细粒度的单命令权限
pregen.notify: 接收开始/完成/错误通知
⚙️ 配置亮点
max-concurrent-chunks: 一个预算由所有任务共享,这样处理三个世界不会使负载增加三倍
adaptive-throttle: 目标 Tick 毫秒数
pause-when-players-online: 仅在服务器为空时生成
radius-limit: 限制半径上限(对托管服务商很有用)
trim.backup: 修剪前的自动备份(默认开启)
无效值永远不会导致插件崩溃:它们会回退到安全默认值,并在控制台输出一条清晰的警告。
? 面向开发者
提供文档化的 API(通过 Bukkit 的服务管理器获取 PregenApi)以及真实的 Bukkit 事件:PregenTaskStartEvent(可取消)、PregenTaskProgressEvent、PregenTaskFinishEvent、PregenTrimScheduledEvent(可取消)。
? 来自 Chunky?
Chunky 是一款经过实战检验的优秀工具。Pregen 对活服上最重要的方面采取了不同的方法:
|
Pregen |
Chunky 1.5.3 (Bukkit) |
| 根据服务器 Tick 时间自适应速度 |
✅ |
❌ 固定并发数 |
| 每位管理员独立的选区 |
✅ |
❌ 所有人共享 |
| 带试运行计数的修剪功能 |
✅ |
❌ |
| 修剪前自动备份 |
✅ |
❌ 要求手动备份 |
| 修剪从不编辑已加载的世界 |
✅ 在启动时运行 |
❌ 运行时编辑文件,然后需要重启 |
从不编辑你的 server.properties |
✅ 仅发出警告 |
❌ 更改 Paper 上的 pause-when-empty-seconds |
| 支持 Tab 补全的 Brigadier 命令 |
✅ |
❌ |
| Boss 栏进度显示 |
✅ |
❌ |
| 每位玩家各自语言的提示信息 |
✅ |
❌ 单一服务器全局语言 |
设置诊断 (/pregen doctor) |
✅ |
❌ |
在 config.yml 中调整参数(而非 JVM 标志) |
✅ |
❌ |
| 遥测数据 |
无 |
bStats |
| Folia 支持、重启后恢复、磁盘空间检查、9 种形状、CSV 导入 |
✅ |
✅ |
比较基于 Chunky 1.5.3 for Bukkit/Paper 的公开可观察行为。Chunky 也运行在 Fabric、Forge 和其他平台上;Pregen 专注于 Paper 和 Folia。
要求: Paper、Folia 或 Purpur 1.21–26.3 · Java 21(1.21.x)或 Java 25(26.x)
提示: 在 1.21.2+ 版本中,请在 server.properties 中设置 pause-when-empty-seconds=0,以便空服务器继续生成区块;使用 /pregen doctor 会提醒你。
Pregen
在不影响服务器性能的前提下预生成你的世界。
Pregen 提前生成地形,让玩家在探索时不再遭遇卡顿,并且安全地执行:它监控每个 tick 的耗时,并在 TPS 下降前减速,且区块裁剪操作绝不会触及已加载的世界。
一个 jar 文件即可支持 Paper、Folia 和 Purpur,涵盖 1.21 至 26.3 版本。无依赖项。无遥测数据。
✨ 为什么选择 Pregen
- ? 仅保护你的 TPS: 根据 tick 时间每秒调整其速度。也可以设置为在没有玩家在线时等待。
- ?️ 安全的裁剪操作: 先进行精确数据的模拟运行,确认后在下一次重启时执行,此时世界尚未加载,并带有自动备份。你可以仅保留玩家访问过的区块。
- ? 为团队设计: 每位管理员都有自己的独立选择范围。
- ⌨️ 现代 Brigadier 命令: 支持自动补全、红色错误提示以及子命令权限。支持如
500、32c、2r、5k、+100 等半径格式。
- ? BossBar 显示进度、速率、预计完成时间,以及用于检查服务器的
/pregen doctor 命令。
- ? 西班牙语和英语根据每位玩家的客户端语言自动切换;消息可通过 MiniMessage 编辑。
- ? 不会丢失进度: 采用原子保存机制,重启后自动恢复,即使崩溃也能如此。
? 快速入门
/pregen center spawn → /pregen radius 5k → /pregen shape circle → /pregen start → /pregen watch
要求: Paper、Folia 或 Purpur 1.21–26.3 · Java 21(1.21.x)或 Java 25(26.x)
Pregen 1.0.0:首次发布
- 适用于 Paper、Folia 和 Purpur 1.21–26.3 的自适应区块预生成(单个 jar 文件)
- 基于 tick 时间的自动节流;可选在玩家在线时暂停
- 9 种形状和 6 种生成模式(区域、螺旋、同心圆、循环、CSV、现有世界)
- 安全的裁剪功能:模拟运行、确认、在下一次启动时执行并自动备份,可选基于存活时间过滤
- 每位管理员独立的范围选择、Brigadier 命令、BossBar 进度条、预计完成时间
- 重启和崩溃后自动恢复
- 根据玩家语言提供西班牙语和英语消息,支持 MiniMessage 格式化
/pregen doctor 设置诊断
- 开发者 API 和 Bukkit 事件
Pregen
Pre-generate your world without hurting your server.
Pregen generates terrain ahead of time so players never lag while exploring, and it does it safely: it watches your tick time and slows itself down before your TPS drops, and trimming chunks never touches a loaded world.
One jar for Paper, Folia and Purpur, from 1.21 to 26.3. No dependencies. No telemetry.
✨ Why Pregen
? It protects your TPS on its own
Most pre-generators push a fixed number of chunks no matter what. Pregen reads the server's tick time every second and adapts its speed automatically: it backs off as soon as ticks get slow and speeds up again when there is headroom. You can also hold generation while players are online and let it run when the server is empty.
?️ Trimming that can't corrupt your world
Deleting chunks from region files while the world is loaded is risky. Pregen does it in three safe steps:
- Dry run:
/pregen trim outside shows exactly how many chunks and regions would go and how much space you'd free. Nothing is touched.
- Confirm:
/pregen confirm schedules it.
- Next restart: the trim runs before any world loads, after an automatic backup of every affected region.
Interrupted by a crash? It simply runs again: it's idempotent and never overwrites your original backup. You can even keep only the chunks players actually visited (inhabited <ticks>).
? Built for teams
Every admin (and the console) has their own selection. Two staff members can set up different areas at the same time without overwriting each other.
⌨️ Modern commands
Native Brigadier commands with tab completion, red inline errors and per-subcommand permissions, so players only see what they can use. Clickable help. Radius in blocks, chunks, regions or thousands: 500, 32c, 2r, 5k, +100.
? See what's happening
- Boss bar with live progress per world (
/pregen watch)
- Speed (chunks/s), ETA and elapsed time that survives restarts
/pregen doctor checks your server setup and tells you what's slowing generation down
? Speaks your players' language
Spanish and English included. Every player sees messages in their own client language. All texts are editable with MiniMessage (gradients, hover, click).
? Never lose progress
Progress is saved atomically every few seconds and on shutdown. Tasks resume automatically after a restart, even after a crash.
? Shapes & patterns
9 shapes: square, rectangle, circle, ellipse, diamond, triangle, pentagon, hexagon, star.
6 generation orders:
| Pattern |
Best for |
region (default) |
Finishes each 32×32 region file at once: the easiest on your disk |
spiral |
Every chunk next to the previous one |
concentric |
Square rings from the center |
loop |
Row by row |
csv |
Your own list of chunks |
world |
Re-load every existing chunk (e.g. to upgrade an old world) |
? Quick start
/pregen center spawn
/pregen radius 5k
/pregen shape circle
/pregen start
/pregen watch
Or in one line: /pregen start world circle 5k 0 0
? Commands
| Command |
Description |
/pregen start [world] [shape] [radius] [x z] |
Start generating |
/pregen pause | resume | cancel [world] |
Control tasks |
/pregen status · /pregen watch |
Progress in chat or boss bar |
/pregen world | center | radius | corners | worldborder | shape | pattern |
Build your selection |
/pregen trim <outside|inside> [inhabited <ticks>] |
Dry run, then schedule a trim |
/pregen trim pending | unschedule <world> |
Manage scheduled trims |
/pregen doctor · /pregen reload |
Diagnostics and reload |
Alias: /pg
? Permissions
pregen.admin: everything, including trim
pregen.operator: generation only, no destructive or admin commands (great for moderators)
pregen.command.<name>: fine-grained per command
pregen.notify: receive start/finish/error announcements
⚙️ Configuration highlights
max-concurrent-chunks: one budget shared by all tasks, so three worlds don't triple the load
adaptive-throttle: target milliseconds per tick
pause-when-players-online: generate only on an empty server
radius-limit: cap the radius (handy for hosting providers)
trim.backup: automatic backups before trimming (on by default)
Invalid values never break the plugin: they fall back to safe defaults with one clear console warning.
? For developers
A documented API (PregenApi via Bukkit's services manager) plus real Bukkit events: PregenTaskStartEvent (cancellable), PregenTaskProgressEvent, PregenTaskFinishEvent, PregenTrimScheduledEvent (cancellable).
? Coming from Chunky?
Chunky is a great, battle-tested tool. Pregen takes a different approach to the things that matter most on a live server:
|
Pregen |
Chunky 1.5.3 (Bukkit) |
| Adapts speed to your server's tick time |
✅ |
❌ fixed concurrency |
| One selection per admin |
✅ |
❌ shared by everyone |
| Trim with dry-run counts |
✅ |
❌ |
| Automatic backup before trimming |
✅ |
❌ asks you to back up manually |
| Trim never edits a loaded world |
✅ runs at startup |
❌ edits files at runtime, then requires a restart |
Never edits your server.properties |
✅ only warns |
❌ changes pause-when-empty-seconds on Paper |
| Brigadier commands with tab completion |
✅ |
❌ |
| Boss bar progress |
✅ |
❌ |
| Messages in each player's own language |
✅ |
❌ one server-wide language |
Setup diagnostics (/pregen doctor) |
✅ |
❌ |
Tuning in config.yml (not JVM flags) |
✅ |
❌ |
| Telemetry |
None |
bStats |
| Folia, resume after restart, disk-space check, 9 shapes, CSV import |
✅ |
✅ |
Comparison based on the publicly observable behaviour of Chunky 1.5.3 for Bukkit/Paper. Chunky also runs on Fabric, Forge and other platforms; Pregen focuses on Paper and Folia.
Requirements: Paper, Folia or Purpur 1.21–26.3 · Java 21 (1.21.x) or Java 25 (26.x)
Tip: on 1.21.2+, set pause-when-empty-seconds=0 in server.properties so an empty server keeps generating; /pregen doctor will remind you.
Pregen
Pre-genera tu mundo sin dañar tu servidor.
Pregen genera el terreno por adelantado para que los jugadores no sufran lag al explorar, y lo hace de forma segura: vigila el tiempo por tick y frena antes de que bajen tus TPS, y el recorte de chunks nunca toca un mundo cargado.
Un solo jar para Paper, Folia y Purpur, de la 1.21 a la 26.3. Sin dependencias. Sin telemetría.
✨ Por qué Pregen
- ? Protege tus TPS solo: ajusta su velocidad cada segundo según el tiempo por tick. También puede esperar a que no haya jugadores conectados.
- ?️ Recorte sin riesgo: primero una simulación con cifras exactas, después confirmas y se ejecuta en el próximo reinicio, antes de cargar los mundos y con copia de seguridad automática. Puedes conservar solo los chunks que los jugadores visitaron.
- ? Pensado para equipos: cada admin tiene su propia selección.
- ⌨️ Comandos modernos Brigadier: autocompletado, errores en rojo y permisos por subcomando. Radios como
500, 32c, 2r, 5k, +100.
- ? BossBar de progreso, ritmo, ETA y
/pregen doctor para revisar tu servidor.
- ? Español e inglés según el idioma del cliente de cada jugador; mensajes editables con MiniMessage.
- ? No pierdes progreso: guardado atómico y reanudación automática tras reiniciar, incluso tras un crash.
? Inicio rápido
/pregen center spawn → /pregen radius 5k → /pregen shape circle → /pregen start → /pregen watch
Requisitos: Paper, Folia o Purpur 1.21–26.3 · Java 21 (1.21.x) o Java 25 (26.x)
Pregen 1.0.0: first release
- Adaptive chunk pre-generation for Paper, Folia and Purpur 1.21–26.3 (one jar)
- Auto-throttle based on tick time; optional hold while players are online
- 9 shapes and 6 generation patterns (region, spiral, concentric, loop, CSV, existing world)
- Safe trimming: dry run, confirmation, execution at next startup with automatic backups, optional inhabited-time filter
- Per-admin selections, Brigadier commands, boss bar progress, ETA
- Automatic resume after restarts and crashes
- Spanish and English messages per player, MiniMessage formatting
/pregen doctor setup diagnostics
- Developer API and Bukkit events
评论 0
登录后参与评分
还没有评论,来抢沙发吧