mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-07 18:32:55 +00:00
Added entity id names
This commit is contained in:
@ -23,6 +23,7 @@ namespace pocketmine\entity;
|
||||
|
||||
|
||||
use pocketmine\nbt\tag\Int;
|
||||
use pocketmine\nbt\tag\String;
|
||||
use pocketmine\network\protocol\AddMobPacket;
|
||||
use pocketmine\network\protocol\SetEntityMotionPacket;
|
||||
use pocketmine\Player;
|
||||
@ -47,6 +48,7 @@ class Villager extends Creature implements NPC, Ageable{
|
||||
|
||||
protected function initEntity(){
|
||||
parent::initEntity();
|
||||
$this->namedtag->id = new String("id", "Villager");
|
||||
if(!isset($this->namedtag->Profession)){
|
||||
$this->setProfession(self::PROFESSION_GENERIC);
|
||||
}
|
||||
|
Reference in New Issue
Block a user