mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-24 19:46:21 +01:00
Made the save-all modification respect the original save state.
This commit is contained in:
parent
605bfd972f
commit
bc5924bbc5
@ -30,9 +30,10 @@ public class ConsoleCommandHandler {
|
|||||||
this.server.a();
|
this.server.a();
|
||||||
} else if (s.toLowerCase().startsWith("save-all")) {
|
} else if (s.toLowerCase().startsWith("save-all")) {
|
||||||
this.print(s1, "Forcing save..");
|
this.print(s1, "Forcing save..");
|
||||||
|
boolean save = worldserver.y; // CraftBukkit - record current save flag state.
|
||||||
worldserver.y = false; // CraftBukkit - If save-all is used, we can assume saving should be turned on to allow for saving.
|
worldserver.y = false; // CraftBukkit - If save-all is used, we can assume saving should be turned on to allow for saving.
|
||||||
this.server.saveChunks(); // CraftBukkit - We should save all worlds on save-all.
|
this.server.saveChunks(); // CraftBukkit - We should save all worlds on save-all.
|
||||||
worldserver.y = true; // CraftBukkit - Once done saving, we should turn it back off to avoid confusion.
|
worldserver.y = save; // CraftBukkit start - Once done saving, we should turn it back off to avoid confusion if it was originally off.
|
||||||
this.print(s1, "Save complete.");
|
this.print(s1, "Save complete.");
|
||||||
} else if (s.toLowerCase().startsWith("save-off")) {
|
} else if (s.toLowerCase().startsWith("save-off")) {
|
||||||
this.print(s1, "Disabling level saving..");
|
this.print(s1, "Disabling level saving..");
|
||||||
|
Loading…
Reference in New Issue
Block a user