//regen creates vanilla decorations without error (#1650)

* fix: Feature placement on regen should create chunk

* feat: update adapter jar

* fix: update adapter jar
This commit is contained in:
Pierre Maurice Schwang 2022-03-28 21:06:26 +02:00 committed by GitHub
parent c45b14a52d
commit 2276d82d2c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 12 additions and 4 deletions

View File

@ -312,8 +312,12 @@ public class PaperweightRegen extends Regenerator<ChunkAccess, ProtoChunk, Level
) {
// redirect to LevelChunks created in #createChunks
@Override
public ChunkAccess getChunk(int x, int z, ChunkStatus chunkstatus, boolean flag) {
return getChunkAt(x, z);
public ChunkAccess getChunk(int x, int z, ChunkStatus chunkstatus, boolean create) {
ChunkAccess chunkAccess = getChunkAt(x, z);
if (chunkAccess == null && create) {
chunkAccess = createChunk(getProtoChunkAt(x, z));
}
return chunkAccess;
}
};

View File

@ -299,8 +299,12 @@ public class PaperweightRegen extends Regenerator<ChunkAccess, ProtoChunk, Level
) {
// redirect to LevelChunks created in #createChunks
@Override
public ChunkAccess getChunk(int x, int z, ChunkStatus chunkstatus, boolean flag) {
return getChunkAt(x, z);
public ChunkAccess getChunk(int x, int z, ChunkStatus chunkstatus, boolean create) {
ChunkAccess chunkAccess = getChunkAt(x, z);
if (chunkAccess == null && create) {
chunkAccess = createChunk(getProtoChunkAt(x, z));
}
return chunkAccess;
}
};