package com.massivecraft.factions.cmd; import com.massivecraft.factions.FPlayer; import com.massivecraft.factions.FPlayers; import com.massivecraft.factions.struct.Permission; public class CmdShowInvites extends FCommand { public CmdShowInvites() { super(); aliases.add("showinvites"); permission = Permission.SHOW_INVITES.node; senderMustBePlayer = true; senderMustBeMember = true; } @Override public void perform() { StringBuilder sb = new StringBuilder(); for (String id : myFaction.getInvites()) { FPlayer fp = FPlayers.i.get(id); sb.append(fp != null ? fp.getName() : id).append(" "); } msg("Players with pending invites: %s", sb.toString().trim()); } }