mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-21 03:59:43 +00:00
added some new mobs
This commit is contained in:
parent
5fdf1f6b75
commit
d5d634b6fb
9 changed files with 111 additions and 1 deletions
31
src/entity/animal/Wolf.php
Normal file
31
src/entity/animal/Wolf.php
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
<?php
|
||||
|
||||
class Wolf extends Animal implements Tameable
|
||||
{
|
||||
const TYPE = MOB_WOLF;
|
||||
public function __construct(Level $level, $eid, $class, $type = 0, $data = []){
|
||||
$this->setSize(0.6, 0.8);
|
||||
parent::__construct($level, $eid, $class, $type, $data);
|
||||
$this->setSpeed(0.3);
|
||||
$this->setName("Wolf");
|
||||
$this->setHealth(isset($this->data["Health"]) ? $this->data["Health"] : 10, "generic");
|
||||
}
|
||||
|
||||
|
||||
public function isTamed()
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
public function getOwner()
|
||||
{
|
||||
return null;
|
||||
}
|
||||
public function isFood($id) //TODO
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue