code: PHP: public function Entity(PlayerJoinEvent $event){ $player = $event->getPlayer(); $pk = new AddEntityPacket(); $pk->type = 56; $pk->eid = Entity::$entityCount++; $pk->speedX = 0; $pk->speedY = 0; $pk->speedZ = 0; $pk->yaw = 0; $pk->pitch = 0; $pk->metadata = array(); $pk->x = $this->data['x']; $pk->y = $this->data['y']; $pk->z = $this->data['z']; $player->dataPacket($pk); $player->getLevel()->addParticle(new FloatingTextParticle(new Vector3($this->data['x'], $this->data['y'], $this->data['z']), '', $this->data['text'], array($player))); } My code doesnt work fine I forgot an argument but which one?
Replace $pk->eid with $pk->entityRuntimeId; And argument you are missing is $pk->position. Also there's no longer $pk->speedX,Y.Z in AddEntityPacket. Take a look at here: https://github.com/pmmp/PocketMine-...ine/network/mcpe/protocol/AddEntityPacket.php Next time please take a look into source before asking here