SitOnBlockGoal 5.46.0
Extends Goal
Tamed cats like to sit on chests, lit furnaces and the foot of beds (vanilla behavior.ocelot_sit_on_block, Java CatSitOnBlockGoal): every 10-20 seconds a cat which isn't ordered to sit looks for one within 8 blocks (1 up or down) with nothing on top, walks there, hops on and sits for up to a minute. Players can't open a chest a cat sits on.
Constants
MAX_TICKS
php
public const MAX_TICKS = 1200Longest time the goal runs (walking there and sitting).
SEARCH_HEIGHT
php
public const SEARCH_HEIGHT = 1SEARCH_RANGE
php
public const SEARCH_RANGE = 8SPEED
php
public const SPEED = 1.0Properties
$cat
php
public \pocketmine\entity\animal\Cat $catMethods
__construct()
php
public function __construct(\pocketmine\entity\animal\Cat $cat)canContinue()
php
public function canContinue() : boolcanStart()
php
public function canStart() : boolgetFlags()
php
public function getFlags() : intstart()
php
public function start() : voidstop()
php
public function stop() : voidtick()
php
public function tick() : void