Question: How would I be able to detect when a server is shutting down, and transfer all players to a different server?
PHP: public function onDisable(){ foreach($this->getServer()->getOnlinePlayers() as $p){ $p->transfer("ip", "port", "message?"); } } will this work to transfer all players?
PHP: public function onDisable(){ foreach($this->getServer()->getOnlinePlayers() as $p){ if($this->getServer()->isRunning() == false){ $p->transfer($ip, $port, $message); } } }