pocketmine\entity\Zombie::getVelY PHP Method

getVelY() private method

private getVelY ( )
    private function getVelY()
    {
        $expectedPos = (new Vector3($this->x + $this->moveDirection->x * $this->moveSpeed, $this->y + $this->motionY, $this->z + $this->moveDirection->z * $this->moveSpeed))->round();
        $block0 = $this->getLevel()->getBlock($expectedPos);
        $block1 = $this->getLevel()->getBlock($expectedPos->add(0, 1, 0));
        if ($block1->getId() != 0) {
            return 1.2;
        }
        return 0;
    }