47 if(count($args) >= 2){
51 $player = $this->fetchPermittedPlayerTarget($sender, $args[0] ??
null, DefaultPermissionNames::COMMAND_KILL_SELF, DefaultPermissionNames::COMMAND_KILL_OTHER);
56 $player->attack(
new EntityDamageEvent($player, EntityDamageEvent::CAUSE_SUICIDE, $player->getHealth()));
57 if($player === $sender){
58 $sender->sendMessage(KnownTranslationFactory::commands_kill_successful($sender->getName()));
60 Command::broadcastCommandMessage($sender, KnownTranslationFactory::commands_kill_successful($player->getName()));