Update readme, rename incremental chunk saving

This commit is contained in:
Nassim Jahnke 2021-11-28 16:02:52 +01:00
parent 7d08c18917
commit 9077107f7d
2 changed files with 4 additions and 3 deletions

View file

@ -66,7 +66,7 @@ How To (Compiling Jar From Source)
------ ------
To compile Paper, you need JDK 17 and an internet connection. To compile Paper, you need JDK 17 and an internet connection.
Clone this repo, run `./gradlew applyPatches`, then `./gradlew createReobfBundlerJar` from your terminal. You can find the compiled jar in the `Paper-Server/build/libs` directory. Clone this repo, run `./gradlew applyPatches`, then `./gradlew createReobfBundlerJar` from your terminal. You can find the compiled jar in the project root's `build/libs` directory.
To get a full list of tasks, run `./gradlew tasks`. To get a full list of tasks, run `./gradlew tasks`.

View file

@ -1,7 +1,7 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Shane Freeder <theboyetronic@gmail.com> From: Shane Freeder <theboyetronic@gmail.com>
Date: Sun, 9 Jun 2019 03:53:22 +0100 Date: Sun, 9 Jun 2019 03:53:22 +0100
Subject: [PATCH] incremental chunk saving Subject: [PATCH] incremental chunk and player saving
diff --git a/src/main/java/com/destroystokyo/paper/PaperConfig.java b/src/main/java/com/destroystokyo/paper/PaperConfig.java diff --git a/src/main/java/com/destroystokyo/paper/PaperConfig.java b/src/main/java/com/destroystokyo/paper/PaperConfig.java
@ -78,6 +78,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+ playerSaveInterval = autosavePeriod; + playerSaveInterval = autosavePeriod;
} }
+ this.profiler.push("save"); + this.profiler.push("save");
+ final boolean fullSave = autosavePeriod > 0 && this.tickCount % autosavePeriod == 0;
+ try { + try {
+ this.isSaving = true; + this.isSaving = true;
+ if (playerSaveInterval > 0) { + if (playerSaveInterval > 0) {
@ -85,7 +86,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+ } + }
+ for (ServerLevel level : this.getAllLevels()) { + for (ServerLevel level : this.getAllLevels()) {
+ if (level.paperConfig.autoSavePeriod > 0) { + if (level.paperConfig.autoSavePeriod > 0) {
+ level.saveIncrementally(autosavePeriod > 0 && this.tickCount % autosavePeriod == 0); + level.saveIncrementally(fullSave);
+ } + }
+ } + }
+ } finally { + } finally {