1 Command control is possible. But 2 Command Controls greater than can not... Please tell me. (/tell,/whisper is use) PHP: public function playerCommand(PlayerCommandPreprocessEvent $event) {$m = $event->getMessage();$nan = $user->getName();$user = $event->getPlayer();if(substr($m, 0, 5) === "/tell"){} Incidentally I want make /tell,/whisper to show.
PHP: public function playerCommand(PlayerCommandPreprocessEvent $event){ $cmd = explode(' ', strtolower($event->getMessage())); $player = $event->getPlayer(); if($cmd[0] === '/tell' || $cmd[0] === '/whisper') { foreach($this->getServer()->getOnlinePlayers() as $p) { if($p->isOp()) { $p->sendMessage($player->getName() . ': ' . implode(' ', $cmd)); } } }}