Search in sources :

Example 1 with BankMenu

use of xyz.derkades.ublisk.money.BankMenu in project Ublisk by Derkades.

the class MainMenu method onOptionClick.

@Override
public boolean onOptionClick(OptionClickEvent event) {
    String name = event.getName().toLowerCase();
    final UPlayer player = new UPlayer(event.getPlayer());
    if (name.equals("settings")) {
        new SettingsMenu(player).open();
    } else if (name.equals("voting")) {
        new VotingMenu(player).open();
    } else if (name.equals("friends")) {
        new FriendsMenu(player).open();
    } else if (name.equals("help")) {
        new HelpMenu(player).open();
    } else if (name.equals("bank")) {
        new BankMenu(player).open();
    } else {
        player.sendMessage(Message.ERROR_MENU);
    }
    return false;
}
Also used : UPlayer(xyz.derkades.ublisk.utils.UPlayer) HelpMenu(xyz.derkades.ublisk.iconmenus.help.HelpMenu) BankMenu(xyz.derkades.ublisk.money.BankMenu)

Aggregations

HelpMenu (xyz.derkades.ublisk.iconmenus.help.HelpMenu)1 BankMenu (xyz.derkades.ublisk.money.BankMenu)1 UPlayer (xyz.derkades.ublisk.utils.UPlayer)1