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@94bdb19b Updated Upstream (Paper)
This commit is contained in:
@@ -213,7 +213,7 @@ index 18071dcc69cc28471dddb7de94e803ec1e5fc2e4..aa25f5ebaf7d1b22825b962b02dcae02
|
||||
}
|
||||
}
|
||||
diff --git a/net/minecraft/server/MinecraftServer.java b/net/minecraft/server/MinecraftServer.java
|
||||
index e04be8b21514db5b7ecb2419b4b37caf29960c5a..f74804d3152f04e9343ef0fe6a5cfc6cb0187ee7 100644
|
||||
index 6e95dfb560448e2fc97a4e6c9aa5766aa37a39f4..d716f0b5f183d09bd7fc149eaa30b853916e585c 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -114,19 +114,8 @@ import net.minecraft.util.TimeUtil;
|
||||
@@ -260,7 +260,7 @@ index e04be8b21514db5b7ecb2419b4b37caf29960c5a..f74804d3152f04e9343ef0fe6a5cfc6c
|
||||
|
||||
LOGGER.info("Stopping server");
|
||||
Commands.COMMAND_SENDING_POOL.shutdownNow(); // Paper - Perf: Async command map building; Shutdown and don't bother finishing
|
||||
@@ -1275,50 +1254,38 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1276,50 +1255,38 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
// Spigot end
|
||||
|
||||
boolean flag = l == 0L;
|
||||
@@ -336,7 +336,7 @@ index e04be8b21514db5b7ecb2419b4b37caf29960c5a..f74804d3152f04e9343ef0fe6a5cfc6c
|
||||
this.isReady = true;
|
||||
JvmProfiler.INSTANCE.onServerTick(this.smoothedTickTimeMillis);
|
||||
}
|
||||
@@ -1490,7 +1457,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1491,7 +1458,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
|
||||
@Override
|
||||
public void doRunTask(TickTask task) {
|
||||
@@ -344,7 +344,7 @@ index e04be8b21514db5b7ecb2419b4b37caf29960c5a..f74804d3152f04e9343ef0fe6a5cfc6c
|
||||
super.doRunTask(task);
|
||||
}
|
||||
|
||||
@@ -1580,12 +1546,10 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1581,12 +1547,10 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
|
||||
this.ticksUntilAutosave--;
|
||||
// Paper start - Incremental chunk and player saving
|
||||
@@ -357,7 +357,7 @@ index e04be8b21514db5b7ecb2419b4b37caf29960c5a..f74804d3152f04e9343ef0fe6a5cfc6c
|
||||
final boolean fullSave = autosavePeriod > 0 && this.tickCount % autosavePeriod == 0;
|
||||
try {
|
||||
this.isSaving = true;
|
||||
@@ -1600,10 +1564,8 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1601,10 +1565,8 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
} finally {
|
||||
this.isSaving = false;
|
||||
}
|
||||
@@ -368,7 +368,7 @@ index e04be8b21514db5b7ecb2419b4b37caf29960c5a..f74804d3152f04e9343ef0fe6a5cfc6c
|
||||
this.runAllTasks(); // Paper - move runAllTasks() into full server tick (previously for timings)
|
||||
this.server.spark.executeMainThreadTasks(); // Paper - spark
|
||||
// Paper start - Server Tick Events
|
||||
@@ -1612,7 +1574,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1613,7 +1575,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
new com.destroystokyo.paper.event.server.ServerTickEndEvent(this.tickCount, ((double)(endTime - lastTick) / 1000000D), remaining).callEvent();
|
||||
// Paper end - Server Tick Events
|
||||
this.server.spark.tickEnd(((double)(endTime - lastTick) / 1000000D)); // Paper - spark
|
||||
@@ -376,7 +376,7 @@ index e04be8b21514db5b7ecb2419b4b37caf29960c5a..f74804d3152f04e9343ef0fe6a5cfc6c
|
||||
long l = Util.getNanos() - nanos;
|
||||
int i1 = this.tickCount % 100;
|
||||
this.aggregatedTickTimesNanos = this.aggregatedTickTimesNanos - this.tickTimesNanos[i1];
|
||||
@@ -1625,16 +1586,12 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1626,16 +1587,12 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
this.tickTimes60s.add(this.tickCount, l);
|
||||
// Paper end - Add tick times API and /mspt command
|
||||
this.logTickMethodTime(nanos);
|
||||
@@ -393,7 +393,7 @@ index e04be8b21514db5b7ecb2419b4b37caf29960c5a..f74804d3152f04e9343ef0fe6a5cfc6c
|
||||
LOGGER.debug("Autosave finished");
|
||||
}
|
||||
|
||||
@@ -1702,7 +1659,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1703,7 +1660,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) {
|
||||
@@ -401,7 +401,7 @@ index e04be8b21514db5b7ecb2419b4b37caf29960c5a..f74804d3152f04e9343ef0fe6a5cfc6c
|
||||
this.getPlayerList().getPlayers().forEach(serverPlayer1 -> serverPlayer1.connection.suspendFlushing());
|
||||
this.server.getScheduler().mainThreadHeartbeat(); // CraftBukkit
|
||||
// Paper start - optimise Folia entity scheduler
|
||||
@@ -1717,9 +1673,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1718,9 +1674,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
|
||||
@@ -411,7 +411,7 @@ index e04be8b21514db5b7ecb2419b4b37caf29960c5a..f74804d3152f04e9343ef0fe6a5cfc6c
|
||||
|
||||
// CraftBukkit start
|
||||
// Run tasks that are waiting on processing
|
||||
@@ -1755,17 +1709,12 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1756,17 +1710,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
|
||||
@@ -429,7 +429,7 @@ index e04be8b21514db5b7ecb2419b4b37caf29960c5a..f74804d3152f04e9343ef0fe6a5cfc6c
|
||||
try {
|
||||
serverLevel.tick(hasTimeLeft);
|
||||
} catch (Throwable var7) {
|
||||
@@ -1774,34 +1723,24 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1775,34 +1724,24 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
throw new ReportedException(crashReport);
|
||||
}
|
||||
|
||||
@@ -464,7 +464,7 @@ index e04be8b21514db5b7ecb2419b4b37caf29960c5a..f74804d3152f04e9343ef0fe6a5cfc6c
|
||||
}
|
||||
|
||||
public void tickConnection() {
|
||||
@@ -1817,14 +1756,9 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1818,14 +1757,9 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
}
|
||||
|
||||
public void forceTimeSynchronization() {
|
||||
@@ -479,7 +479,7 @@ index e04be8b21514db5b7ecb2419b4b37caf29960c5a..f74804d3152f04e9343ef0fe6a5cfc6c
|
||||
}
|
||||
|
||||
public boolean isLevelEnabled(Level level) {
|
||||
@@ -2643,55 +2577,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -2644,55 +2578,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
}
|
||||
// CraftBukkit end
|
||||
|
||||
@@ -535,7 +535,7 @@ index e04be8b21514db5b7ecb2419b4b37caf29960c5a..f74804d3152f04e9343ef0fe6a5cfc6c
|
||||
public Path getWorldPath(LevelResource levelResource) {
|
||||
return this.storageSource.getLevelPath(levelResource);
|
||||
}
|
||||
@@ -2741,24 +2626,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -2742,24 +2627,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
return this.isSaving;
|
||||
}
|
||||
|
||||
@@ -560,7 +560,7 @@ index e04be8b21514db5b7ecb2419b4b37caf29960c5a..f74804d3152f04e9343ef0fe6a5cfc6c
|
||||
public int getMaxChainedNeighborUpdates() {
|
||||
return 1000000;
|
||||
}
|
||||
@@ -2868,55 +2735,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -2869,55 +2736,6 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
public record ServerResourcePackInfo(UUID id, String url, String hash, boolean isRequired, @Nullable Component prompt) {
|
||||
}
|
||||
|
||||
@@ -1515,7 +1515,7 @@ index 10a749890b432688626811c55ee18eb35eaac1fb..f7b73c4c472e53ea5593d855e7194b4e
|
||||
this.stopUsingItem();
|
||||
this.connection.send(new ClientboundPlayerAbilitiesPacket(this.getAbilities()));
|
||||
diff --git a/net/minecraft/server/network/ServerCommonPacketListenerImpl.java b/net/minecraft/server/network/ServerCommonPacketListenerImpl.java
|
||||
index 63aba275b1b714e3f0d5761709a115b214d0ca69..667ef5b2ab50eeb0491f7fe0bc8913ec29a4603a 100644
|
||||
index 436f753d00f3854c481c95e4ddacfd9fac9932d4..1975aeecbfdebaacecae1c43005d4ff26fa6a263 100644
|
||||
--- a/net/minecraft/server/network/ServerCommonPacketListenerImpl.java
|
||||
+++ b/net/minecraft/server/network/ServerCommonPacketListenerImpl.java
|
||||
@@ -26,7 +26,6 @@ import net.minecraft.network.protocol.cookie.ServerboundCookieResponsePacket;
|
||||
@@ -4006,7 +4006,7 @@ index 39a604c9a53930b53d959b1d2eb504aa964e9a58..0d0380e3955836ce125f777841477503
|
||||
|
||||
@Override
|
||||
diff --git a/net/minecraft/world/entity/Entity.java b/net/minecraft/world/entity/Entity.java
|
||||
index 816c3950fb0bc8b5700f54fb20fd965699bee1ad..989043d73af2c719e6c36ac5d4c35e7d31d3410c 100644
|
||||
index 8941f45781839de877cc742251d48cf24043966c..eb2f896a8f1b92ace8c7d48eecca386b8a750334 100644
|
||||
--- a/net/minecraft/world/entity/Entity.java
|
||||
+++ b/net/minecraft/world/entity/Entity.java
|
||||
@@ -80,8 +80,6 @@ import net.minecraft.tags.TagKey;
|
||||
@@ -4134,7 +4134,7 @@ index 816c3950fb0bc8b5700f54fb20fd965699bee1ad..989043d73af2c719e6c36ac5d4c35e7d
|
||||
}
|
||||
}
|
||||
diff --git a/net/minecraft/world/entity/LivingEntity.java b/net/minecraft/world/entity/LivingEntity.java
|
||||
index 590ccc9d181d401abd1154ae1f16b1230e8195f1..8df6ceea1536b12d87755c8a69e1b652d280600c 100644
|
||||
index 90000923ad33eb29c0e4c2fe9da19edd356bf23c..b35abb66ae175bca7bf339c9ad34cb33647a378e 100644
|
||||
--- a/net/minecraft/world/entity/LivingEntity.java
|
||||
+++ b/net/minecraft/world/entity/LivingEntity.java
|
||||
@@ -69,8 +69,6 @@ import net.minecraft.tags.FluidTags;
|
||||
@@ -5117,7 +5117,7 @@ index 81de6c1bbef1cafd3036e736dd305fbedc8368c6..c2baadcdceb1df6a881d6f73aa4eb4dd
|
||||
// Paper end - Perf: remove streams and optimize collection
|
||||
}
|
||||
diff --git a/net/minecraft/world/ticks/LevelTicks.java b/net/minecraft/world/ticks/LevelTicks.java
|
||||
index 7b2c5a41e91468f1d7989ed58a19fcfbc8ef1eaa..9e606c158b53fdb6723966275457fc5f13b81714 100644
|
||||
index 7ea0273018b1a364a5e2b7bf57da840383c8ffa5..c7f9485191dc797de78e6524c5c2c737581ed838 100644
|
||||
--- a/net/minecraft/world/ticks/LevelTicks.java
|
||||
+++ b/net/minecraft/world/ticks/LevelTicks.java
|
||||
@@ -23,8 +23,6 @@ import net.minecraft.Util;
|
||||
|
||||
@@ -5,7 +5,7 @@ Subject: [PATCH] Lag compensation
|
||||
|
||||
|
||||
diff --git a/net/minecraft/server/MinecraftServer.java b/net/minecraft/server/MinecraftServer.java
|
||||
index 824f9200b66639ad1e3e821c8ae2ea4c66fe0b30..dd88e4d0f72a482e4feea38bc194fc16799adf02 100644
|
||||
index d716f0b5f183d09bd7fc149eaa30b853916e585c..519296e58787a15a0d77de94bc3a591ace2d2ae0 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -288,6 +288,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -16,7 +16,7 @@ index 824f9200b66639ad1e3e821c8ae2ea4c66fe0b30..dd88e4d0f72a482e4feea38bc194fc16
|
||||
|
||||
public static <S extends MinecraftServer> S spin(Function<Thread, S> threadFunction) {
|
||||
ca.spottedleaf.dataconverter.minecraft.datatypes.MCTypeRegistry.init(); // Paper - rewrite data converter system
|
||||
@@ -1535,6 +1536,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1536,6 +1537,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
}
|
||||
|
||||
this.server.spark.tickStart(); // Paper - spark
|
||||
@@ -66,7 +66,7 @@ index 4a2cace22512fe06c1713bc8735e775e3012f3bc..85c4d709b6d04e8f43baf7b900ee59ea
|
||||
this.serverLevelData.setDayTime(time);
|
||||
// Purpur start - Configurable daylight cycle
|
||||
diff --git a/net/minecraft/world/entity/LivingEntity.java b/net/minecraft/world/entity/LivingEntity.java
|
||||
index 33f33a51a7016e214bca1aec8e6cc3910ec3bb42..327b3b1463caafc69e6a5dc0eee577f4af49d202 100644
|
||||
index 3344c477a55b3ed28e8e9847be642ce2cf233995..76a7898c040cd46df6a889535b1d77c8e6de5a91 100644
|
||||
--- a/net/minecraft/world/entity/LivingEntity.java
|
||||
+++ b/net/minecraft/world/entity/LivingEntity.java
|
||||
@@ -523,6 +523,7 @@ public abstract class LivingEntity extends Entity implements Attackable, Waypoin
|
||||
@@ -183,7 +183,7 @@ index 40cb5e6bbcf9dbdb400f1503e86c0804b60e07be..d5352cbb4a64631a0a831de880efa21e
|
||||
BlocksAttacks blocksAttacks = stack.get(DataComponents.BLOCKS_ATTACKS);
|
||||
return blocksAttacks != null ? 72000 : 0;
|
||||
diff --git a/net/minecraft/world/level/GameRules.java b/net/minecraft/world/level/GameRules.java
|
||||
index d510503a8ad272255aeba20a916642828023fd19..2def087994cb6676b6346e7062fd050e7e346c05 100644
|
||||
index c78a68df7f088338b18b6c2511d8db62bb809c52..5ad9ad7303b1322e811f178f03b1853afcd13c96 100644
|
||||
--- a/net/minecraft/world/level/GameRules.java
|
||||
+++ b/net/minecraft/world/level/GameRules.java
|
||||
@@ -366,8 +366,31 @@ public class GameRules {
|
||||
|
||||
@@ -36,10 +36,10 @@ index 758ce439d2e10e6ef42a58d147a77093667e0acd..de622982f864d96a5b76efcd69f1836e
|
||||
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 9dd56cdd243b63d36e2d6a1b0e2aa48aa766c3b6..a5130d66312717737e7b3a6e6f5fac3e4c0a62d7 100644
|
||||
index 519296e58787a15a0d77de94bc3a591ace2d2ae0..c4dc21538a6aa917de81ae11d786e8128c80ebf0 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -2643,8 +2643,11 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -2644,8 +2644,11 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -82,7 +82,7 @@ index ac27ff24f018d8798921c5152e679ceed1e88d8d..ec7d1353b19e55b00c558df8981323ef
|
||||
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 cd084854b4c9938f5d18b9c16fbfa763323f8d8f..a67f276b4b3692207f093930c00eac67553be3b4 100644
|
||||
index 3e06aac4f1a4d3e21efac94bdc78b360c8998ee4..6b658ae60ef9a6733749e9bd77fc491b69bbad44 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -290,6 +290,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -143,7 +143,7 @@ index cd084854b4c9938f5d18b9c16fbfa763323f8d8f..a67f276b4b3692207f093930c00eac67
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -1661,6 +1674,18 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1662,6 +1675,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 cd084854b4c9938f5d18b9c16fbfa763323f8d8f..a67f276b4b3692207f093930c00eac67
|
||||
protected void tickChildren(BooleanSupplier hasTimeLeft) {
|
||||
this.getPlayerList().getPlayers().forEach(serverPlayer1 -> serverPlayer1.connection.suspendFlushing());
|
||||
this.server.getScheduler().mainThreadHeartbeat(); // CraftBukkit
|
||||
@@ -1706,28 +1731,43 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1707,28 +1732,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 cd084854b4c9938f5d18b9c16fbfa763323f8d8f..a67f276b4b3692207f093930c00eac67
|
||||
this.isIteratingOverLevels = false; // Paper - Throw exception on world create while being ticked
|
||||
|
||||
this.tickConnection();
|
||||
@@ -1805,6 +1845,7 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1806,6 +1846,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());
|
||||
@@ -640,7 +640,7 @@ index f9e7532f86122a379692561a639a209a126e8bba..839f6b7696ef85314da185bedba7cfc5
|
||||
if (isLocatorBarEnabledFor(player)) {
|
||||
if (!connection.isBroken()) {
|
||||
diff --git a/net/minecraft/world/entity/Entity.java b/net/minecraft/world/entity/Entity.java
|
||||
index 6963be899ac218bd091e73b72c9ccef82e33de36..85da5aec677d84aea005449d97c1ee3ca616e2e4 100644
|
||||
index 9e53b4297fa786ee863d0cf1855aa0ebd9afc221..cb77b3ab59542bc4e8b50aecb23d98186206a0ad 100644
|
||||
--- a/net/minecraft/world/entity/Entity.java
|
||||
+++ b/net/minecraft/world/entity/Entity.java
|
||||
@@ -3480,14 +3480,34 @@ public abstract class Entity implements SyncedDataHolder, Nameable, EntityAccess
|
||||
|
||||
@@ -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 c56fa00f9443b6a3a44f0b89da9dcfb6a4faf1c8..57d401aa7801c8cd37921086c3349414d9f7af4f 100644
|
||||
index 6b658ae60ef9a6733749e9bd77fc491b69bbad44..76787f940ae156db1af491dff2145673c082a29b 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -1677,7 +1677,15 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1678,7 +1678,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 4535858701b2bb232b9d2feb2af6551526232ddc..aa4dd7517e8be167aef1eaf7aa907e3c
|
||||
if (var4 instanceof ReportedException reportedException && reportedException.getCause() instanceof OutOfMemoryError) {
|
||||
throw makeReportedException(var4, packet, processor);
|
||||
diff --git a/net/minecraft/server/MinecraftServer.java b/net/minecraft/server/MinecraftServer.java
|
||||
index 57d401aa7801c8cd37921086c3349414d9f7af4f..008530bf0f09180ba365fc514b51d22630564de2 100644
|
||||
index 76787f940ae156db1af491dff2145673c082a29b..ca5458d6687a322a2b6494dcd7fa903943beea47 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -1686,6 +1686,10 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1687,6 +1687,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 89c1fa23b7ce507f86c69c8dcc8f0de38bfa8e99..ce422e12d985a274816abf2841bb3a939568b13b 100644
|
||||
index ca5458d6687a322a2b6494dcd7fa903943beea47..b51a7dfd95769766924f25364179ebccb4160a8b 100644
|
||||
--- a/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/net/minecraft/server/MinecraftServer.java
|
||||
@@ -1788,6 +1788,8 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
@@ -1789,6 +1789,8 @@ public abstract class MinecraftServer extends ReentrantBlockableEventLoop<TickTa
|
||||
GameTestTicker.SINGLETON.tick();
|
||||
}
|
||||
|
||||
@@ -48,7 +48,7 @@ index 89c1fa23b7ce507f86c69c8dcc8f0de38bfa8e99..ce422e12d985a274816abf2841bb3a93
|
||||
this.tickables.get(i).run();
|
||||
}
|
||||
diff --git a/net/minecraft/server/network/ServerCommonPacketListenerImpl.java b/net/minecraft/server/network/ServerCommonPacketListenerImpl.java
|
||||
index 2853d8a34038dd521df2a9e5dfe33d50a72cff82..e6e320100fe1609c58215ea8c9e7914cf02ce9a3 100644
|
||||
index e5d6e5ec12168936d6d50b2f38a3cb58150b0af1..2b2cbe361e7d5dd9c8923c73831a9c5a6ec4a6ae 100644
|
||||
--- a/net/minecraft/server/network/ServerCommonPacketListenerImpl.java
|
||||
+++ b/net/minecraft/server/network/ServerCommonPacketListenerImpl.java
|
||||
@@ -61,6 +61,7 @@ public abstract class ServerCommonPacketListenerImpl implements ServerCommonPack
|
||||
|
||||
@@ -203,7 +203,7 @@ public class DivineConfig {
|
||||
|
||||
// Async pathfinding settings
|
||||
public static boolean asyncPathfinding = true;
|
||||
public static int asyncPathfindingMaxThreads = 2;
|
||||
public static int asyncPathfindingMaxThreads = 1;
|
||||
public static int asyncPathfindingKeepalive = 60;
|
||||
public static int asyncPathfindingQueueSize = 0;
|
||||
public static PathfindTaskRejectPolicy asyncPathfindingRejectPolicy = PathfindTaskRejectPolicy.FLUSH_ALL;
|
||||
|
||||
@@ -2,7 +2,7 @@ group = org.bxteam.divinemc
|
||||
version=1.21.8-R0.1-SNAPSHOT
|
||||
|
||||
mcVersion=1.21.8
|
||||
purpurRef=07108b707f75390d377ec290f0263cc3e7b509ca
|
||||
purpurRef=94bdb19b2a74c5b4513eac65cf7b3908bcc2dadc
|
||||
experimental=false
|
||||
|
||||
org.gradle.configuration-cache=true
|
||||
|
||||
Reference in New Issue
Block a user