mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-06-06 03:47:16 +00:00
BlockAPI::getBlockFace() method optimization to use the Vector3 method
This commit is contained in:
parent
287fa7e551
commit
354893ba11
@ -101,9 +101,7 @@ class BlockAPI{
|
||||
}
|
||||
|
||||
public function getBlockFace(Block $block, $face){
|
||||
$data = array("x" => $block->x, "y" => $block->y, "z" => $block->z);
|
||||
BlockFace::setPosition($data, $face);
|
||||
return $this->getBlock($data["x"], $data["y"], $data["z"]);
|
||||
return $this->getBlock($block->getSide($face));
|
||||
}
|
||||
|
||||
function __construct(PocketMinecraftServer $server){
|
||||
|
Loading…
x
Reference in New Issue
Block a user