Changed the enum for Leader to actually be leader and not admin.
This commit is contained in:
@@ -47,7 +47,7 @@ public class CmdKick extends FCommand {
|
||||
String s = player.getName();
|
||||
msg.then(s + " ").color(ChatColor.GRAY).tooltip(TL.COMMAND_KICK_CLICKTOKICK.toString() + s).command("/" + Conf.baseCommandAliases.get(0) + " kick " + s);
|
||||
}
|
||||
if (fme.getRole() == Role.ADMIN) {
|
||||
if (fme.getRole() == Role.LEADER) {
|
||||
// Only add coleader to this for the leader.
|
||||
for (FPlayer player : myFaction.getFPlayersWhereRole(Role.COLEADER)) {
|
||||
String s = player.getName();
|
||||
@@ -80,7 +80,7 @@ public class CmdKick extends FCommand {
|
||||
// - Make sure the kicked player has lower rank than the kicker.
|
||||
if (!fme.isAdminBypassing()) {
|
||||
Access access = myFaction.getAccess(fme, PermissableAction.KICK);
|
||||
if (access != Access.ALLOW && fme.getRole() != Role.ADMIN) {
|
||||
if (access != Access.ALLOW && fme.getRole() != Role.LEADER) {
|
||||
fme.msg(TL.GENERIC_NOPERMISSION, "kick");
|
||||
return;
|
||||
}
|
||||
@@ -124,7 +124,7 @@ public class CmdKick extends FCommand {
|
||||
if (Conf.logFactionKick) {
|
||||
P.p.log((senderIsConsole ? "A console command" : fme.getName()) + " kicked " + toKick.getName() + " from the faction: " + toKickFaction.getTag());
|
||||
}
|
||||
if (toKick.getRole() == Role.ADMIN) {
|
||||
if (toKick.getRole() == Role.LEADER) {
|
||||
toKickFaction.promoteNewLeader();
|
||||
}
|
||||
toKickFaction.deinvite(toKick);
|
||||
|
||||
Reference in New Issue
Block a user