Update upstream, fix patches
This commit is contained in:
@@ -17,7 +17,7 @@ index a6f58b3457b7477015c5c6d969e7d83017dd3fa1..7f2070bd2d7eb7f0256a96df00103d20
|
||||
|
||||
public BlockUpdates blockUpdates;
|
||||
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
|
||||
index 078f6e9d081f6efd9417da0798197cf4b5661198..b71fa704c812c138cb44c7580a61ddec15bdc18d 100644
|
||||
index 544f8b6c9f2b5d1f9681cc97db09e815e77f8765..a7335d9f890397eff67d0063d077e263a66d2fdd 100644
|
||||
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
|
||||
@@ -2,6 +2,7 @@ package net.minecraft.server;
|
||||
@@ -28,16 +28,16 @@ index 078f6e9d081f6efd9417da0798197cf4b5661198..b71fa704c812c138cb44c7580a61ddec
|
||||
import com.google.common.collect.ImmutableList;
|
||||
import co.aikar.timings.Timings;
|
||||
import com.destroystokyo.paper.event.server.PaperServerListPingEvent;
|
||||
@@ -315,6 +316,8 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
public static final long SERVER_INIT = System.nanoTime();
|
||||
// Paper end - lag compensation
|
||||
@@ -312,6 +313,8 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
public volatile boolean abnormalExit = false; // Paper
|
||||
public static final long SERVER_INIT = System.nanoTime(); // Paper - Lag compensation
|
||||
|
||||
+ @Nullable DimensionDataStorage sharedDataStorage; // Slice
|
||||
+
|
||||
public static <S extends MinecraftServer> S spin(Function<Thread, S> serverFactory) {
|
||||
AtomicReference<S> atomicreference = new AtomicReference();
|
||||
Thread thread = new io.papermc.paper.util.TickThread(() -> { // Paper - rewrite chunk system
|
||||
@@ -416,6 +419,12 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -413,6 +416,12 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
this.paperConfigurations = services.paperConfigurations(); // Paper - add paper configuration files
|
||||
}
|
||||
|
||||
@@ -50,7 +50,7 @@ index 078f6e9d081f6efd9417da0798197cf4b5661198..b71fa704c812c138cb44c7580a61ddec
|
||||
private void readScoreboard(DimensionDataStorage persistentStateManager) {
|
||||
persistentStateManager.computeIfAbsent(this.getScoreboard().dataFactory(), "scoreboard");
|
||||
}
|
||||
@@ -919,6 +928,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -916,6 +925,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
this.isSaving = true;
|
||||
this.getPlayerList().saveAll(); // Paper - Incremental chunk and player saving; diff on change
|
||||
flag3 = this.saveAllChunks(suppressLogs, flush, force);
|
||||
@@ -58,7 +58,7 @@ index 078f6e9d081f6efd9417da0798197cf4b5661198..b71fa704c812c138cb44c7580a61ddec
|
||||
} finally {
|
||||
this.isSaving = false;
|
||||
}
|
||||
@@ -1133,6 +1143,15 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1130,6 +1140,15 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
throw new IllegalStateException("Failed to initialize server");
|
||||
}
|
||||
|
||||
@@ -74,7 +74,7 @@ index 078f6e9d081f6efd9417da0798197cf4b5661198..b71fa704c812c138cb44c7580a61ddec
|
||||
this.nextTickTimeNanos = Util.getNanos();
|
||||
this.statusIcon = (ServerStatus.Favicon) this.loadStatusIcon().orElse(null); // CraftBukkit - decompile error
|
||||
this.status = this.buildServerStatus();
|
||||
@@ -1533,6 +1552,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1531,6 +1550,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
level.saveIncrementally(fullSave);
|
||||
}
|
||||
}
|
||||
@@ -83,10 +83,10 @@ index 078f6e9d081f6efd9417da0798197cf4b5661198..b71fa704c812c138cb44c7580a61ddec
|
||||
this.isSaving = false;
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||
index 7f81f3c3339ee1858013a2e1b18c457d9f3eaf03..abdd05abf86567da495682e0613322cdcb4d9c59 100644
|
||||
index f033f530eef10177c349f2673bb3ee8ebdb1d30b..ebd5fe9f64672b01e3981c19aa9464e8f20dbc03 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||
@@ -2136,7 +2136,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||
@@ -2116,7 +2116,7 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||
@Override
|
||||
public MapItemSavedData getMapData(String id) {
|
||||
// Paper start - Call missing map initialize event and set id
|
||||
@@ -95,7 +95,7 @@ index 7f81f3c3339ee1858013a2e1b18c457d9f3eaf03..abdd05abf86567da495682e0613322cd
|
||||
|
||||
final net.minecraft.world.level.saveddata.SavedData existing = storage.cache.get(id);
|
||||
if (existing == null && !storage.cache.containsKey(id)) {
|
||||
@@ -2163,12 +2163,22 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||
@@ -2143,12 +2143,22 @@ public class ServerLevel extends Level implements WorldGenLevel {
|
||||
MapInitializeEvent event = new MapInitializeEvent(state.mapView);
|
||||
Bukkit.getServer().getPluginManager().callEvent(event);
|
||||
// CraftBukkit end
|
||||
@@ -119,4 +119,4 @@ index 7f81f3c3339ee1858013a2e1b18c457d9f3eaf03..abdd05abf86567da495682e0613322cd
|
||||
+ // Slice end
|
||||
}
|
||||
|
||||
// Paper start - helper function for configurable spawn radius
|
||||
// Paper start - Configurable Keep Spawn Loaded range per world
|
||||
|
||||
Reference in New Issue
Block a user