Merge branch 'stable' into next-minor

This commit is contained in:
Dylan K. Taylor
2020-02-27 16:51:06 +00:00
29 changed files with 228 additions and 42 deletions

View File

@ -55,7 +55,7 @@ abstract class Crops extends Flowable{
$this->getLevel()->setBlock($this, $ev->getNewState(), true, true);
}
$item->count--;
$item->pop();
return true;
}

View File

@ -99,7 +99,7 @@ class Grass extends Solid{
public function onActivate(Item $item, Player $player = null) : bool{
if($item->getId() === Item::DYE and $item->getDamage() === 0x0F){
$item->count--;
$item->pop();
TallGrassObject::growGrass($this->getLevel(), $this, new Random(mt_rand()), 8, 2);
return true;

View File

@ -72,7 +72,7 @@ class Sapling extends Flowable{
//TODO: change log type
Tree::growTree($this->getLevel(), $this->x, $this->y, $this->z, new Random(mt_rand()), $this->getVariant());
$item->count--;
$item->pop();
return true;
}

View File

@ -62,7 +62,7 @@ class Sugarcane extends Flowable{
$this->getLevel()->setBlock($this, $this, true);
}
$item->count--;
$item->pop();
return true;
}