diff --git a/Plugins/Mineplex.Core/src/mineplex/core/game/GameDisplay.java b/Plugins/Mineplex.Core/src/mineplex/core/game/GameDisplay.java index 91c3ae291..e921acff9 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/game/GameDisplay.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/game/GameDisplay.java @@ -41,8 +41,8 @@ public enum GameDisplay Sheep("Sheep Quest", Material.WOOL, (byte)4, GameCategory.ARCADE, 33), Smash("Super Smash Mobs", Material.SKULL_ITEM, (byte)4, GameCategory.CLASSICS, 34), - SmashDomination("Super Smash Mobs Domination", "Super Smash Mobs", Material.SKULL_ITEM, (byte)4, GameCategory.EXTRA, 36), - SmashTeams("Super Smash Mobs Teams", "Super Smash Mobs", Material.SKULL_ITEM, (byte)4, GameCategory.TEAM_VARIANT, 35), + SmashDomination("Super Smash Mobs", Material.SKULL_ITEM, (byte)4, GameCategory.EXTRA, 36), + SmashTeams("Super Smash Mobs", Material.SKULL_ITEM, (byte)4, GameCategory.TEAM_VARIANT, 35), Snake("Snake", Material.WOOL, (byte)0, GameCategory.ARCADE, 37), SneakyAssassins("Sneaky Assassins", Material.INK_SACK, (byte)0, GameCategory.ARCADE, 38), SnowFight("Snow Fight", Material.SNOW_BALL, (byte)0, GameCategory.EXTRA, 39), @@ -61,8 +61,8 @@ public enum GameDisplay Build("Master Builders", Material.WOOD, (byte)0, GameCategory.CLASSICS, 50), Cards("Craft Against Humanity", Material.MAP, (byte)0, GameCategory.CLASSICS, 51), - Skywars("Skywars", "Skywars", Material.FEATHER, (byte) 0, GameCategory.SURVIVAL, 52), - SkywarsTeams("Skywars Teams", "Skywars",Material.FEATHER, (byte)5, GameCategory.TEAM_VARIANT, 53), + Skywars("Skywars", Material.FEATHER, (byte) 0, GameCategory.SURVIVAL, 52), + SkywarsTeams("Skywars", Material.FEATHER, (byte)5, GameCategory.TEAM_VARIANT, 53), Event("Mineplex Event", Material.CAKE, (byte)0, GameCategory.EVENT, 999); diff --git a/Plugins/Mineplex.Hub/src/mineplex/hub/server/ServerManager.java b/Plugins/Mineplex.Hub/src/mineplex/hub/server/ServerManager.java index 909827f6e..e2c11d1c5 100644 --- a/Plugins/Mineplex.Hub/src/mineplex/hub/server/ServerManager.java +++ b/Plugins/Mineplex.Hub/src/mineplex/hub/server/ServerManager.java @@ -598,7 +598,7 @@ public class ServerManager extends MiniPlugin { ServerInfo largestServer = servers.get(0); - if (largestServer.getAvailableSlots() >= MIN_SLOTS_REQUIRED) + if (largestServer.getAvailableSlots() >= MIN_SLOTS_REQUIRED || largestServer.MaxPlayers > 40) { return largestServer; } @@ -618,6 +618,9 @@ public class ServerManager extends MiniPlugin for (ServerInfo server : servers) { + if (isInProgress(server)) + continue; + if (results.size() >= count) break; if (server.getAvailableSlots() > requiredSlots) @@ -628,6 +631,11 @@ public class ServerManager extends MiniPlugin return results; } + + private boolean isInProgress(ServerInfo serverInfo) + { + return serverInfo.MOTD.contains("Progress") || serverInfo.MOTD.contains("Restarting"); + } public void ListServerNpcs(Player caller) { @@ -680,13 +688,13 @@ public class ServerManager extends MiniPlugin { for (ServerGroup serverGroup : mineplex.serverdata.servers.ServerManager.getServerRepository(region).getServerGroups(null)) { + addServerGroup(serverGroup); + System.out.println("Adding servergroup : " + serverGroup.getName() + " prefix:" + serverGroup.getPrefix()); + if (!serverGroup.getServerNpcName().isEmpty()) { - if (!HasServerNpc(serverGroup.getServerNpcName())) - { - AddServerNpc(serverGroup); - addServerGroup(serverGroup); - } + AddServerNpc(serverGroup); + System.out.println("Adding to npcs"); } if (!serverGroup.getPortalBottomCornerLocation().isEmpty() && !serverGroup.getPortalTopCornerLocation().isEmpty()) @@ -805,7 +813,7 @@ public class ServerManager extends MiniPlugin public ServerNpcShop getSKYShop() { - return _serverNpcShopMap.get("SkyWars"); + return _serverNpcShopMap.get("Skywars"); } public ServerNpcShop getPlayerGamesShop() diff --git a/Plugins/Mineplex.Hub/src/mineplex/hub/server/ui/ServerGameMenu.java b/Plugins/Mineplex.Hub/src/mineplex/hub/server/ui/ServerGameMenu.java index f63540cbf..31a9851d0 100644 --- a/Plugins/Mineplex.Hub/src/mineplex/hub/server/ui/ServerGameMenu.java +++ b/Plugins/Mineplex.Hub/src/mineplex/hub/server/ui/ServerGameMenu.java @@ -64,7 +64,7 @@ public class ServerGameMenu extends ShopPageBase ChatColor.RESET + "Join " + ChatColor.GREEN + getPlugin().getGroupTagPlayerCount("BR") + ChatColor.RESET + " other players!", })); - setItem(2, ItemStackFactory.Instance.CreateStack(Material.IRON_SWORD.getId(), (byte)0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Survival Games " + C.cGray + "Last Man Standing", new String[] + setItem(2, ItemStackFactory.Instance.CreateStack(Material.IRON_SWORD.getId(), (byte)0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Survival Games " + C.cGray + "Solo/Team Survival", new String[] { ChatColor.RESET + "", ChatColor.RESET + "Search for chests to find loot and ", @@ -74,7 +74,7 @@ public class ServerGameMenu extends ShopPageBase ChatColor.RESET + "Join " + ChatColor.GREEN + getPlugin().getGroupTagPlayerCount("HG") + ChatColor.RESET + " other players!", })); - setItem(4, ItemStackFactory.Instance.CreateStack(Material.FEATHER.getId(), (byte) 0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Skywars " + C.cGray + "Solo Survival", new String[] + setItem(4, ItemStackFactory.Instance.CreateStack(Material.FEATHER.getId(), (byte) 0, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Skywars " + C.cGray + "Solo/Team Survival", new String[] { ChatColor.RESET + "", ChatColor.RESET + "16 contenders fight for the right to rule the skies!", @@ -456,7 +456,7 @@ public class ServerGameMenu extends ShopPageBase ChatColor.RESET + "Join " + ChatColor.GREEN + getPlugin().getGroupTagPlayerCount("SSM") + ChatColor.RESET + " other players!", }; - _superSmashCycle.add(ItemStackFactory.Instance.CreateStack(397, (byte)4, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Super Smash Mobs", desc)); + _superSmashCycle.add(ItemStackFactory.Instance.CreateStack(397, (byte)4, 1, ChatColor.RESET + C.Bold + ChatColor.YELLOW + "Super Smash Mobs " + C.cGray + "Solo/Team Deathmatch", desc)); } public void Update() diff --git a/Plugins/Mineplex.Hub/src/mineplex/hub/server/ui/ServerNpcPage.java b/Plugins/Mineplex.Hub/src/mineplex/hub/server/ui/ServerNpcPage.java index d484f1cbc..fe38ea991 100644 --- a/Plugins/Mineplex.Hub/src/mineplex/hub/server/ui/ServerNpcPage.java +++ b/Plugins/Mineplex.Hub/src/mineplex/hub/server/ui/ServerNpcPage.java @@ -42,7 +42,7 @@ public class ServerNpcPage extends ShopPageBase im public ServerNpcPage(ServerManager plugin, ServerNpcShop shop, CoreClientManager clientManager, DonationManager donationManager, String name, Player player, String serverNpcKey) { - super(plugin, shop, clientManager, donationManager, name, player, 27); + super(plugin, shop, clientManager, donationManager, name, player, 54); _serverNpcKey = serverNpcKey; diff --git a/Plugins/Mineplex.Hub/src/mineplex/hub/server/ui/ServerTypePage.java b/Plugins/Mineplex.Hub/src/mineplex/hub/server/ui/ServerTypePage.java index 1c070d71d..5eb10705b 100644 --- a/Plugins/Mineplex.Hub/src/mineplex/hub/server/ui/ServerTypePage.java +++ b/Plugins/Mineplex.Hub/src/mineplex/hub/server/ui/ServerTypePage.java @@ -50,15 +50,17 @@ public class ServerTypePage extends ShopPageBase { String name = _serverGroup.getName(); - setItem(12, ItemStackFactory.Instance.CreateStack(Material.SKULL_ITEM.getId(), (byte)3, 1, ChatColor.RESET + C.cYellow + "Solo " + C.cGray + name, new String[] + String friendlyName = _serverGroup.getServerNpcName(); + + setItem(12, ItemStackFactory.Instance.CreateStack(Material.SKULL_ITEM.getId(), (byte)3, 1, ChatColor.RESET + C.cYellow + "Solo " + friendlyName, new String[] { ChatColor.RESET + "", - ChatColor.RESET + C.cRed + C.Bold + "WARNING:" + ChatColor.RESET + "Teaming in Solo Mode is bannable!", + ChatColor.RESET + C.cRed + C.Bold + "WARNING: " + ChatColor.RESET + "Teaming in Solo Mode is bannable!", ChatColor.RESET + "", ChatColor.RESET + C.cGreen + "Click to Play", })); - setItem(14, ItemStackFactory.Instance.CreateStack(Material.SKULL_ITEM.getId(), (byte)3, 2, ChatColor.RESET + C.cYellow + "Team " + name, new String[] + setItem(14, ItemStackFactory.Instance.CreateStack(Material.SKULL_ITEM.getId(), (byte)3, 2, ChatColor.RESET + C.cYellow + "Team " + friendlyName, new String[] { ChatColor.RESET + "", ChatColor.RESET + C.cGray + "2 Player Teams", diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/quiver/kits/KitNinja.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/quiver/kits/KitNinja.java index 21636cee3..106360d21 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/quiver/kits/KitNinja.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/quiver/kits/KitNinja.java @@ -1,5 +1,6 @@ package nautilus.game.arcade.game.games.quiver.kits; +import mineplex.core.achievement.Achievement; import mineplex.core.common.util.F; import mineplex.core.common.util.UtilInv; import mineplex.core.common.util.UtilServer; @@ -27,6 +28,13 @@ public class KitNinja extends Kit { new PerkVanishing() }, EntityType.ZOMBIE, new ItemBuilder(Material.GOLD_SWORD).build()); + + this.setAchievementRequirements(new Achievement[] + { + Achievement.OITQ_SHARPSHOOTER, + Achievement.OITQ_WHATS_A_BOW, + Achievement.OITQ_WINS, + }); } @Override diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/quiver/kits/KitSlamShot.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/quiver/kits/KitSlamShot.java index 543a7c58b..b248eb2d7 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/quiver/kits/KitSlamShot.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/quiver/kits/KitSlamShot.java @@ -33,14 +33,6 @@ public class KitSlamShot extends Kit }, EntityType.ZOMBIE, new ItemStack(Material.DIAMOND_SPADE)); - - this.setAchievementRequirements(new Achievement[] - { - Achievement.OITQ_PERFECTIONIST, - Achievement.OITQ_SHARPSHOOTER, - Achievement.OITQ_WHATS_A_BOW, - Achievement.OITQ_WINS, - }); } @Override diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/GameHostManager.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/GameHostManager.java index fab9c7138..96a719071 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/GameHostManager.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/managers/GameHostManager.java @@ -391,7 +391,7 @@ public class GameHostManager implements Listener } msg = msg.trim(); - Bukkit.broadcastMessage("�6�l" + event.getPlayer().getName() + " �e" + msg); + Bukkit.broadcastMessage(C.cDGreen + C.Bold + event.getPlayer().getName() + " " + C.cGreen + msg); } @EventHandler