Stem: fixed not attaching to grown pumpkin/melon

no idea how this got missed ...
This commit is contained in:
Dylan K. Taylor 2023-11-02 14:48:45 +00:00
parent 8aaa6dd176
commit 1e4a1565bb
No known key found for this signature in database
GPG Key ID: 8927471A91CAFD3D

View File

@ -80,7 +80,9 @@ abstract class Stem extends Crops{
$facing = Facing::HORIZONTAL[array_rand(Facing::HORIZONTAL)];
$side = $this->getSide($facing);
if($side->getTypeId() === BlockTypeIds::AIR && $side->getSide(Facing::DOWN)->hasTypeTag(BlockTypeTags::DIRT)){
BlockEventHelper::grow($side, $grow, null);
if(BlockEventHelper::grow($side, $grow, null)){
$this->position->getWorld()->setBlock($this->position, $this->setFacing($facing));
}
}
}
}