mirror of
https://github.com/Minestom/Minestom.git
synced 2024-12-30 21:17:53 +01:00
Synchronize chunk packet creation
Signed-off-by: TheMode <themode@outlook.fr>
This commit is contained in:
parent
380f5a5a67
commit
5376b8af76
@ -164,7 +164,7 @@ public class DynamicChunk extends Chunk {
|
|||||||
this.entries.clear();
|
this.entries.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
private @NotNull ChunkDataPacket createChunkPacket() {
|
private synchronized @NotNull ChunkDataPacket createChunkPacket() {
|
||||||
ChunkDataPacket packet = new ChunkDataPacket();
|
ChunkDataPacket packet = new ChunkDataPacket();
|
||||||
packet.biomes = biomes;
|
packet.biomes = biomes;
|
||||||
packet.chunkX = chunkX;
|
packet.chunkX = chunkX;
|
||||||
@ -174,7 +174,7 @@ public class DynamicChunk extends Chunk {
|
|||||||
return packet;
|
return packet;
|
||||||
}
|
}
|
||||||
|
|
||||||
private @NotNull UpdateLightPacket createLightPacket() {
|
private synchronized @NotNull UpdateLightPacket createLightPacket() {
|
||||||
long skyMask = 0;
|
long skyMask = 0;
|
||||||
long blockMask = 0;
|
long blockMask = 0;
|
||||||
List<byte[]> skyLights = new ArrayList<>();
|
List<byte[]> skyLights = new ArrayList<>();
|
||||||
|
Loading…
Reference in New Issue
Block a user