Split some block variants into their own classes where behaviour differs

This commit is contained in:
Dylan K. Taylor
2018-09-28 16:21:03 +01:00
parent e038c4295d
commit 2600cf5977
14 changed files with 200 additions and 102 deletions

View File

@ -24,11 +24,7 @@ declare(strict_types=1);
namespace pocketmine\block;
use pocketmine\block\utils\PillarRotationTrait;
use pocketmine\item\Item;
use pocketmine\item\TieredTool;
use pocketmine\math\Facing;
use pocketmine\math\Vector3;
use pocketmine\Player;
class BoneBlock extends Solid{
use PillarRotationTrait;
@ -54,9 +50,4 @@ class BoneBlock extends Solid{
public function getToolHarvestLevel() : int{
return TieredTool::TIER_WOODEN;
}
public function place(Item $item, Block $blockReplace, Block $blockClicked, int $face, Vector3 $clickVector, Player $player = null) : bool{
$this->axis = Facing::axis($face);
return parent::place($item, $blockReplace, $blockClicked, $face, $clickVector, $player);
}
}