Skip to content

EatGrassGoal 5.46.0 ​

class · pocketmine\entity\ai\goal\EatGrassGoal · source

Extends Goal

Sheep eat the grass they stand on (vanilla behavior.eat_block): short grass becomes air, a grass block becomes dirt. Eating regrows their wool and makes babies grow faster.

Properties ​

$sheep ​

php
public \pocketmine\entity\animal\Sheep $sheep

Methods ​

__construct() ​

php
public function __construct(\pocketmine\entity\animal\Sheep $sheep)

canContinue() ​

php
public function canContinue() : bool

canStart() ​

php
public function canStart() : bool

getFlags() ​

php
public function getFlags() : int

start() ​

php
public function start() : void

stop() ​

php
public function stop() : void

tick() ​

php
public function tick() : void

VanillaMine is a fork of PocketMine-MP, maintained by Luxury Nodes. Not affiliated with the PMMP team or Mojang.