mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-09 11:16:57 +00:00
Block: Clean up internal constructor inconsistencies
I don't dare look how big this commit is or how many bugs it introduced...
This commit is contained in:
@ -32,20 +32,16 @@ use pocketmine\Player;
|
||||
use pocketmine\tile\Furnace as TileFurnace;
|
||||
|
||||
class Furnace extends Solid{
|
||||
|
||||
protected $itemId = self::FURNACE;
|
||||
/** @var BlockIdentifierFlattened */
|
||||
protected $idInfo;
|
||||
|
||||
/** @var int */
|
||||
protected $facing = Facing::NORTH;
|
||||
/** @var bool */
|
||||
protected $lit = false; //this is set based on the blockID
|
||||
|
||||
public function __construct(){
|
||||
|
||||
}
|
||||
|
||||
public function getId() : int{
|
||||
return $this->lit ? Block::BURNING_FURNACE : Block::FURNACE;
|
||||
return $this->lit ? $this->idInfo->getSecondId() : parent::getId();
|
||||
}
|
||||
|
||||
protected function writeStateToMeta() : int{
|
||||
@ -60,14 +56,6 @@ class Furnace extends Solid{
|
||||
return 0b111;
|
||||
}
|
||||
|
||||
protected function getTileClass() : ?string{
|
||||
return TileFurnace::class;
|
||||
}
|
||||
|
||||
public function getName() : string{
|
||||
return "Furnace";
|
||||
}
|
||||
|
||||
public function getHardness() : float{
|
||||
return 3.5;
|
||||
}
|
||||
|
Reference in New Issue
Block a user