From c91cfc73603fa8fa699f6ea4b846c9a7d70534d1 Mon Sep 17 00:00:00 2001 From: UnknownShadow200 Date: Sun, 22 Mar 2020 23:38:22 +1100 Subject: [PATCH] Fix zones getting lost with /resizelvl (Thanks starlightglimmer) --- MCGalaxy/Commands/World/CmdResizeLvl.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/MCGalaxy/Commands/World/CmdResizeLvl.cs b/MCGalaxy/Commands/World/CmdResizeLvl.cs index 8706dc00d..56905f37b 100644 --- a/MCGalaxy/Commands/World/CmdResizeLvl.cs +++ b/MCGalaxy/Commands/World/CmdResizeLvl.cs @@ -104,6 +104,11 @@ namespace MCGalaxy.Commands.World { lock (lvl.saveLock) { lvl.Backup(true); + + // Make sure zones are kept + res.Zones = lvl.Zones; + lvl.Zones = new VolatileArray(false); + IMapExporter.Formats[0].Write(LevelInfo.MapPath(lvl.name), res); lvl.SaveChanges = false; }