Updated Upstream (Paper)

Upstream has released updates that appear to apply and compile correctly

Paper Changes:
PaperMC/Paper@2f4281e Remove unused skyLightSources
PaperMC/Paper@00331d9 Fix mushrooms not generating in swamps
PaperMC/Paper@4b0bc74 Initialise default nibble arrays in ChunkAccess directly
This commit is contained in:
granny
2023-10-16 21:49:40 -07:00
parent 7aa6845805
commit 1524516e0a
6 changed files with 17 additions and 17 deletions

View File

@@ -2,7 +2,7 @@ group = org.purpurmc.purpur
version = 1.20.2-R0.1-SNAPSHOT
mcVersion = 1.20.2
paperCommit = e57af7d01e509c747520cc1037169029256289bf
paperCommit = 4b0bc74c90582f2d52d720c795228130545cd103
org.gradle.caching = true
org.gradle.parallel = true

View File

@@ -2995,7 +2995,7 @@ index 081691f9710ff1115e4308f79ed49fbc38941193..765ee7f78532a363813286ef7db2a7e4
}
diff --git a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
index 4abec88caab4116cfa318f7b66c6b1a8346a7401..7edc6f1e642d01299117680edc79c67225c2053c 100644
index 3e9758fa40bf93fe3d315cc66389193bd57bc393..b78476223637722efe12520d3c2e301603abd8a1 100644
--- a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
+++ b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
@@ -86,6 +86,18 @@ public class LevelChunk extends ChunkAccess {
@@ -3017,7 +3017,7 @@ index 4abec88caab4116cfa318f7b66c6b1a8346a7401..7edc6f1e642d01299117680edc79c672
public LevelChunk(Level world, ChunkPos pos) {
this(world, pos, UpgradeData.EMPTY, new LevelChunkTicks<>(), new LevelChunkTicks<>(), 0L, (LevelChunkSection[]) null, (LevelChunk.PostLoadProcessor) null, (BlendingData) null);
}
@@ -113,6 +125,8 @@ public class LevelChunk extends ChunkAccess {
@@ -109,6 +121,8 @@ public class LevelChunk extends ChunkAccess {
this.postLoad = entityLoader;
this.blockTicks = blockTickScheduler;
this.fluidTicks = fluidTickScheduler;

View File

@@ -66,10 +66,10 @@ index 1e2620338f0b6fd1c160a8f8d6b659e273f2f1c9..6c0e33323922de72dcb941a10883a07c
protected Level(WritableLevelData worlddatamutable, ResourceKey<Level> resourcekey, RegistryAccess iregistrycustom, Holder<DimensionType> holder, Supplier<ProfilerFiller> supplier, boolean flag, boolean flag1, long i, int j, org.bukkit.generator.ChunkGenerator gen, org.bukkit.generator.BiomeProvider biomeProvider, org.bukkit.World.Environment env, java.util.function.Function<org.spigotmc.SpigotWorldConfig, io.papermc.paper.configuration.WorldConfiguration> paperWorldConfigCreator, java.util.concurrent.Executor executor) { // Paper - Async-Anti-Xray - Pass executor
this.spigotConfig = new org.spigotmc.SpigotWorldConfig(((net.minecraft.world.level.storage.PrimaryLevelData) worlddatamutable).getLevelName()); // Spigot
diff --git a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
index 7edc6f1e642d01299117680edc79c67225c2053c..2d4586859bd19a5094619d8abd62e466b822d293 100644
index b78476223637722efe12520d3c2e301603abd8a1..e2ea90469352346b43f0a86746179a6adc53d82a 100644
--- a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
+++ b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
@@ -126,7 +126,7 @@ public class LevelChunk extends ChunkAccess {
@@ -122,7 +122,7 @@ public class LevelChunk extends ChunkAccess {
this.blockTicks = blockTickScheduler;
this.fluidTicks = fluidTickScheduler;

View File

@@ -17,10 +17,10 @@ index e38e2e5a7ddba9c140f362021b6be0b0974f7cd1..0b3a06027f2c600960cd88159803be18
} else {
this.startProgress(advancementholder, advancementprogress);
diff --git a/src/main/java/net/minecraft/server/level/WorldGenRegion.java b/src/main/java/net/minecraft/server/level/WorldGenRegion.java
index 877498729c66de9aa6a27c9148f7494d7895615c..acd7468ee3c86d3456e96e4ec3d7e6a4c612e89d 100644
index 50ed7cfe1ecef6d075ba484804827cec83ba2bf2..54f9cd80ac925aa95ff4fdb4d52cbcc2b04263a5 100644
--- a/src/main/java/net/minecraft/server/level/WorldGenRegion.java
+++ b/src/main/java/net/minecraft/server/level/WorldGenRegion.java
@@ -297,6 +297,7 @@ public class WorldGenRegion implements WorldGenLevel {
@@ -318,6 +318,7 @@ public class WorldGenRegion implements WorldGenLevel {
return true;
} else {
// Paper start

View File

@@ -762,10 +762,10 @@ index 9c2d62feff1816f5729060c6192269a5b2d34153..1e3349690d00c7889a381f7c65a3b5bf
}
diff --git a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
index 2d4586859bd19a5094619d8abd62e466b822d293..ad9f63e80975b816f71e12f3801ba9e10c1c0cff 100644
index e2ea90469352346b43f0a86746179a6adc53d82a..ef2f9ee9f32d6a6ad7ec9385335fc368f0ecff32 100644
--- a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
+++ b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
@@ -804,7 +804,7 @@ public class LevelChunk extends ChunkAccess {
@@ -800,7 +800,7 @@ public class LevelChunk extends ChunkAccess {
this.chunkHolder.getEntityChunk().callEntitiesLoadEvent(); // Paper - rewrite chunk system
if (this.needsDecoration) {
@@ -774,7 +774,7 @@ index 2d4586859bd19a5094619d8abd62e466b822d293..ad9f63e80975b816f71e12f3801ba9e1
this.needsDecoration = false;
java.util.Random random = new java.util.Random();
random.setSeed(this.level.getSeed());
@@ -824,7 +824,7 @@ public class LevelChunk extends ChunkAccess {
@@ -820,7 +820,7 @@ public class LevelChunk extends ChunkAccess {
}
}
server.getPluginManager().callEvent(new org.bukkit.event.world.ChunkPopulateEvent(bukkitChunk));
@@ -783,7 +783,7 @@ index 2d4586859bd19a5094619d8abd62e466b822d293..ad9f63e80975b816f71e12f3801ba9e1
}
}
}
@@ -1182,7 +1182,7 @@ public class LevelChunk extends ChunkAccess {
@@ -1178,7 +1178,7 @@ public class LevelChunk extends ChunkAccess {
ProfilerFiller gameprofilerfiller = LevelChunk.this.level.getProfiler();
gameprofilerfiller.push(this::getType);
@@ -792,7 +792,7 @@ index 2d4586859bd19a5094619d8abd62e466b822d293..ad9f63e80975b816f71e12f3801ba9e1
BlockState iblockdata = LevelChunk.this.getBlockState(blockposition);
if (this.blockEntity.getType().isValid(iblockdata)) {
@@ -1204,7 +1204,7 @@ public class LevelChunk extends ChunkAccess {
@@ -1200,7 +1200,7 @@ public class LevelChunk extends ChunkAccess {
// Paper end
// Spigot start
} finally {

View File

@@ -1819,16 +1819,16 @@ index 1e3349690d00c7889a381f7c65a3b5bf3de2ac5b..524301e2438ee2938b59eb2b2e9fc4e0
// Paper start
diff --git a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
index ad9f63e80975b816f71e12f3801ba9e10c1c0cff..6e9b9028f4ea2ff6ecb9398e36a30d70890bdfc5 100644
index ef2f9ee9f32d6a6ad7ec9385335fc368f0ecff32..220e1dbf70e7d51ea69d964eb7e84f55aa5a32d7 100644
--- a/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
+++ b/src/main/java/net/minecraft/world/level/chunk/LevelChunk.java
@@ -461,11 +461,11 @@ public class LevelChunk extends ChunkAccess {
@@ -457,11 +457,11 @@ public class LevelChunk extends ChunkAccess {
if (LightEngine.hasDifferentLightProperties(this, blockposition, iblockdata1, iblockdata)) {
ProfilerFiller gameprofilerfiller = this.level.getProfiler();
- gameprofilerfiller.push("updateSkyLightSources");
+ //gameprofilerfiller.push("updateSkyLightSources"); // Purpur
this.skyLightSources.update(this, j, i, l);
// Paper - starlight - remove skyLightSources
- gameprofilerfiller.popPush("queueCheckLight");
+ //gameprofilerfiller.popPush("queueCheckLight"); // Purpur
this.level.getChunkSource().getLightEngine().checkBlock(blockposition);
@@ -1837,7 +1837,7 @@ index ad9f63e80975b816f71e12f3801ba9e10c1c0cff..6e9b9028f4ea2ff6ecb9398e36a30d70
}
boolean flag3 = iblockdata1.hasBlockEntity();
@@ -1179,9 +1179,9 @@ public class LevelChunk extends ChunkAccess {
@@ -1175,9 +1175,9 @@ public class LevelChunk extends ChunkAccess {
if (LevelChunk.this.isTicking(blockposition)) {
try {
@@ -1849,7 +1849,7 @@ index ad9f63e80975b816f71e12f3801ba9e10c1c0cff..6e9b9028f4ea2ff6ecb9398e36a30d70
//this.blockEntity.tickTimer.startTiming(); // Spigot // Purpur
BlockState iblockdata = LevelChunk.this.getBlockState(blockposition);
@@ -1193,7 +1193,7 @@ public class LevelChunk extends ChunkAccess {
@@ -1189,7 +1189,7 @@ public class LevelChunk extends ChunkAccess {
LevelChunk.LOGGER.warn("Block entity {} @ {} state {} invalid for ticking:", new Object[]{LogUtils.defer(this::getType), LogUtils.defer(this::getPos), iblockdata});
}