mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-08 02:42:58 +00:00
Added Block->getVariantBitmask(0 to cut down on getDrops() boilerplate, fixed several blocks incorrectly retaining meta when broken
This commit is contained in:
@ -40,9 +40,14 @@ class WoodenStairs extends Stair{
|
||||
return Tool::TYPE_AXE;
|
||||
}
|
||||
|
||||
public function getVariantBitmask() : int{
|
||||
return 0;
|
||||
}
|
||||
|
||||
public function getDrops(Item $item) : array{
|
||||
//TODO: Hierarchy problem (base class is for stone stairs)
|
||||
return [
|
||||
Item::get($this->getItemId(), 0, 1)
|
||||
Item::get($this->getItemId(), $this->getDamage() & $this->getVariantBitmask(), 1)
|
||||
];
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user