Hotfix Tabcomplete and colors
Dieser Commit ist enthalten in:
Ursprung
c6f4ab4777
Commit
a6293e163d
@ -74,14 +74,24 @@ public class CommandInvite implements CommandExecutor, TabCompleter {
|
||||
team.invitePlayer(invitedPlayer);
|
||||
player.sendMessage("§7Du hast §e" + invitedPlayer.getName() + " §7eingeladen.");
|
||||
invitedPlayer.sendMessage("§7Du wurdest von §e" + player.getName() + "§7 in das Team §e" + MissileWars.getTeam(player).getColoredName() + "§7 eingeladen.");
|
||||
invitedPlayer.sendMessage("§8/§6accept §8- §7Zum akzeptieren.");
|
||||
invitedPlayer.sendMessage("§8/§6decline §8- §7Zum ablehnen.");
|
||||
invitedPlayer.sendMessage("§8/§eaccept §8- §7Zum akzeptieren.");
|
||||
invitedPlayer.sendMessage("§8/§edecline §8- §7Zum ablehnen.");
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> onTabComplete(CommandSender sender, Command command, String label, String[] args) {
|
||||
if (args.length != 1) return new ArrayList<>();
|
||||
if (args.length == 0) {
|
||||
return Bukkit.getOnlinePlayers()
|
||||
.stream()
|
||||
.filter(p -> MissileWars.getTeam(p) != null)
|
||||
.filter(p -> MissileWars.getInvitation(p) != null)
|
||||
.map(Player::getName)
|
||||
.collect(Collectors.toList());
|
||||
}
|
||||
if (args.length != 1) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
return Bukkit.getOnlinePlayers()
|
||||
.stream()
|
||||
.filter(p -> MissileWars.getTeam(p) != null)
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren