mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-01 17:01:56 +01:00
Fix faulty logic in Auto Save check - Fixes #443
This commit is contained in:
parent
8c5be62ad9
commit
c15001e24d
1 changed files with 7 additions and 2 deletions
|
@ -50,10 +50,15 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
|||
return true;
|
||||
}
|
||||
- } else if (this.t && this.world.getTime() >= this.lastSaved + MinecraftServer.getServer().autosavePeriod * 4) { // Spigot - Only save if we've passed 2 auto save intervals without modification
|
||||
+ } else if (this.t && this.world.getTime() >= this.lastSaved + world.paperConfig.autoSavePeriod) { // Spigot // Paper - Make world configurable and incremental
|
||||
return true;
|
||||
- return true;
|
||||
}
|
||||
-
|
||||
- return this.s;
|
||||
+ // This !flag section should say if s(isModified) or t(hasEntities), then check auto save
|
||||
+ return ((this.s || this.t) && this.world.getTime() >= this.lastSaved + world.paperConfig.autoSavePeriod); // Paper - Make world configurable and incremental
|
||||
}
|
||||
|
||||
public Random a(long i) {
|
||||
diff --git a/src/main/java/net/minecraft/server/ChunkProviderServer.java b/src/main/java/net/minecraft/server/ChunkProviderServer.java
|
||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||
--- a/src/main/java/net/minecraft/server/ChunkProviderServer.java
|
||||
|
|
Loading…
Reference in a new issue