Final tidying up

This commit is contained in:
AlexTheCoder 2017-09-23 06:11:03 -04:00
parent 1e2dce46ad
commit e4da5e5592
5 changed files with 23 additions and 7 deletions

View File

@ -19,7 +19,7 @@ public class UnpauseQueueCommand extends ConsoleCommand
{
if (arguments.length < 1)
{
addOutput("Usage: pause <Server>");
addOutput("Usage: unpause <Server>");
sendOutput();
return;
}

View File

@ -14,19 +14,25 @@ import org.bukkit.event.player.PlayerQuitEvent;
import mineplex.core.MiniPlugin;
import mineplex.core.ReflectivelyCreateMiniPlugin;
import mineplex.core.account.permissions.Permission;
import mineplex.core.account.permissions.PermissionGroup;
import mineplex.core.command.CommandBase;
import mineplex.core.common.Rank;
@ReflectivelyCreateMiniPlugin
public class VisibilityManager extends MiniPlugin
{
public enum Perm implements Permission
{
VIS_DEBUG,
}
private final Map<Player, Map<Player, Set<String>>> _visibility = new HashMap<>();
private VisibilityManager()
{
super("Visibility Manager");
addCommand(new CommandBase<VisibilityManager>(this, Rank.ADMIN, "visdebug")
addCommand(new CommandBase<VisibilityManager>(this, Perm.VIS_DEBUG, "visdebug")
{
@Override
public void Execute(Player caller, String[] args)
@ -69,6 +75,14 @@ public class VisibilityManager extends MiniPlugin
}
}
});
generatePermissions();
}
private void generatePermissions()
{
PermissionGroup.ADMIN.setPermission(Perm.VIS_DEBUG, true, true);
PermissionGroup.QA.setPermission(Perm.VIS_DEBUG, true, true);
}
public boolean canSee(Player viewer, Player target)

View File

@ -147,7 +147,6 @@ public class AltManager extends MiniPlugin
if (success)
{
UtilPlayer.message(caller, F.main(getName(), "Ip successfully whitelisted!"));
new IpBanNotification(ip).publish();
}
else
{
@ -366,7 +365,7 @@ public class AltManager extends MiniPlugin
{
if (player.getAddress().getAddress().toString().substring(1).equals(notification.getIp()))
{
player.kickPlayer(C.cRedB + "Your IP has been suspended from Mineplex Clans.\n" + C.cGold + "Visit %FORUM_LINK_HERE% for more information.");
player.kickPlayer(C.cRedB + "Your IP has been suspended from Mineplex Clans.\n" + C.cGold + "Visit http://www.mineplex.com/appeals to appeal this ban.");
}
});
});

View File

@ -74,7 +74,10 @@ public class AltRepository extends RepositoryBase
executeQuery(connection, FETCH_IP_WHITELIST_INFO, resultSet ->
{
recordExists.Set(resultSet.next());
additionalAccounts.Set(resultSet.getInt("additionalAccounts"));
if (recordExists.Get())
{
additionalAccounts.Set(resultSet.getInt("additionalAccounts"));
}
}, new ColumnVarChar("ipAddress", ipAddress.length(), ipAddress));
resultMap.put(WHITELIST_STATUS_KEY, recordExists.Get());

View File

@ -101,7 +101,7 @@ public class UndeadCity extends WorldEvent
int active = 0;
for (CityChest chest : _chests.values())
{
if (chest.isEnabled() && chest.isOpen())
if (chest.isEnabled() && !chest.isOpen())
{
active++;
}