mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-30 16:19:03 +01:00
04ca580aa6
Upstream has released updates that appear to apply and compile correctly. This update has not been tested by PaperMC and as with ANY update, please do your own testing Bukkit Changes: 716b4fce Revert SnakeYAML upgrade ca6f8942 Update to Minecraft 1.18-rc3 57e7e952 #683: Add Player#showDemoScreen CraftBukkit Changes: c98abfb0 Update to Minecraft 1.18-rc3 9b258501 #960: Add Player#showDemoScreen d9542247 Produce remapped jars after bootstrap jar 99f3ddde SPIGOT-6808: Fix RegionAccessor#getBiome Spigot Changes: b7a4222e Update to Minecraft 1.18-rc3
37 lines
2.1 KiB
Diff
37 lines
2.1 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Josh Roy <10731363+JRoy@users.noreply.github.com>
|
|
Date: Mon, 29 Jun 2020 17:03:06 -0400
|
|
Subject: [PATCH] Remove some streams from structures
|
|
|
|
This showed up a lot in the spark profiler, should have a low-medium performance improvement.
|
|
|
|
diff --git a/src/main/java/net/minecraft/world/level/levelgen/Beardifier.java b/src/main/java/net/minecraft/world/level/levelgen/Beardifier.java
|
|
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
|
--- a/src/main/java/net/minecraft/world/level/levelgen/Beardifier.java
|
|
+++ b/src/main/java/net/minecraft/world/level/levelgen/Beardifier.java
|
|
@@ -0,0 +0,0 @@ import net.minecraft.world.level.levelgen.feature.structures.StructureTemplatePo
|
|
import net.minecraft.world.level.levelgen.structure.BoundingBox;
|
|
import net.minecraft.world.level.levelgen.structure.PoolElementStructurePiece;
|
|
import net.minecraft.world.level.levelgen.structure.StructurePiece;
|
|
+import net.minecraft.world.level.levelgen.structure.StructureStart;
|
|
|
|
public class Beardifier implements NoiseChunk.NoiseFiller {
|
|
public static final int BEARD_KERNEL_RADIUS = 12;
|
|
@@ -0,0 +0,0 @@ public class Beardifier implements NoiseChunk.NoiseFiller {
|
|
this.rigids = new ObjectArrayList<>(10);
|
|
|
|
for(StructureFeature<?> structureFeature : StructureFeature.NOISE_AFFECTING_FEATURES) {
|
|
- structureAccessor.startsForFeature(SectionPos.bottomOf(chunk), structureFeature).forEach((start) -> {
|
|
+ for (StructureStart<?> start : structureAccessor.startsForFeature(SectionPos.bottomOf(chunk), structureFeature)) { // Paper - remove streams
|
|
for(StructurePiece structurePiece : start.getPieces()) {
|
|
if (structurePiece.isCloseToChunk(chunkPos, 12)) {
|
|
if (structurePiece instanceof PoolElementStructurePiece) {
|
|
@@ -0,0 +0,0 @@ public class Beardifier implements NoiseChunk.NoiseFiller {
|
|
}
|
|
}
|
|
|
|
- });
|
|
+ } // Paper
|
|
}
|
|
|
|
this.pieceIterator = this.rigids.iterator();
|