mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-04-22 08:44:01 +00:00
Fixed missing variant bitmask for Leaves, close #1478
This commit is contained in:
parent
7b04049bb7
commit
ba3fe20227
@ -169,10 +169,14 @@ class Leaves extends Transparent{
|
||||
return $this->getLevel()->setBlock($this, $this, true);
|
||||
}
|
||||
|
||||
public function getVariantBitmask() : int{
|
||||
return 0x03;
|
||||
}
|
||||
|
||||
public function getDrops(Item $item) : array{
|
||||
$drops = [];
|
||||
|
||||
$variantMeta = $this->getDamage() & 0x03;
|
||||
$variantMeta = $this->getVariant();
|
||||
|
||||
if($item->isShears()){
|
||||
$drops[] = ItemFactory::get($this->getItemId(), $variantMeta, 1);
|
||||
|
Loading…
x
Reference in New Issue
Block a user