mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-06 09:56:06 +00:00
Added HeightMap get/set methods on chunks, Level
This commit is contained in:
@ -1634,6 +1634,16 @@ class Level implements ChunkManager, Metadatable{
|
||||
return $this->getChunk($x >> 4, $z >> 4, true)->getBiomeColor($x & 0x0f, $z & 0x0f);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $x
|
||||
* @param int $z
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getHeightMap($x, $z){
|
||||
return $this->getChunk($x >> 4, $z >> 4, true)->getHeightMap($x & 0x0f, $z & 0x0f);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $x
|
||||
* @param int $z
|
||||
@ -1654,6 +1664,15 @@ class Level implements ChunkManager, Metadatable{
|
||||
$this->getChunk($x >> 4, $z >> 4, true)->setBiomeColor($x & 0x0f, $z & 0x0f, $R, $G, $B);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $x
|
||||
* @param int $z
|
||||
* @param int $value
|
||||
*/
|
||||
public function setHeightMap($x, $z, $value){
|
||||
$this->getChunk($x >> 4, $z >> 4, true)->setHeightMap($x & 0x0f, $z & 0x0f, $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the Chunk object
|
||||
*
|
||||
|
Reference in New Issue
Block a user