mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-25 10:27:55 +01:00
[Bleeding] Make sure biome data is initialized during generate - prevent uninitialized data being sent to client. Fixes BUKKIT-871
This commit is contained in:
parent
6cd2a70803
commit
09a73d352c
@ -192,6 +192,12 @@ public class ChunkProviderGenerate implements IChunkProvider {
|
||||
}
|
||||
|
||||
Chunk chunk = new Chunk(this.p, abyte, i, j);
|
||||
// CraftBukkit start - prime biome data to prevent uninitialized values racing to client
|
||||
byte[] biomes = chunk.l();
|
||||
for(int idx = 0; idx < biomes.length; idx++) {
|
||||
biomes[idx] = (byte) this.y[idx].id;
|
||||
}
|
||||
// CraftBukkit end
|
||||
|
||||
chunk.initLighting();
|
||||
return chunk;
|
||||
|
Loading…
Reference in New Issue
Block a user