Sniffer 5.46.0
Extends Animal
Bedrock values (entities/sniffer.json): 14 health, 1.9x1.75, movement 0.09, babies (snifflets) scale 0.45 and grow up in 40 minutes. Tempted (1.25x), bred and healed (2) with torchflower seeds; breeding makes it pregnant and it lays a sniffer egg next to it. Every 8 minutes (Java dig cooldown) a sniffer standing on dirt, grass, podzol, moss or mud digs for 6 seconds (DIGGING) and drops a torchflower seed or a pitcher pod. No loot; XP 1-3.
Constants
SNIFFLET_AGE
php
public const SNIFFLET_AGE = -48000TAG_DIG_COOLDOWN
php
public const TAG_DIG_COOLDOWN = "DigCooldown"TAG_PREGNANT
php
public const TAG_PREGNANT = "IsPregnant"Methods
canDig()
php
public function canDig() : boolcreateBaby() protected
php
protected function createBaby(\pocketmine\entity\animal\Animal $partner, \pocketmine\entity\Location $location) : \pocketmine\entity\animal\AnimalentityBaseTick() protected
php
protected function entityBaseTick(int $tickDiff = 1) : boolgetBabyScale() protected
php
protected function getBabyScale() : floatgetFeedGrowth() protected
php
protected function getFeedGrowth(\pocketmine\item\Item $item) : intgetInitialSizeInfo() protected
php
protected function getInitialSizeInfo() : \pocketmine\entity\EntitySizeInfogetName()
php
public function getName() : stringgetNetworkTypeId()
php
public static function getNetworkTypeId() : stringinitEntity() protected
php
protected function initEntity(\pocketmine\nbt\tag\CompoundTag $nbt) : voidisBreedingItem()
php
public function isBreedingItem(\pocketmine\item\Item $item) : boolisDigging()
php
public function isDigging() : boolisPregnant()
php
public function isPregnant() : boolonInteractWithItem() protected
php
protected function onInteractWithItem(\pocketmine\player\Player $player, \pocketmine\item\Item $item) : boolregisterGoals() protected
php
protected function registerGoals() : voidsaveNBT()
php
public function saveNBT() : \pocketmine\nbt\tag\CompoundTagsetPregnant()
php
public function setPregnant(bool $pregnant) : voidspawnBaby() protected
php
protected function spawnBaby(\pocketmine\entity\animal\Animal $partner) : ?\pocketmine\entity\animal\AnimalstartDigging()
php
public function startDigging() : voidsyncNetworkData() protected
php
protected function syncNetworkData(\pocketmine\network\mcpe\protocol\types\entity\EntityMetadataCollection $properties) : void