Re-add support for full chunk saving so the server save-alls on stop. Fixes BUKKIT-2158

This commit is contained in:
EvilSeph 2012-08-08 03:08:46 -04:00
parent a133bc7182
commit 24809ef986

View file

@ -305,9 +305,11 @@ public abstract class MinecraftServer implements Runnable, IMojangStatistics, IC
if (worldserver != null) { if (worldserver != null) {
if (!flag) { if (!flag) {
log.info("Saving chunks for level \'" + worldserver.getWorldData().getName() + "\'/" + worldserver.worldProvider); log.info("Saving chunks for level \'" + worldserver.getWorldData().getName() + "\'/" + worldserver.worldProvider);
worldserver.save(true, (IProgressUpdate) null); // Perform a full save
} else {
worldserver.save(false, (IProgressUpdate) null); // Queue chunk saving
} }
worldserver.save(false, (IProgressUpdate) null); // Queue chunk saving
worldserver.saveLevel(); worldserver.saveLevel();
WorldSaveEvent event = new WorldSaveEvent(worldserver.getWorld()); WorldSaveEvent event = new WorldSaveEvent(worldserver.getWorld());