getChunk

abstract fun getChunk(x: Int, z: Int): Chunk?

Gets a chunk from its chunk coordinates, or returns null if there is no chunk loaded at the given coordinates.

That is, to calculate the chunk coordinate from a given block coordinate, the block coordinate is shifted right by 4 (divided by 16 and floored).

Return

the chunk at the given coordinates, or null if there isn't one loaded

Parameters

x

the chunk X coordinate

z

the chunk Z coordinate