Can you imagine indexing the array if you had dynamic chunk height AND a joined array?
m_BlockData[XZSliceSize * ChunkHeight + XZSliceNibbleSize * ChunkHeight + XZSliceNibbleSize * ChunkHeight + IndexToSkyLight]
There, finished. It's a bit cleaner now. And finally loaders and generators may pass heightmap of the new chunk, instad of having to recalculate it
m_BlockData[XZSliceSize * ChunkHeight + XZSliceNibbleSize * ChunkHeight + XZSliceNibbleSize * ChunkHeight + IndexToSkyLight]
There, finished. It's a bit cleaner now. And finally loaders and generators may pass heightmap of the new chunk, instad of having to recalculate it