mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-22 20:49:43 +00:00
BlockAPI::getBlockFace() method optimization to use the Vector3 method
This commit is contained in:
parent
287fa7e551
commit
354893ba11
1 changed files with 1 additions and 3 deletions
|
|
@ -101,9 +101,7 @@ class BlockAPI{
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getBlockFace(Block $block, $face){
|
public function getBlockFace(Block $block, $face){
|
||||||
$data = array("x" => $block->x, "y" => $block->y, "z" => $block->z);
|
return $this->getBlock($block->getSide($face));
|
||||||
BlockFace::setPosition($data, $face);
|
|
||||||
return $this->getBlock($data["x"], $data["y"], $data["z"]);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function __construct(PocketMinecraftServer $server){
|
function __construct(PocketMinecraftServer $server){
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue