mirror of
https://github.com/BX-Team/DivineMC.git
synced 2025-12-19 14:59:25 +00:00
Updated Upstream (Purpur)
Upstream has released updates that appear to apply and compile correctly Purpur Changes: PurpurMC/Purpur@49f28912 Updated Upstream (Paper)
This commit is contained in:
81
.idea/icon.svg
generated
Normal file
81
.idea/icon.svg
generated
Normal file
File diff suppressed because one or more lines are too long
|
After Width: | Height: | Size: 66 KiB |
24
.idea/runConfigurations/Create_Mojmap_Paperclip.xml
generated
Normal file
24
.idea/runConfigurations/Create_Mojmap_Paperclip.xml
generated
Normal file
@@ -0,0 +1,24 @@
|
||||
<component name="ProjectRunConfigurationManager">
|
||||
<configuration default="false" name="Create Mojmap Paperclip" type="GradleRunConfiguration" factoryName="Gradle">
|
||||
<ExternalSystemSettings>
|
||||
<option name="executionName" />
|
||||
<option name="externalProjectPath" value="$PROJECT_DIR$" />
|
||||
<option name="externalSystemIdString" value="GRADLE" />
|
||||
<option name="scriptParameters" value="" />
|
||||
<option name="taskDescriptions">
|
||||
<list />
|
||||
</option>
|
||||
<option name="taskNames">
|
||||
<list>
|
||||
<option value="createMojmapPaperclipJar" />
|
||||
</list>
|
||||
</option>
|
||||
<option name="vmOptions" />
|
||||
</ExternalSystemSettings>
|
||||
<ExternalSystemDebugServerProcess>true</ExternalSystemDebugServerProcess>
|
||||
<ExternalSystemReattachDebugProcess>true</ExternalSystemReattachDebugProcess>
|
||||
<DebugAllEnabled>false</DebugAllEnabled>
|
||||
<RunAsTest>false</RunAsTest>
|
||||
<method v="2" />
|
||||
</configuration>
|
||||
</component>
|
||||
8
.idea/runConfigurations/Run_DivineMC_Paperclip_Jar.xml
generated
Normal file
8
.idea/runConfigurations/Run_DivineMC_Paperclip_Jar.xml
generated
Normal file
@@ -0,0 +1,8 @@
|
||||
<component name="ProjectRunConfigurationManager">
|
||||
<configuration default="false" name="Run DivineMC Paperclip Jar" type="JarApplication">
|
||||
<option name="JAR_PATH" value="$PROJECT_DIR$/divinemc-server/build/libs/divinemc-paperclip-1.21.10-R0.1-SNAPSHOT-mojmap.jar" />
|
||||
<option name="VM_PARAMETERS" value="-Dcom.mojang.eula.agree" />
|
||||
<option name="WORKING_DIRECTORY" value="$PROJECT_DIR$/run" />
|
||||
<option name="ALTERNATIVE_JRE_PATH" />
|
||||
</configuration>
|
||||
</component>
|
||||
@@ -150,7 +150,7 @@
|
||||
implementation("net.neoforged:srgutils:1.0.9") // Mappings handling
|
||||
implementation("net.neoforged:AutoRenamingTool:2.0.3") // Remap plugins
|
||||
@@ -219,30 +_,42 @@
|
||||
implementation("me.lucko:spark-paper:1.10.133-20250413.112336-1")
|
||||
implementation("me.lucko:spark-paper:1.10.152")
|
||||
}
|
||||
|
||||
+// DivineMC start - Hide irrelevant compilation warnings
|
||||
@@ -168,7 +168,7 @@
|
||||
val git = Git(rootProject.layout.projectDirectory.path)
|
||||
val mcVersion = rootProject.providers.gradleProperty("mcVersion").get()
|
||||
val build = System.getenv("BUILD_NUMBER") ?: null
|
||||
- val buildTime = if (build != null) Instant.now() else Instant.EPOCH
|
||||
- val buildTime = providers.environmentVariable("BUILD_STARTED_AT").map(Instant::parse).orElse(Instant.EPOCH).get()
|
||||
+ val buildTime = Instant.now() // DivineMC - Set build time to current
|
||||
val gitHash = git.exec(providers, "rev-parse", "--short=7", "HEAD").get().trim()
|
||||
val implementationVersion = "$mcVersion-${build ?: "DEV"}-$gitHash"
|
||||
|
||||
@@ -120,10 +120,10 @@ index 2c85607bcc62b227485972707c3541247a626524..9e25b6412fadbbecda0430f8554eaa48
|
||||
String awtException = io.papermc.paper.util.ServerEnvironment.awtDependencyCheck();
|
||||
if (awtException != null) {
|
||||
diff --git a/net/minecraft/server/MinecraftServer.java b/net/minecraft/server/MinecraftServer.java
|
||||
index 0c9de646201b41c7e2cbd308cf6c62a1b6b319b3..5d761c36739981897fe165148e528ef6b0e80b8d 100644
|
||||
index 10769fe7a3d99f0464b9d265b9d0b8c9fc25ae5d..31edaf3b34d77656ceb010beb2e33307d84fb117 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -1258,6 +1258,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1263,6 +1263,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
|
||||
protected void runServer() {
|
||||
try {
|
||||
|
||||
@@ -203,7 +203,7 @@ index 18071dcc69cc28471dddb7de94e803ec1e5fc2e4..aa25f5ebaf7d1b22825b962b02dcae02
|
||||
}
|
||||
}
|
||||
diff --git a/net/minecraft/server/MinecraftServer.java b/net/minecraft/server/MinecraftServer.java
|
||||
index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9e37e2a76 100644
|
||||
index 31edaf3b34d77656ceb010beb2e33307d84fb117..d8e5de94e677863e1e7894b186c7cd79ecef43f6 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -117,20 +117,9 @@ import net.minecraft.util.TimeUtil;
|
||||
@@ -241,7 +241,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
private ServerConnectionListener connection;
|
||||
// Paper - per world load listener - moved LevelLoadListener to ServerLevel
|
||||
@Nullable
|
||||
@@ -993,9 +975,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -998,9 +980,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
org.spigotmc.WatchdogThread.doStop(); // Paper - Improved watchdog support
|
||||
// CraftBukkit end
|
||||
this.packetProcessor.close();
|
||||
@@ -251,7 +251,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
|
||||
LOGGER.info("Stopping server");
|
||||
Commands.COMMAND_SENDING_POOL.shutdownNow(); // Paper - Perf: Async command map building; Shutdown and don't bother finishing
|
||||
@@ -1164,10 +1143,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1169,10 +1148,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
|
||||
// note: To avoid possibly spinning forever, only execute tasks that are roughly available at the beginning
|
||||
// of this call. Packet processing and chunk system tasks are possibly always being queued.
|
||||
@@ -262,7 +262,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
// avoid calling MinecraftServer#pollTask - we just want to execute queued tasks
|
||||
while (super.pollTask()) {
|
||||
// execute small amounts of other tasks just in case the number of tasks we are
|
||||
@@ -1176,38 +1151,23 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1181,38 +1156,23 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
((ca.spottedleaf.moonrise.patches.chunk_system.server.ChunkSystemMinecraftServer)this).moonrise$executeMidTickTasks(); // Paper - rewrite chunk system
|
||||
this.packetProcessor.executeSinglePacket();
|
||||
}
|
||||
@@ -301,7 +301,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
this.waitingForNextTick = true;
|
||||
// implement waitForTasks
|
||||
final boolean isLoggingEnabled = this.isTickTimeLoggingEnabled();
|
||||
@@ -1252,7 +1212,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1257,7 +1217,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
} finally {
|
||||
this.waitingForNextTick = false;
|
||||
}
|
||||
@@ -309,7 +309,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
}
|
||||
// Paper end - improve tick loop
|
||||
|
||||
@@ -1340,44 +1299,32 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1345,44 +1304,32 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
// Paper end - improve tick loop
|
||||
|
||||
boolean flag = l == 0L;
|
||||
@@ -375,7 +375,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
this.isReady = true;
|
||||
JvmProfiler.INSTANCE.onServerTick(this.smoothedTickTimeMillis);
|
||||
}
|
||||
@@ -1485,7 +1432,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1490,7 +1437,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
}
|
||||
|
||||
protected void waitUntilNextTick() {
|
||||
@@ -383,7 +383,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
// Paper - improve tick loop - moved to start of tick
|
||||
this.waitingForNextTick = true;
|
||||
|
||||
@@ -1550,7 +1496,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1555,7 +1501,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
|
||||
@Override
|
||||
public void doRunTask(TickTask task) {
|
||||
@@ -391,7 +391,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
super.doRunTask(task);
|
||||
}
|
||||
|
||||
@@ -1640,12 +1585,10 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1645,12 +1590,10 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
|
||||
this.ticksUntilAutosave--;
|
||||
// Paper start - Incremental chunk and player saving
|
||||
@@ -404,7 +404,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
final boolean fullSave = autosavePeriod > 0 && this.tickCount % autosavePeriod == 0;
|
||||
try {
|
||||
this.isSaving = true;
|
||||
@@ -1660,10 +1603,9 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1665,10 +1608,9 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
} finally {
|
||||
this.isSaving = false;
|
||||
}
|
||||
@@ -416,7 +416,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
this.server.spark.executeMainThreadTasks(); // Paper - spark
|
||||
// Paper start - Server Tick Events
|
||||
long endTime = System.nanoTime();
|
||||
@@ -1671,7 +1613,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1676,7 +1618,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
new com.destroystokyo.paper.event.server.ServerTickEndEvent(this.tickCount, ((double)(endTime - this.currentTickStart) / 1000000D), remaining).callEvent();
|
||||
// Paper end - Server Tick Events
|
||||
this.server.spark.tickEnd(((double)(endTime - this.currentTickStart) / 1000000D)); // Paper - spark
|
||||
@@ -424,7 +424,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
long l = Util.getNanos() - nanos;
|
||||
int i1 = this.tickCount % 100;
|
||||
this.aggregatedTickTimesNanos = this.aggregatedTickTimesNanos - this.tickTimesNanos[i1];
|
||||
@@ -1679,16 +1620,12 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1684,16 +1625,12 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
this.tickTimesNanos[i1] = l;
|
||||
this.smoothedTickTimeMillis = this.smoothedTickTimeMillis * 0.8F + (float)l / (float)TimeUtil.NANOSECONDS_PER_MILLISECOND * 0.19999999F;
|
||||
this.logTickMethodTime(nanos);
|
||||
@@ -441,7 +441,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
LOGGER.debug("Autosave finished");
|
||||
}
|
||||
|
||||
@@ -1756,7 +1693,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1761,7 +1698,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
public final io.papermc.paper.threadedregions.EntityScheduler.EntitySchedulerTickList entitySchedulerTickList = new io.papermc.paper.threadedregions.EntityScheduler.EntitySchedulerTickList(); // Paper - optimise Folia entity scheduler
|
||||
|
||||
protected void tickChildren(BooleanSupplier hasTimeLeft) {
|
||||
@@ -449,7 +449,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
this.getPlayerList().getPlayers().forEach(serverPlayer1 -> serverPlayer1.connection.suspendFlushing());
|
||||
this.server.getScheduler().mainThreadHeartbeat(); // CraftBukkit
|
||||
// Paper start - optimise Folia entity scheduler
|
||||
@@ -1771,9 +1707,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1776,9 +1712,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
// Paper end - optimise Folia entity scheduler
|
||||
io.papermc.paper.adventure.providers.ClickCallbackProviderImpl.ADVENTURE_CLICK_MANAGER.handleQueue(this.tickCount); // Paper
|
||||
io.papermc.paper.adventure.providers.ClickCallbackProviderImpl.DIALOG_CLICK_MANAGER.handleQueue(this.tickCount); // Paper
|
||||
@@ -459,7 +459,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
this.updateEffectiveRespawnData();
|
||||
|
||||
// CraftBukkit start
|
||||
@@ -1810,17 +1744,12 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1815,17 +1749,12 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
serverLevel.updateLagCompensationTick(); // Paper - lag compensation
|
||||
net.minecraft.world.level.block.entity.HopperBlockEntity.skipHopperEvents = serverLevel.paperConfig().hopper.disableMoveEvent || org.bukkit.event.inventory.InventoryMoveItemEvent.getHandlerList().getRegisteredListeners().length == 0; // Paper - Perf: Optimize Hoppers
|
||||
serverLevel.hasRidableMoveEvent = org.purpurmc.purpur.event.entity.RidableMoveEvent.getHandlerList().getRegisteredListeners().length > 0; // Purpur - Ridables
|
||||
@@ -477,7 +477,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
try {
|
||||
serverLevel.tick(hasTimeLeft);
|
||||
} catch (Throwable var7) {
|
||||
@@ -1829,37 +1758,25 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1834,37 +1763,25 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
throw new ReportedException(crashReport);
|
||||
}
|
||||
|
||||
@@ -515,7 +515,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
}
|
||||
|
||||
// Paper start - per world respawn data - read "server global" respawn data from overworld dimension reference
|
||||
@@ -1884,14 +1801,9 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1889,14 +1806,9 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
}
|
||||
|
||||
public void forceTimeSynchronization() {
|
||||
@@ -530,7 +530,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
}
|
||||
|
||||
public boolean isAllowedToEnterPortal(Level level) {
|
||||
@@ -2736,55 +2648,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -2741,55 +2653,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
}
|
||||
// CraftBukkit end
|
||||
|
||||
@@ -586,7 +586,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
public Path getWorldPath(LevelResource levelResource) {
|
||||
return this.storageSource.getLevelPath(levelResource);
|
||||
}
|
||||
@@ -2834,24 +2697,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -2839,24 +2702,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
return this.isSaving;
|
||||
}
|
||||
|
||||
@@ -611,7 +611,7 @@ index 5d761c36739981897fe165148e528ef6b0e80b8d..18c3599ceb7a1c9dc769af0ad4c3eff9
|
||||
public int getMaxChainedNeighborUpdates() {
|
||||
return 1000000;
|
||||
}
|
||||
@@ -2999,55 +2844,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -3004,55 +2849,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
public record ServerResourcePackInfo(UUID id, String url, String hash, boolean isRequired, @Nullable Component prompt) {
|
||||
}
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ Subject: [PATCH] Lag compensation
|
||||
|
||||
|
||||
diff --git a/net/minecraft/server/MinecraftServer.java b/net/minecraft/server/MinecraftServer.java
|
||||
index 18c3599ceb7a1c9dc769af0ad4c3eff9e37e2a76..89aa020832fb9894e057b0f2b1226eb48c8accd1 100644
|
||||
index d8e5de94e677863e1e7894b186c7cd79ecef43f6..8f281339ac390f005baddf00cd09e876cc49e524 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -287,6 +287,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -16,7 +16,7 @@ index 18c3599ceb7a1c9dc769af0ad4c3eff9e37e2a76..89aa020832fb9894e057b0f2b1226eb4
|
||||
// Paper start - improve tick loop
|
||||
public final ca.spottedleaf.moonrise.common.time.TickData tickTimes1s = new ca.spottedleaf.moonrise.common.time.TickData(java.util.concurrent.TimeUnit.SECONDS.toNanos(1L));
|
||||
public final ca.spottedleaf.moonrise.common.time.TickData tickTimes5s = new ca.spottedleaf.moonrise.common.time.TickData(java.util.concurrent.TimeUnit.SECONDS.toNanos(5L));
|
||||
@@ -1574,6 +1575,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1579,6 +1580,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
}
|
||||
|
||||
this.server.spark.tickStart(); // Paper - spark
|
||||
|
||||
@@ -18,10 +18,10 @@ index 9a7a40c1dcea57ba674d8431077d2477104a456f..8e41097f978800039e6e057c5bbcfcf0
|
||||
new java.util.concurrent.LinkedBlockingQueue<>(),
|
||||
new com.google.common.util.concurrent.ThreadFactoryBuilder()
|
||||
diff --git a/net/minecraft/server/MinecraftServer.java b/net/minecraft/server/MinecraftServer.java
|
||||
index 89aa020832fb9894e057b0f2b1226eb48c8accd1..4ba10f90711ac8b6813f86bcff9635716fdc6028 100644
|
||||
index 8f281339ac390f005baddf00cd09e876cc49e524..a08e56c822b54648f5013e67128c670dd6cb70de 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -2714,8 +2714,11 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -2719,8 +2719,11 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -82,7 +82,7 @@ index 181fdb493f64442c659165c10e237ebc198fb6e2..43363235f3dc696973eee99548b1ae55
|
||||
List<org.bukkit.block.BlockState> states = new java.util.ArrayList<>(level.capturedBlockStates.values());
|
||||
level.capturedBlockStates.clear();
|
||||
diff --git a/net/minecraft/server/MinecraftServer.java b/net/minecraft/server/MinecraftServer.java
|
||||
index 95e39a728b7505a273a6e9c927308ee8931ea756..9e09e9823f53e60c819d43012905fa21d044e283 100644
|
||||
index fa29260810341898169441f6baf72846dbd17d67..b533f3c938ba184bee7dea9f9969b59381c03912 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -289,6 +289,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -93,7 +93,7 @@ index 95e39a728b7505a273a6e9c927308ee8931ea756..9e09e9823f53e60c819d43012905fa21
|
||||
// Paper start - improve tick loop
|
||||
public final ca.spottedleaf.moonrise.common.time.TickData tickTimes1s = new ca.spottedleaf.moonrise.common.time.TickData(java.util.concurrent.TimeUnit.SECONDS.toNanos(1L));
|
||||
public final ca.spottedleaf.moonrise.common.time.TickData tickTimes5s = new ca.spottedleaf.moonrise.common.time.TickData(java.util.concurrent.TimeUnit.SECONDS.toNanos(5L));
|
||||
@@ -374,24 +375,36 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -379,24 +380,36 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
private long lastMidTickExecute;
|
||||
private long lastMidTickExecuteFailure;
|
||||
|
||||
@@ -143,7 +143,7 @@ index 95e39a728b7505a273a6e9c927308ee8931ea756..9e09e9823f53e60c819d43012905fa21
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -1695,6 +1708,18 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1700,6 +1713,18 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
|
||||
public final io.papermc.paper.threadedregions.EntityScheduler.EntitySchedulerTickList entitySchedulerTickList = new io.papermc.paper.threadedregions.EntityScheduler.EntitySchedulerTickList(); // Paper - optimise Folia entity scheduler
|
||||
|
||||
@@ -162,7 +162,7 @@ index 95e39a728b7505a273a6e9c927308ee8931ea756..9e09e9823f53e60c819d43012905fa21
|
||||
protected void tickChildren(BooleanSupplier hasTimeLeft) {
|
||||
this.getPlayerList().getPlayers().forEach(serverPlayer1 -> serverPlayer1.connection.suspendFlushing());
|
||||
this.server.getScheduler().mainThreadHeartbeat(); // CraftBukkit
|
||||
@@ -1741,28 +1766,43 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1746,28 +1771,43 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
}
|
||||
|
||||
this.isIteratingOverLevels = true; // Paper - Throw exception on world create while being ticked
|
||||
@@ -224,7 +224,7 @@ index 95e39a728b7505a273a6e9c927308ee8931ea756..9e09e9823f53e60c819d43012905fa21
|
||||
this.isIteratingOverLevels = false; // Paper - Throw exception on world create while being ticked
|
||||
|
||||
this.tickConnection();
|
||||
@@ -1850,6 +1890,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1855,6 +1895,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
Map<ResourceKey<Level>, ServerLevel> oldLevels = this.levels;
|
||||
Map<ResourceKey<Level>, ServerLevel> newLevels = Maps.newLinkedHashMap(oldLevels);
|
||||
newLevels.remove(level.dimension());
|
||||
|
||||
@@ -5,10 +5,10 @@ Subject: [PATCH] MSPT Tracking for each world
|
||||
|
||||
|
||||
diff --git a/net/minecraft/server/MinecraftServer.java b/net/minecraft/server/MinecraftServer.java
|
||||
index 9e09e9823f53e60c819d43012905fa21d044e283..e3fb85c466aca52bd4431aabbc13a4de58c2f474 100644
|
||||
index b533f3c938ba184bee7dea9f9969b59381c03912..1c60d0384e3f5cc9f719fdd2ca2960af407114a0 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -1711,7 +1711,15 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1716,7 +1716,15 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
// DivineMC start - Parallel world ticking
|
||||
private void tickLevel(ServerLevel serverLevel, BooleanSupplier hasTimeLeft) {
|
||||
try {
|
||||
|
||||
@@ -20,10 +20,10 @@ index 3e4241976fdfe65bc0aae90a9097770745c0ddf1..98b101fde04fbf5507f021bb8d8e6bed
|
||||
if (var3 instanceof ReportedException reportedException && reportedException.getCause() instanceof OutOfMemoryError) {
|
||||
throw PacketUtils.makeReportedException(var3, this.packet, this.listener);
|
||||
diff --git a/net/minecraft/server/MinecraftServer.java b/net/minecraft/server/MinecraftServer.java
|
||||
index e3fb85c466aca52bd4431aabbc13a4de58c2f474..db392b8596f1f0438894a9fa8246beeb69ce0fd6 100644
|
||||
index 1c60d0384e3f5cc9f719fdd2ca2960af407114a0..949b8129ec014c76a1558a9011633f1a6405f2d7 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -1720,6 +1720,10 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1725,6 +1725,10 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
serverLevel.tickTimes10s.add(this.tickCount, j);
|
||||
serverLevel.tickTimes60s.add(this.tickCount, j);
|
||||
// DivineMC end - MSPT Tracking for each world
|
||||
|
||||
@@ -35,10 +35,10 @@ index fb263fa1f30a7dfcb7ec2656abfb38e5fe88eac9..c3be4c2fd4a544967322a45d3b8c0fe7
|
||||
};
|
||||
}
|
||||
diff --git a/net/minecraft/server/MinecraftServer.java b/net/minecraft/server/MinecraftServer.java
|
||||
index db392b8596f1f0438894a9fa8246beeb69ce0fd6..90303969f330b40785795531dedb737743b6123a 100644
|
||||
index 949b8129ec014c76a1558a9011633f1a6405f2d7..7239a712628ae5a7f70d9e5b45b7faa7c8fa9395 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -1824,6 +1824,8 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1829,6 +1829,8 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
GameTestTicker.SINGLETON.tick();
|
||||
}
|
||||
|
||||
|
||||
@@ -60,10 +60,10 @@ index 51c126735ace8fdde89ad97b5cab62f244212db0..23f6ed26b531ea570fdf2ae48c1e2710
|
||||
+ public void moonrise$write(final org.bxteam.divinemc.region.IRegionFile regionFile) throws IOException; // DivineMC - Buffered Linear region format
|
||||
}
|
||||
diff --git a/net/minecraft/server/MinecraftServer.java b/net/minecraft/server/MinecraftServer.java
|
||||
index 90303969f330b40785795531dedb737743b6123a..60e77f74124027cc73fd4366b77fdb54c68273e5 100644
|
||||
index 7239a712628ae5a7f70d9e5b45b7faa7c8fa9395..1c7f170f92d7d184a3a0d79d8046cc266d006076 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -934,10 +934,10 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -939,10 +939,10 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
// CraftBukkit end
|
||||
if (flush) {
|
||||
for (ServerLevel serverLevel : this.getAllLevels()) {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -981,6 +_,13 @@
|
||||
@@ -986,6 +_,13 @@
|
||||
if (this.hasStopped) return;
|
||||
this.hasStopped = true;
|
||||
}
|
||||
@@ -14,7 +14,7 @@
|
||||
if (!hasLoggedStop && isDebugging()) io.papermc.paper.util.TraceUtil.dumpTraceForThread("Server stopped"); // Paper - Debugging
|
||||
shutdownThread = Thread.currentThread(); // Paper - Improved watchdog support
|
||||
org.spigotmc.WatchdogThread.doStop(); // Paper - Improved watchdog support
|
||||
@@ -1073,6 +_,7 @@
|
||||
@@ -1078,6 +_,7 @@
|
||||
// Paper end - rewrite chunk system
|
||||
// Paper start - Improved watchdog support - move final shutdown items here
|
||||
Util.shutdownExecutors();
|
||||
|
||||
@@ -2,7 +2,7 @@ group = org.bxteam.divinemc
|
||||
version=1.21.10-R0.1-SNAPSHOT
|
||||
|
||||
mcVersion=1.21.10
|
||||
purpurRef=c29e73b9922eb76f600f1c9b7dcd493aeaaf82c4
|
||||
purpurRef=49f2891215bdda59a2c1d79f6b96b08d40229a3b
|
||||
experimental=true
|
||||
|
||||
org.gradle.configuration-cache=true
|
||||
|
||||
@@ -48,7 +48,7 @@ mv divinemc-server/build/libs/divinemc-paperclip-"$version"-mojmap.jar "$jarName
|
||||
fi
|
||||
} >> $changelog
|
||||
|
||||
number=$(git log --oneline ver/1.21.8 ^"$(git describe --tags --abbrev=0)" | wc -l)
|
||||
number=$(git log --oneline ver/1.21.10 ^"$(git describe --tags --abbrev=0)" | wc -l)
|
||||
git log --pretty='- [`%h`](https://github.com/BX-Team/DivineMC/commit/%H) %s' "-$number" >> $changelog
|
||||
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user