diff --git a/nms-patches/ChunkStatus.patch b/nms-patches/ChunkStatus.patch new file mode 100644 index 0000000000..5893431741 --- /dev/null +++ b/nms-patches/ChunkStatus.patch @@ -0,0 +1,20 @@ +--- a/net/minecraft/server/ChunkStatus.java ++++ b/net/minecraft/server/ChunkStatus.java +@@ -27,7 +27,7 @@ + }); + public static final ChunkStatus STRUCTURE_STARTS = a("structure_starts", ChunkStatus.EMPTY, 0, ChunkStatus.n, ChunkStatus.Type.PROTOCHUNK, (chunkstatus, worldserver, chunkgenerator, definedstructuremanager, lightenginethreaded, function, list, ichunkaccess) -> { + if (!ichunkaccess.getChunkStatus().b(chunkstatus)) { +- if (worldserver.getMinecraftServer().getSaveData().getGeneratorSettings().shouldGenerateMapFeatures()) { ++ if (worldserver.worldDataServer.getGeneratorSettings().shouldGenerateMapFeatures()) { // CraftBukkit + chunkgenerator.createStructures(worldserver.getStructureManager(), ichunkaccess, definedstructuremanager, worldserver.getSeed()); + } + +@@ -90,7 +90,7 @@ + return (CompletableFuture) function.apply(ichunkaccess); + }); + private static final List q = ImmutableList.of(ChunkStatus.FULL, ChunkStatus.FEATURES, ChunkStatus.LIQUID_CARVERS, ChunkStatus.STRUCTURE_STARTS, ChunkStatus.STRUCTURE_STARTS, ChunkStatus.STRUCTURE_STARTS, ChunkStatus.STRUCTURE_STARTS, ChunkStatus.STRUCTURE_STARTS, ChunkStatus.STRUCTURE_STARTS, ChunkStatus.STRUCTURE_STARTS, ChunkStatus.STRUCTURE_STARTS); +- private static final IntList r = (IntList) SystemUtils.a((Object) (new IntArrayList(a().size())), (intarraylist) -> { ++ private static final IntList r = (IntList) SystemUtils.a((new IntArrayList(a().size())), (java.util.function.Consumer) (intarraylist) -> { // CraftBukkit - decompile error + int i = 0; + + for (int j = a().size() - 1; j >= 0; --j) { diff --git a/nms-patches/WorldServer.patch b/nms-patches/WorldServer.patch index 825e5083f1..19c80dadb6 100644 --- a/nms-patches/WorldServer.patch +++ b/nms-patches/WorldServer.patch @@ -499,6 +499,15 @@ ++j; } } +@@ -1074,7 +1274,7 @@ + + @Nullable + public BlockPosition a(StructureGenerator structuregenerator, BlockPosition blockposition, int i, boolean flag) { +- return !this.server.getSaveData().getGeneratorSettings().shouldGenerateMapFeatures() ? null : this.getChunkProvider().getChunkGenerator().findNearestMapFeature(this, structuregenerator, blockposition, i, flag); ++ return !this.worldDataServer.getGeneratorSettings().shouldGenerateMapFeatures() ? null : this.getChunkProvider().getChunkGenerator().findNearestMapFeature(this, structuregenerator, blockposition, i, flag); // CraftBukkit + } + + @Nullable @@ -1105,7 +1305,13 @@ @Override public WorldMap a(String s) {