PocketMine-MP 5.21.2 git-a6534ecbbbcf369264567d27e5ed70f7f5be9816
|
Public Member Functions | |
__construct (private int $emptyBlockId, private array $blockLayers, private PalettedBlockArray $biomes, private ?LightArray $skyLight=null, private ?LightArray $blockLight=null) | |
__clone () | |
__debugInfo () | |
collectGarbage () | |
getBiomeArray () | |
getBlockLayers () | |
getBlockLightArray () | |
getBlockSkyLightArray () | |
getBlockStateId (int $x, int $y, int $z) | |
getEmptyBlockId () | |
getHighestBlockAt (int $x, int $z) | |
isEmptyAuthoritative () | |
isEmptyFast () | |
setBlockLightArray (LightArray $data) | |
setBlockSkyLightArray (LightArray $data) | |
setBlockStateId (int $x, int $y, int $z, int $block) | |
Public Attributes | |
const | COORD_BIT_SIZE = 4 |
const | COORD_MASK = ~(~0 << self::COORD_BIT_SIZE) |
const | EDGE_LENGTH = 1 << self::COORD_BIT_SIZE |
Definition at line 30 of file SubChunk.php.
pocketmine\world\format\SubChunk::__construct | ( | private int | $emptyBlockId, |
private array | $blockLayers, | ||
private PalettedBlockArray | $biomes, | ||
private ?LightArray | $skyLight = null, | ||
private ?LightArray | $blockLight = null ) |
SubChunk constructor.
PalettedBlockArray[] | $blockLayers |
Definition at line 40 of file SubChunk.php.
pocketmine\world\format\SubChunk::__clone | ( | ) |
Definition at line 153 of file SubChunk.php.
pocketmine\world\format\SubChunk::__debugInfo | ( | ) |
Definition at line 127 of file SubChunk.php.
pocketmine\world\format\SubChunk::collectGarbage | ( | ) |
Definition at line 131 of file SubChunk.php.
pocketmine\world\format\SubChunk::getBiomeArray | ( | ) |
Definition at line 106 of file SubChunk.php.
pocketmine\world\format\SubChunk::getBlockLayers | ( | ) |
Definition at line 89 of file SubChunk.php.
pocketmine\world\format\SubChunk::getBlockLightArray | ( | ) |
Definition at line 116 of file SubChunk.php.
pocketmine\world\format\SubChunk::getBlockSkyLightArray | ( | ) |
Definition at line 108 of file SubChunk.php.
pocketmine\world\format\SubChunk::getBlockStateId | ( | int | $x, |
int | $y, | ||
int | $z ) |
Definition at line 72 of file SubChunk.php.
pocketmine\world\format\SubChunk::getEmptyBlockId | ( | ) |
Returns the block used as the default. This is assumed to refer to air. If all the blocks in a subchunk layer are equal to this block, the layer is assumed to be empty.
Definition at line 70 of file SubChunk.php.
pocketmine\world\format\SubChunk::getHighestBlockAt | ( | int | $x, |
int | $z ) |
Definition at line 93 of file SubChunk.php.
pocketmine\world\format\SubChunk::isEmptyAuthoritative | ( | ) |
Returns whether this subchunk contains any non-air blocks. This function will do a slow check, usually by garbage collecting first. This is typically useful for disk saving.
Definition at line 53 of file SubChunk.php.
pocketmine\world\format\SubChunk::isEmptyFast | ( | ) |
Returns a non-authoritative bool to indicate whether the chunk contains any blocks. This may report non-empty erroneously if the chunk has been modified and not garbage-collected.
Definition at line 62 of file SubChunk.php.
pocketmine\world\format\SubChunk::setBlockLightArray | ( | LightArray | $data | ) |
Definition at line 120 of file SubChunk.php.
pocketmine\world\format\SubChunk::setBlockSkyLightArray | ( | LightArray | $data | ) |
Definition at line 112 of file SubChunk.php.
pocketmine\world\format\SubChunk::setBlockStateId | ( | int | $x, |
int | $y, | ||
int | $z, | ||
int | $block ) |
Definition at line 79 of file SubChunk.php.
const pocketmine\world\format\SubChunk::COORD_BIT_SIZE = 4 |
Definition at line 31 of file SubChunk.php.
const pocketmine\world\format\SubChunk::COORD_MASK = ~(~0 << self::COORD_BIT_SIZE) |
Definition at line 32 of file SubChunk.php.
const pocketmine\world\format\SubChunk::EDGE_LENGTH = 1 << self::COORD_BIT_SIZE |
Definition at line 33 of file SubChunk.php.