From 2f5c1b759d1b904930312349e69d11f67ee3a07e Mon Sep 17 00:00:00 2001 From: Starbeamrainbowlabs Date: Sun, 7 Feb 2021 01:35:06 +0000 Subject: [PATCH] //subdivide: fix undefined variable; update reference --- Chat-Command-Reference.md | 2 ++ worldeditadditions_commands/commands/meta/subdivide.lua | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/Chat-Command-Reference.md b/Chat-Command-Reference.md index 54128d2..d1e4bcd 100644 --- a/Chat-Command-Reference.md +++ b/Chat-Command-Reference.md @@ -359,6 +359,8 @@ Note that this command only works with WorldEdit commands, and only those which Note also that `` should _not_ be prefixed with _any_ forward slashes - see the examples below. +While other server commands can be executed while a `//subdivide` is running, `//subdivide` manipulates your player's defined region when running. This has the side-effect that you can check on where it has got up to with `//p get` for example - but means that attempting to change your pos1 & pos2 manually will have no effect until the `//subdivide` completes. + **Warning:** Once started, this command cannot be stopped without restarting your server! This is the case with all WorldEdit commands, but it's worth a special mention here. ``` diff --git a/worldeditadditions_commands/commands/meta/subdivide.lua b/worldeditadditions_commands/commands/meta/subdivide.lua index 95ae1ca..c9200e4 100644 --- a/worldeditadditions_commands/commands/meta/subdivide.lua +++ b/worldeditadditions_commands/commands/meta/subdivide.lua @@ -114,7 +114,7 @@ worldedit.register_command("subdivide", { worldedit.player_notify_unsuppress(name) -- Send updates every 2 seconds, and after the first 3 chunks are done - if worldeditadditions.get_ms_time() - time_last_msg > 2 * 1000 or i == 3 or i == stats.chunks_total then + if worldeditadditions.get_ms_time() - time_last_msg > 2 * 1000 or stats.chunks_completed == 3 or stats.chunks_completed == stats.chunks_total then worldedit.player_notify(name, string.format("%s%d / %d (~%.2f%%) complete | last chunk: %s, average: %s, %.2f%% emerge overhead, ETA: ~%s", msg_prefix,