diff --git a/src/main/java/net/minestom/server/instance/DynamicChunk.java b/src/main/java/net/minestom/server/instance/DynamicChunk.java index 218554b80..66044667f 100644 --- a/src/main/java/net/minestom/server/instance/DynamicChunk.java +++ b/src/main/java/net/minestom/server/instance/DynamicChunk.java @@ -19,6 +19,8 @@ import java.util.concurrent.CopyOnWriteArraySet; public class DynamicChunk extends Chunk { // blocks id based on coordinate, see Chunk#getBlockIndex + // WARNING: those arrays are NOT thread-safe + // and modifying them can cause issue with block data, update, block entity and the cached chunk packet protected final short[] blocksStateId = new short[CHUNK_SIZE_X * CHUNK_SIZE_Y * CHUNK_SIZE_Z]; protected final short[] customBlocksId = new short[CHUNK_SIZE_X * CHUNK_SIZE_Y * CHUNK_SIZE_Z];