diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/addons/CompassAddon.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/addons/CompassAddon.java index f7569f949..b28f531fe 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/addons/CompassAddon.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/addons/CompassAddon.java @@ -32,7 +32,7 @@ import nautilus.game.arcade.ArcadeManager; import nautilus.game.arcade.events.GameStateChangeEvent; import nautilus.game.arcade.game.Game; import nautilus.game.arcade.game.GameTeam; -import nautilus.game.arcade.gui.SpectatorShop; +import nautilus.game.arcade.gui.spectatorMenu.SpectatorShop; public class CompassAddon extends MiniPlugin { diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/GameHostShop.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/GameHostShop.java deleted file mode 100644 index 9bdc7809c..000000000 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/GameHostShop.java +++ /dev/null @@ -1,30 +0,0 @@ -package nautilus.game.arcade.gui; - -import java.util.Arrays; - -import org.bukkit.ChatColor; -import org.bukkit.Material; -import org.bukkit.entity.Player; -import org.bukkit.inventory.ItemStack; -import org.bukkit.inventory.meta.SkullMeta; - -import mineplex.core.account.CoreClientManager; -import mineplex.core.donation.DonationManager; -import mineplex.core.shop.ShopBase; -import mineplex.core.shop.page.ShopPageBase; -import nautilus.game.arcade.ArcadeManager; -import nautilus.game.arcade.gui.page.GameHostMenuPage; - -public class GameHostShop extends ShopBase -{ - public GameHostShop(ArcadeManager plugin, CoreClientManager clientManager, DonationManager donationManager) - { - super(plugin, clientManager, donationManager, "Private Server Menu"); - } - - @Override - protected ShopPageBase> BuildPagesFor(Player player) - { - return new GameHostMenuPage(Plugin, this, player); - } -} diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/GameSettingsButton.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/GameSettingsButton.java deleted file mode 100644 index 037683152..000000000 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/GameSettingsButton.java +++ /dev/null @@ -1,28 +0,0 @@ -package nautilus.game.arcade.gui.button; - -import org.bukkit.entity.Player; -import org.bukkit.event.inventory.ClickType; - -import mineplex.core.shop.item.IButton; -import nautilus.game.arcade.ArcadeManager; -import nautilus.game.arcade.gui.GameHostShop; -import nautilus.game.arcade.gui.page.GameHostOptionsPage; -import nautilus.game.arcade.gui.page.GiveAdminPage; - -public class GameSettingsButton implements IButton -{ - private ArcadeManager _arcadeManager; - private GameHostShop _shop; - - public GameSettingsButton(ArcadeManager arcadeManager, GameHostShop shop) - { - _shop = shop; - _arcadeManager = arcadeManager; - } - - @Override - public void onClick(Player player, ClickType clickType) - { - _shop.OpenPageForPlayer(player, new GameHostOptionsPage(_arcadeManager, _shop, player)); - } -} diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/PrivateServerShop.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/PrivateServerShop.java new file mode 100644 index 000000000..a6dbe14df --- /dev/null +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/PrivateServerShop.java @@ -0,0 +1,24 @@ +package nautilus.game.arcade.gui.privateServer; + +import org.bukkit.entity.Player; + +import mineplex.core.account.CoreClientManager; +import mineplex.core.donation.DonationManager; +import mineplex.core.shop.ShopBase; +import mineplex.core.shop.page.ShopPageBase; +import nautilus.game.arcade.ArcadeManager; +import nautilus.game.arcade.gui.privateServer.page.MenuPage; + +public class PrivateServerShop extends ShopBase +{ + public PrivateServerShop(ArcadeManager plugin, CoreClientManager clientManager, DonationManager donationManager) + { + super(plugin, clientManager, donationManager, "Private Server Menu"); + } + + @Override + protected ShopPageBase> BuildPagesFor(Player player) + { + return new MenuPage(Plugin, this, player); + } +} diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/BanButton.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/BanButton.java similarity index 61% rename from Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/BanButton.java rename to Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/BanButton.java index 7d09e2ff2..180bb8ee1 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/BanButton.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/BanButton.java @@ -1,19 +1,19 @@ -package nautilus.game.arcade.gui.button; +package nautilus.game.arcade.gui.privateServer.button; import org.bukkit.entity.Player; import org.bukkit.event.inventory.ClickType; import mineplex.core.shop.item.IButton; import nautilus.game.arcade.ArcadeManager; -import nautilus.game.arcade.gui.GameHostShop; -import nautilus.game.arcade.gui.page.BanPage; +import nautilus.game.arcade.gui.privateServer.PrivateServerShop; +import nautilus.game.arcade.gui.privateServer.page.BanPage; public class BanButton implements IButton { private ArcadeManager _arcadeManager; - private GameHostShop _shop; + private PrivateServerShop _shop; - public BanButton(ArcadeManager arcadeManager, GameHostShop shop) + public BanButton(ArcadeManager arcadeManager, PrivateServerShop shop) { _shop = shop; _arcadeManager = arcadeManager; diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/EditRotationButton.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/EditRotationButton.java similarity index 61% rename from Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/EditRotationButton.java rename to Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/EditRotationButton.java index bf7d0eb09..9e02640ae 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/EditRotationButton.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/EditRotationButton.java @@ -1,19 +1,19 @@ -package nautilus.game.arcade.gui.button; +package nautilus.game.arcade.gui.privateServer.button; import org.bukkit.entity.Player; import org.bukkit.event.inventory.ClickType; import mineplex.core.shop.item.IButton; import nautilus.game.arcade.ArcadeManager; -import nautilus.game.arcade.gui.GameHostShop; -import nautilus.game.arcade.gui.page.EditRotationPage; +import nautilus.game.arcade.gui.privateServer.PrivateServerShop; +import nautilus.game.arcade.gui.privateServer.page.EditRotationPage; public class EditRotationButton implements IButton { private ArcadeManager _arcadeManager; - private GameHostShop _shop; + private PrivateServerShop _shop; - public EditRotationButton(ArcadeManager arcadeManager, GameHostShop shop) + public EditRotationButton(ArcadeManager arcadeManager, PrivateServerShop shop) { _shop = shop; _arcadeManager = arcadeManager; diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/GiveAdminButton.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/GiveAdminButton.java similarity index 61% rename from Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/GiveAdminButton.java rename to Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/GiveAdminButton.java index 17fe7ef93..19fd20f85 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/GiveAdminButton.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/GiveAdminButton.java @@ -1,19 +1,19 @@ -package nautilus.game.arcade.gui.button; +package nautilus.game.arcade.gui.privateServer.button; import org.bukkit.entity.Player; import org.bukkit.event.inventory.ClickType; import mineplex.core.shop.item.IButton; import nautilus.game.arcade.ArcadeManager; -import nautilus.game.arcade.gui.GameHostShop; -import nautilus.game.arcade.gui.page.GiveAdminPage; +import nautilus.game.arcade.gui.privateServer.PrivateServerShop; +import nautilus.game.arcade.gui.privateServer.page.GiveAdminPage; public class GiveAdminButton implements IButton { private ArcadeManager _arcadeManager; - private GameHostShop _shop; + private PrivateServerShop _shop; - public GiveAdminButton(ArcadeManager arcadeManager, GameHostShop shop) + public GiveAdminButton(ArcadeManager arcadeManager, PrivateServerShop shop) { _shop = shop; _arcadeManager = arcadeManager; diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/OptionsButton.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/OptionsButton.java new file mode 100644 index 000000000..4b1e934a3 --- /dev/null +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/OptionsButton.java @@ -0,0 +1,27 @@ +package nautilus.game.arcade.gui.privateServer.button; + +import org.bukkit.entity.Player; +import org.bukkit.event.inventory.ClickType; + +import mineplex.core.shop.item.IButton; +import nautilus.game.arcade.ArcadeManager; +import nautilus.game.arcade.gui.privateServer.PrivateServerShop; +import nautilus.game.arcade.gui.privateServer.page.OptionsPage; + +public class OptionsButton implements IButton +{ + private ArcadeManager _arcadeManager; + private PrivateServerShop _shop; + + public OptionsButton(ArcadeManager arcadeManager, PrivateServerShop shop) + { + _shop = shop; + _arcadeManager = arcadeManager; + } + + @Override + public void onClick(Player player, ClickType clickType) + { + _shop.OpenPageForPlayer(player, new OptionsPage(_arcadeManager, _shop, player)); + } +} diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/SetGameButton.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/SetGameButton.java similarity index 61% rename from Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/SetGameButton.java rename to Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/SetGameButton.java index 1fb348a07..80159ae1f 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/SetGameButton.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/SetGameButton.java @@ -1,19 +1,19 @@ -package nautilus.game.arcade.gui.button; +package nautilus.game.arcade.gui.privateServer.button; import org.bukkit.entity.Player; import org.bukkit.event.inventory.ClickType; import mineplex.core.shop.item.IButton; import nautilus.game.arcade.ArcadeManager; -import nautilus.game.arcade.gui.GameHostShop; -import nautilus.game.arcade.gui.page.SetGamePage; +import nautilus.game.arcade.gui.privateServer.PrivateServerShop; +import nautilus.game.arcade.gui.privateServer.page.SetGamePage; public class SetGameButton implements IButton { private ArcadeManager _arcadeManager; - private GameHostShop _shop; + private PrivateServerShop _shop; - public SetGameButton(ArcadeManager arcadeManager, GameHostShop shop) + public SetGameButton(ArcadeManager arcadeManager, PrivateServerShop shop) { _shop = shop; _arcadeManager = arcadeManager; diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/UnbanButton.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/UnbanButton.java similarity index 61% rename from Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/UnbanButton.java rename to Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/UnbanButton.java index 2ca023eb5..affb50a28 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/button/UnbanButton.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/button/UnbanButton.java @@ -1,20 +1,19 @@ -package nautilus.game.arcade.gui.button; +package nautilus.game.arcade.gui.privateServer.button; import org.bukkit.entity.Player; import org.bukkit.event.inventory.ClickType; import mineplex.core.shop.item.IButton; import nautilus.game.arcade.ArcadeManager; -import nautilus.game.arcade.gui.GameHostShop; -import nautilus.game.arcade.gui.page.BanPage; -import nautilus.game.arcade.gui.page.UnbanPage; +import nautilus.game.arcade.gui.privateServer.PrivateServerShop; +import nautilus.game.arcade.gui.privateServer.page.UnbanPage; public class UnbanButton implements IButton { private ArcadeManager _arcadeManager; - private GameHostShop _shop; + private PrivateServerShop _shop; - public UnbanButton(ArcadeManager arcadeManager, GameHostShop shop) + public UnbanButton(ArcadeManager arcadeManager, PrivateServerShop shop) { _shop = shop; _arcadeManager = arcadeManager; diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/page/BanPage.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/page/BanPage.java similarity index 71% rename from Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/page/BanPage.java rename to Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/page/BanPage.java index 64514cecb..5779e1f58 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/page/BanPage.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/page/BanPage.java @@ -1,12 +1,12 @@ -package nautilus.game.arcade.gui.page; +package nautilus.game.arcade.gui.privateServer.page; import org.bukkit.entity.Player; import nautilus.game.arcade.ArcadeManager; -import nautilus.game.arcade.gui.GameHostShop; +import nautilus.game.arcade.gui.privateServer.PrivateServerShop; public class BanPage extends PlayerPage { - public BanPage(ArcadeManager plugin, GameHostShop shop, Player player) + public BanPage(ArcadeManager plugin, PrivateServerShop shop, Player player) { super(plugin, shop, "Ban Players", player); BuildPage(); diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/page/GameHostPage.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/page/BasePage.java similarity index 74% rename from Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/page/GameHostPage.java rename to Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/page/BasePage.java index 717829671..9629edc8c 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/page/GameHostPage.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/gui/privateServer/page/BasePage.java @@ -1,7 +1,6 @@ -package nautilus.game.arcade.gui.page; +package nautilus.game.arcade.gui.privateServer.page; import java.util.Arrays; -import java.util.function.Consumer; import org.bukkit.Material; import org.bukkit.entity.Player; @@ -14,19 +13,19 @@ import mineplex.core.shop.item.IButton; import mineplex.core.shop.item.ShopItem; import mineplex.core.shop.page.ShopPageBase; import nautilus.game.arcade.ArcadeManager; -import nautilus.game.arcade.gui.GameHostShop; +import nautilus.game.arcade.gui.privateServer.PrivateServerShop; import nautilus.game.arcade.managers.GameHostManager; -public abstract class GameHostPage extends ShopPageBase +public abstract class BasePage extends ShopPageBase { protected GameHostManager _manager; - public GameHostPage(ArcadeManager plugin, GameHostShop shop, String pageName, Player player) + public BasePage(ArcadeManager plugin, PrivateServerShop shop, String pageName, Player player) { this(plugin, shop, pageName, player, 54); } - public GameHostPage(ArcadeManager plugin, GameHostShop shop, String pageName, Player player, int slots) + public BasePage(ArcadeManager plugin, PrivateServerShop shop, String pageName, Player player, int slots) { super(plugin, shop, plugin.GetClients(), plugin.GetDonation(), pageName, player, slots); @@ -40,7 +39,7 @@ public abstract class GameHostPage extends ShopPageBase _whitelist = new HashSet(); private HashSet _blacklist = new HashSet(); - private GameHostShop _shop; + private PrivateServerShop _shop; public GameHostManager(ArcadeManager manager) { Manager = manager; - _shop = new GameHostShop(manager, manager.GetClients(), manager.GetDonation()); + _shop = new PrivateServerShop(manager, manager.GetClients(), manager.GetDonation()); Manager.GetPluginManager().registerEvents(this, Manager.GetPlugin()); //Ultra Games