mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-19 17:37:42 +01:00
Fix compilation issues (#1530)
This commit is contained in:
@@ -238,10 +238,10 @@ index df00ea382915480be1279a5347872cf7a1417341..b27cb90a52bc7d96d4318979c678a49a
|
||||
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/level/ServerChunkCache.java b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||
index 7dc2ecd8a80b063cec922021bd978ba2c6f8c0fb..8bead89ad6f54f5dbc6b03d90b6bb111fd2c983b 100644
|
||||
index 681fdab250d924a29ca160acffbcbf7f8a3ca78a..fbb1753425a1cd456e4096b9fe506264e3dac505 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/ServerChunkCache.java
|
||||
@@ -418,9 +418,9 @@ public class ServerChunkCache extends ChunkSource {
|
||||
@@ -436,9 +436,9 @@ public class ServerChunkCache extends ChunkSource implements ca.spottedleaf.moon
|
||||
|
||||
public void save(boolean flush) {
|
||||
// Paper - rewrite chunk system
|
||||
@@ -253,7 +253,7 @@ index 7dc2ecd8a80b063cec922021bd978ba2c6f8c0fb..8bead89ad6f54f5dbc6b03d90b6bb111
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -448,26 +448,25 @@ public class ServerChunkCache extends ChunkSource {
|
||||
@@ -466,26 +466,25 @@ public class ServerChunkCache extends ChunkSource implements ca.spottedleaf.moon
|
||||
@Override
|
||||
public void tick(BooleanSupplier shouldKeepTicking, boolean tickChunks) {
|
||||
this.level.getProfiler().push("purge");
|
||||
@@ -286,7 +286,7 @@ index 7dc2ecd8a80b063cec922021bd978ba2c6f8c0fb..8bead89ad6f54f5dbc6b03d90b6bb111
|
||||
this.level.getProfiler().pop();
|
||||
this.clearCache();
|
||||
}
|
||||
@@ -484,7 +483,7 @@ public class ServerChunkCache extends ChunkSource {
|
||||
@@ -502,7 +501,7 @@ public class ServerChunkCache extends ChunkSource implements ca.spottedleaf.moon
|
||||
gameprofilerfiller.push("filteringLoadedChunks");
|
||||
List<ServerChunkCache.ChunkAndHolder> list = Lists.newArrayListWithCapacity(this.chunkMap.size());
|
||||
Iterator iterator = this.chunkMap.getChunks().iterator();
|
||||
@@ -295,7 +295,7 @@ index 7dc2ecd8a80b063cec922021bd978ba2c6f8c0fb..8bead89ad6f54f5dbc6b03d90b6bb111
|
||||
|
||||
while (iterator.hasNext()) {
|
||||
ChunkHolder playerchunk = (ChunkHolder) iterator.next();
|
||||
@@ -497,7 +496,7 @@ public class ServerChunkCache extends ChunkSource {
|
||||
@@ -515,7 +514,7 @@ public class ServerChunkCache extends ChunkSource implements ca.spottedleaf.moon
|
||||
|
||||
if (this.level.tickRateManager().runsNormally()) {
|
||||
gameprofilerfiller.popPush("naturalSpawnCount");
|
||||
@@ -304,7 +304,7 @@ index 7dc2ecd8a80b063cec922021bd978ba2c6f8c0fb..8bead89ad6f54f5dbc6b03d90b6bb111
|
||||
int k = this.distanceManager.getNaturalSpawnChunkCount();
|
||||
// Paper start - Optional per player mob spawns
|
||||
int naturalSpawnChunkCount = k;
|
||||
@@ -522,7 +521,7 @@ public class ServerChunkCache extends ChunkSource {
|
||||
@@ -540,7 +539,7 @@ public class ServerChunkCache extends ChunkSource implements ca.spottedleaf.moon
|
||||
spawnercreature_d = NaturalSpawner.createState(naturalSpawnChunkCount, this.level.getAllEntities(), this::getFullChunk, !this.level.paperConfig().entities.spawning.perPlayerMobSpawns ? new LocalMobCapCalculator(this.chunkMap) : null, false);
|
||||
}
|
||||
// Paper end - Optional per player mob spawns
|
||||
@@ -313,7 +313,7 @@ index 7dc2ecd8a80b063cec922021bd978ba2c6f8c0fb..8bead89ad6f54f5dbc6b03d90b6bb111
|
||||
|
||||
this.lastSpawnState = spawnercreature_d;
|
||||
gameprofilerfiller.popPush("spawnAndTick");
|
||||
@@ -558,21 +557,21 @@ public class ServerChunkCache extends ChunkSource {
|
||||
@@ -576,21 +575,21 @@ public class ServerChunkCache extends ChunkSource implements ca.spottedleaf.moon
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -341,10 +341,10 @@ index 7dc2ecd8a80b063cec922021bd978ba2c6f8c0fb..8bead89ad6f54f5dbc6b03d90b6bb111
|
||||
gameprofilerfiller.pop();
|
||||
gameprofilerfiller.pop();
|
||||
diff --git a/src/main/java/net/minecraft/server/level/ServerLevel.java b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||
index 49f77274309befcdef1548e875480b9f667a414e..e78d3a8e286a0f62b0211dec91cac1ca64f73e52 100644
|
||||
index fda301c5bb53bc04d9cb133c45d791fa2b30169c..55446501a3bc42e4881eb38b13d1de5d03d22c0d 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/ServerLevel.java
|
||||
@@ -687,7 +687,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
@@ -686,7 +686,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
}
|
||||
|
||||
gameprofilerfiller.popPush("tickPending");
|
||||
@@ -353,7 +353,7 @@ index 49f77274309befcdef1548e875480b9f667a414e..e78d3a8e286a0f62b0211dec91cac1ca
|
||||
if (!this.isDebug() && flag) {
|
||||
j = this.getGameTime();
|
||||
gameprofilerfiller.push("blockTicks");
|
||||
@@ -696,24 +696,24 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
@@ -695,24 +695,24 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
this.fluidTicks.tick(j, paperConfig().environment.maxFluidTicks, this::tickFluid); // Paper - configurable max fluid ticks
|
||||
gameprofilerfiller.pop();
|
||||
}
|
||||
@@ -385,7 +385,7 @@ index 49f77274309befcdef1548e875480b9f667a414e..e78d3a8e286a0f62b0211dec91cac1ca
|
||||
}
|
||||
|
||||
this.handlingTick = false;
|
||||
@@ -726,7 +726,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
@@ -725,7 +725,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
|
||||
if (flag1 || this.emptyTime++ < 300) {
|
||||
gameprofilerfiller.push("entities");
|
||||
@@ -394,7 +394,7 @@ index 49f77274309befcdef1548e875480b9f667a414e..e78d3a8e286a0f62b0211dec91cac1ca
|
||||
if (this.dragonFight != null && flag) {
|
||||
gameprofilerfiller.push("dragonFight");
|
||||
this.dragonFight.tick();
|
||||
@@ -734,7 +734,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
@@ -733,7 +733,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
}
|
||||
|
||||
org.spigotmc.ActivationRange.activateEntities(this); // Spigot
|
||||
@@ -403,7 +403,7 @@ index 49f77274309befcdef1548e875480b9f667a414e..e78d3a8e286a0f62b0211dec91cac1ca
|
||||
this.entityTickList.forEach((entity) -> {
|
||||
if (!entity.isRemoved()) {
|
||||
if (false && this.shouldDiscardEntity(entity)) { // CraftBukkit - We prevent spawning in general, so this butchering is not needed
|
||||
@@ -761,8 +761,8 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
@@ -760,8 +760,8 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -414,7 +414,7 @@ index 49f77274309befcdef1548e875480b9f667a414e..e78d3a8e286a0f62b0211dec91cac1ca
|
||||
gameprofilerfiller.pop();
|
||||
this.tickBlockEntities();
|
||||
}
|
||||
@@ -895,7 +895,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
@@ -894,7 +894,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
} // Paper - Option to disable ice and snow
|
||||
|
||||
gameprofilerfiller.popPush("tickBlocks");
|
||||
@@ -423,7 +423,7 @@ index 49f77274309befcdef1548e875480b9f667a414e..e78d3a8e286a0f62b0211dec91cac1ca
|
||||
if (randomTickSpeed > 0) {
|
||||
LevelChunkSection[] achunksection = chunk.getSections();
|
||||
|
||||
@@ -928,7 +928,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
@@ -927,7 +927,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
}
|
||||
}
|
||||
|
||||
@@ -432,7 +432,7 @@ index 49f77274309befcdef1548e875480b9f667a414e..e78d3a8e286a0f62b0211dec91cac1ca
|
||||
gameprofilerfiller.pop();
|
||||
}
|
||||
|
||||
@@ -1242,8 +1242,8 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
@@ -1241,8 +1241,8 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
// Spigot end
|
||||
// Paper start- timings
|
||||
final boolean isActive = org.spigotmc.ActivationRange.checkIfActive(entity);
|
||||
@@ -443,7 +443,7 @@ index 49f77274309befcdef1548e875480b9f667a414e..e78d3a8e286a0f62b0211dec91cac1ca
|
||||
// Paper end - timings
|
||||
entity.setOldPosAndRot();
|
||||
ProfilerFiller gameprofilerfiller = this.getProfiler();
|
||||
@@ -1259,7 +1259,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
@@ -1258,7 +1258,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
entity.postTick(); // CraftBukkit
|
||||
} else { entity.inactiveTick(); } // Paper - EAR 2
|
||||
this.getProfiler().pop();
|
||||
@@ -452,7 +452,7 @@ index 49f77274309befcdef1548e875480b9f667a414e..e78d3a8e286a0f62b0211dec91cac1ca
|
||||
Iterator iterator = entity.getPassengers().iterator();
|
||||
|
||||
while (iterator.hasNext()) {
|
||||
@@ -1276,8 +1276,8 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
@@ -1275,8 +1275,8 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
if (passenger instanceof Player || this.entityTickList.contains(passenger)) {
|
||||
// Paper - EAR 2
|
||||
final boolean isActive = org.spigotmc.ActivationRange.checkIfActive(passenger);
|
||||
@@ -463,7 +463,7 @@ index 49f77274309befcdef1548e875480b9f667a414e..e78d3a8e286a0f62b0211dec91cac1ca
|
||||
// Paper end
|
||||
passenger.setOldPosAndRot();
|
||||
++passenger.tickCount;
|
||||
@@ -1307,7 +1307,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
@@ -1306,7 +1306,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
this.tickPassenger(passenger, entity2);
|
||||
}
|
||||
|
||||
@@ -472,7 +472,7 @@ index 49f77274309befcdef1548e875480b9f667a414e..e78d3a8e286a0f62b0211dec91cac1ca
|
||||
}
|
||||
} else {
|
||||
passenger.stopRiding();
|
||||
@@ -1329,7 +1329,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
@@ -1328,7 +1328,7 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
|
||||
if (!savingDisabled) {
|
||||
org.bukkit.Bukkit.getPluginManager().callEvent(new org.bukkit.event.world.WorldSaveEvent(this.getWorld())); // CraftBukkit
|
||||
@@ -481,7 +481,7 @@ index 49f77274309befcdef1548e875480b9f667a414e..e78d3a8e286a0f62b0211dec91cac1ca
|
||||
if (progressListener != null) {
|
||||
progressListener.progressStartNoAbort(Component.translatable("menu.savingLevel"));
|
||||
}
|
||||
@@ -1339,10 +1339,10 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
@@ -1338,10 +1338,10 @@ public class ServerLevel extends Level implements WorldGenLevel, ca.spottedleaf.
|
||||
progressListener.progressStage(Component.translatable("menu.savingChunks"));
|
||||
}
|
||||
|
||||
@@ -496,7 +496,7 @@ index 49f77274309befcdef1548e875480b9f667a414e..e78d3a8e286a0f62b0211dec91cac1ca
|
||||
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/players/PlayerList.java b/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||
index f4f965a51628a096f6697f4008ec9dba04d30fd2..224ee4649a8e2d3c99ac5ca298233bcb89248fc3 100644
|
||||
index b9c48dfa9c1e091cd674d6168b230ad25b66e94d..51cb32a67f81422fd59ef072633c3de523ff7405 100644
|
||||
--- a/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||
+++ b/src/main/java/net/minecraft/server/players/PlayerList.java
|
||||
@@ -1220,11 +1220,11 @@ public abstract class PlayerList {
|
||||
|
||||
Reference in New Issue
Block a user