mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-07 10:22:56 +00:00
Nuke block extradata
this has been superseded by multi-layer blockstorages in 1.2.14+
This commit is contained in:
@ -846,25 +846,6 @@ class Level implements ChunkManager, Metadatable{
|
||||
$this->sleepTicks = $ticks;
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated
|
||||
*
|
||||
* @param int $x
|
||||
* @param int $y
|
||||
* @param int $z
|
||||
* @param int $id
|
||||
* @param int $data
|
||||
* @param Player[]|null $targets
|
||||
*/
|
||||
public function sendBlockExtraData(int $x, int $y, int $z, int $id, int $data, array $targets = null){
|
||||
$pk = new LevelEventPacket;
|
||||
$pk->evid = LevelEventPacket::EVENT_SET_DATA;
|
||||
$pk->position = new Vector3($x, $y, $z);
|
||||
$pk->data = ($data << 8) | $id;
|
||||
|
||||
$this->server->broadcastPacket($targets ?? $this->getChunkPlayers($x >> 4, $z >> 4), $pk);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param Player[] $target
|
||||
* @param Block[] $blocks
|
||||
@ -2136,37 +2117,6 @@ class Level implements ChunkManager, Metadatable{
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated This functionality no longer produces any effect and will be removed in a future release
|
||||
*
|
||||
* Gets the raw block extra data
|
||||
*
|
||||
* @param int $x
|
||||
* @param int $y
|
||||
* @param int $z
|
||||
*
|
||||
* @return int 16-bit
|
||||
*/
|
||||
public function getBlockExtraDataAt(int $x, int $y, int $z) : int{
|
||||
return $this->getChunk($x >> 4, $z >> 4, true)->getBlockExtraData($x & 0x0f, $y, $z & 0x0f);
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated This functionality no longer produces any effect and will be removed in a future release
|
||||
* Sets the raw block metadata.
|
||||
*
|
||||
* @param int $x
|
||||
* @param int $y
|
||||
* @param int $z
|
||||
* @param int $id
|
||||
* @param int $data
|
||||
*/
|
||||
public function setBlockExtraDataAt(int $x, int $y, int $z, int $id, int $data){
|
||||
$this->getChunk($x >> 4, $z >> 4, true)->setBlockExtraData($x & 0x0f, $y, $z & 0x0f, ($data << 8) | $id);
|
||||
|
||||
$this->sendBlockExtraData($x, $y, $z, $id, $data);
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the raw block metadata
|
||||
*
|
||||
|
Reference in New Issue
Block a user