If players all had died, I want to stop running minigame. How can I embody it? I think it should be yaml. isn't it?
Store who join the game in arena data. Remove player from arena data when death. Check if all player die with task.
Why would you need a task for that? You could just check if there are no remaining players when someone dies.
Speak english properly please, there's no need to store players in a .yaml you could just save them into an array for each match
you can also check the players of a world this is an example for you: PHP: public function onDeath(PlayerDeathEvent $ev){ if ($ev->getPlayer()->getLevel()->getName() == "your world name"){ $players = $this->getServer()->getLevelByName("your world name")->getPlayers(); if (count($players) === 0){ //no alive player in this level... } } }