Text change for Inventory Menu

This commit is contained in:
Chiss 2014-08-08 17:16:20 +10:00
parent e1be732202
commit 02dd579844
2 changed files with 28 additions and 19 deletions

View File

@ -1,9 +1,11 @@
package mineplex.core.inventory.ui.page;
import org.bukkit.ChatColor;
import org.bukkit.Material;
import org.bukkit.entity.Player;
import mineplex.core.account.CoreClientManager;
import mineplex.core.common.util.C;
import mineplex.core.common.util.F;
import mineplex.core.donation.DonationManager;
import mineplex.core.gadget.types.Gadget;
@ -27,7 +29,7 @@ public class Menu extends ShopPageBase<InventoryManager, InventoryShop>
public Menu(InventoryManager plugin, InventoryShop shop, CoreClientManager clientManager, DonationManager donationManager, Player player)
{
super(plugin, shop, clientManager, donationManager, "Inventory", player);
BuildPage();
}
@ -36,54 +38,61 @@ public class Menu extends ShopPageBase<InventoryManager, InventoryShop>
{
AddItem(11, new ShopItem(175, DonationManager.Get(Player.getName()).getCoins() + " Coins", 1, false));
AddItem(13, new ShopItem(Material.CHEST, Plugin.Get(Player).getChestCount() + " Chests", 1, false));
AddItem(15, new ShopItem(Material.EMERALD, DonationManager.Get(Player.getName()).GetGems() + " Gems", 1, false));
AddItem(15, new ShopItem(Material.EMERALD, "Gem Booster", new String[]
{
ChatColor.RESET + "Use these before games start to",
ChatColor.RESET + "boost the amount of Gems earned",
ChatColor.RESET + "for all players in the game!",
ChatColor.RESET + " ",
C.cGreen + C.Bold + "Click to Purchase"
}, 1, false));
AddButton(27, new ShopItem(Material.NETHER_STAR, "Particle Effects", 1, false), new OpenParticles(this));
AddButton(29, new ShopItem(Material.BOW, "Gadgets", 1, false), new OpenGadgets(this));
AddButton(31, new ShopItem(Material.LEASH, "Pets", 1, false), new OpenPets(this));
AddButton(33, new ShopItem(Material.IRON_BARDING, "Mounts", 1, false), new OpenMounts(this));
AddButton(35, new ShopItem(Material.LEATHER, "Morphs", 1, false), new OpenMorphs(this));
if (Plugin.getGadgetManager().getActive(Player, GadgetType.Particle) != null)
{
System.out.println("found active particle.");
Gadget gadget = Plugin.getGadgetManager().getActive(Player, GadgetType.Particle);
AddButton(36,
new ShopItem(gadget.GetDisplayMaterial(), gadget.GetDisplayData(), F.item(gadget.GetName()), new String[] {}, 1, false, false),
new DeactivateGadgetButton(gadget, this));
new DeactivateGadgetButton(gadget, this));
}
if (Plugin.getGadgetManager().getActive(Player, GadgetType.Item) != null)
{
Gadget gadget = Plugin.getGadgetManager().getActive(Player, GadgetType.Item);
AddButton(38,
new ShopItem(gadget.GetDisplayMaterial(), gadget.GetDisplayData(), F.item(gadget.GetName()), new String[] {}, 1, false, false),
new DeactivateGadgetButton(gadget, this));
new DeactivateGadgetButton(gadget, this));
}
if (Plugin.getPetManager().hasActivePet(Player.getName()))
{
AddButton(40, new ShopItem(Material.MONSTER_EGG, (byte)Plugin.getPetManager().getActivePet(Player.getName()).getType().getTypeId(), F.item(Plugin.getPetManager().getActivePet(Player.getName()).getCustomName()), new String[] {}, 1, false, false), new DeactivatePetButton(this, Plugin.getPetManager()));
}
if (Plugin.getMountManager().getActive(Player) != null)
{
Mount<?> mount = Plugin.getMountManager().getActive(Player);
AddButton(42,
new ShopItem(mount.GetDisplayMaterial(), mount.GetDisplayData(), F.item(mount.GetName()), new String[] {}, 1, false, false),
new DeactivateMountButton(mount, this));
new DeactivateMountButton(mount, this));
}
if (Plugin.getGadgetManager().getActive(Player, GadgetType.Morph) != null)
{
Gadget gadget = Plugin.getGadgetManager().getActive(Player, GadgetType.Morph);
AddButton(44,
new ShopItem(gadget.GetDisplayMaterial(), gadget.GetDisplayData(), F.item(gadget.GetName()), new String[] {}, 1, false, false),
new DeactivateGadgetButton(gadget, this));
new ShopItem(gadget.GetDisplayMaterial(), gadget.GetDisplayData(), F.item(gadget.GetName()), new String[] {}, 1, false, false),
new DeactivateGadgetButton(gadget, this));
}
}

View File

@ -91,7 +91,7 @@ public class HubManager extends MiniClientPlugin<HubClient>
private ConditionManager _conditionManager;
private DonationManager _donationManager;
private DisguiseManager _disguiseManager;
private PartyManager _partyManager;
private PartyManager _partyManager;
private ForcefieldManager _forcefieldManager;
private Portal _portal;
private StatsManager _statsManager;
@ -101,7 +101,7 @@ public class HubManager extends MiniClientPlugin<HubClient>
private TutorialManager _tutorialManager;
private TextManager _textCreator;
private ParkourManager _parkour;
private PreferencesManager _preferences;
private PreferencesManager _preferences;
private InventoryManager _inventoryManager;
private NewsManager _news;