mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-08 02:42:58 +00:00
Item factory refactor and added capability to register custom items
This commit is contained in:
@ -24,6 +24,7 @@ declare(strict_types=1);
|
||||
namespace pocketmine\block;
|
||||
|
||||
use pocketmine\item\Item;
|
||||
use pocketmine\item\ItemFactory;
|
||||
use pocketmine\item\Tool;
|
||||
|
||||
class WoodenStairs extends Stair{
|
||||
@ -43,7 +44,7 @@ class WoodenStairs extends Stair{
|
||||
public function getDrops(Item $item) : array{
|
||||
//TODO: Hierarchy problem (base class is for stone stairs)
|
||||
return [
|
||||
Item::get($this->getItemId(), $this->getDamage() & $this->getVariantBitmask(), 1)
|
||||
ItemFactory::get($this->getItemId(), $this->getDamage() & $this->getVariantBitmask(), 1)
|
||||
];
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user