Creates a new block storage.
Optional
palette: number[]The optional palette.
Optional
blocks: number[]The optional blocks.
Optional
size: [number, number, number]The size of the block storage.
Readonly
airThe air value of the storage.
Readonly
blocksThe blocks of the storage.
Readonly
paletteThe palette of the storage.
Readonly
sizeThe size of the block storage.
Static
Readonly
MAX_The total maximum chunk size.
Static
Readonly
MAX_The maximum chunk size in the x direction.
Static
Readonly
MAX_The maximum chunk size in the y direction.
Static
Readonly
MAX_The maximum chunk size in the z direction.
Calculates the index of the block position.
The x coordinate of the block.
The y coordinate of the block.
The z coordinate of the block.
The index of the block.
Gets the block state at the given coordinates.
The x coordinate of the block.
The y coordinate of the block.
The z coordinate of the block.
The block state.
Checks if the block storage is empty.
Sets the block state at the given coordinates.
The x coordinate of the block.
The y coordinate of the block.
The z coordinate of the block.
The block state.
Static
deserializeDeserializes the block storage from a binary stream.
The binary stream to read from.
The block storage.
Static
serializeSerializes the block storage to a binary stream.
The binary stream to write to.
Represents a block storage.