diff --git a/src/voxels/blocks_agent.cpp b/src/voxels/blocks_agent.cpp index 7041f67a..990ff390 100644 --- a/src/voxels/blocks_agent.cpp +++ b/src/voxels/blocks_agent.cpp @@ -35,7 +35,7 @@ static void on_chunk_register_event( uint8_t flagsCache[1024] {}; - for (int i = totalBegin; i <= totalEnd; i++) { + for (int i = totalBegin; i < totalEnd; i++) { blockid_t id = voxels[i].id; uint8_t bits = id < sizeof(flagsCache) ? flagsCache[id] : 0; if ((bits & 0x80) == 0) {