monsters are separated now

This commit is contained in:
GameHerobrine 2022-06-16 20:53:40 +03:00
parent 27be94ad1b
commit dbc199f34b
10 changed files with 112 additions and 79 deletions

View file

@ -0,0 +1,19 @@
<?php
class Skeleton extends Monster{
const TYPE = MOB_SKELETON;
function __construct(Level $level, $eid, $class, $type = 0, $data = array()){
parent::__construct($level, $eid, $class, $type, $data);
$this->setHealth(isset($this->data["Health"]) ? $this->data["Health"] : 20, "generic");
$this->update();
//$this->setName('Skeleton');
$this->size = 1.9;
}
public function getDrops(){
return array(
array(ARROW, 0, mt_rand(0,2)),
array(BONE, 0, mt_rand(0,2)),
);
}
}