[API] P-API 1.1

[1.8 R3] Simple API for Titles, Actionbar, Tab header & footer and Glowingitems!

  1. Pustekuchen98
    This API is a simple way to use Titles, Actionbar, Tab header & footer and Glowingitems without massive lines of code in version 1.8 R3 and higher. Here i will provide code-snippets for every function.

    !!!IMPORTANT!!!
    You have to add this plugin to your buildpath, to the server and you have to put it as a dependency in your plugin.yml.

    If you have suggestions or found bugs please write it into the discussion section.

    Examples:

    -ACTIONBAR

    Broadcasts a message in the actionbar to anybody on the server.

    Code (Text):
    Action.broadcastAllAction(message);

    Broadcasts a message in the actionbar to a specified player.
    Code (Text):
    Action.playAction(player, message);


    - Glowingitems

    Add an enchantment glow to any item.
    Code (Text):

    ItemStack Glow = new ItemStack( Material.STAINED_GLASS_PANE, 1, (short) 14);
    ItemMeta metaGlow = Glow.getItemMeta();
    metaGlow.setDisplayName("§6§lGlow");
    Glow.setItemMeta(metaGlow);
    inv.setItem(25, GlowingItems.addGlow(Glow));
     


    -Tablist

    Sets the Tab-header and footer for a specified player.
    Code (Text):
     Tablist.setTablist(player, header, footer);


    Sets the Tab-header and footer for all players.
    Code (Text):
     Tablist.setTablistAll(header, footer);


    -Title

    Sends a title to all players.
    Code (Text):
     Title.broadcastAllFullTitle(fadeIn, stay, fadeOut, subtitle, title);
    Sends only a subtitle.
    Code (Text):
     Title.broadcastAllSubTitle(fadeIn, stay, fadeOut, text);
    Sends a normal title without a subtitle.
    Code (Text):
     Title.broadcastAllTitle(fadeIn, stay, fadeOut, text);
    Sends a title to a specified player.
    Code (Text):
     Title.playFullTitle(player, fadeIn, stay, fadeOut, title, subtitle);
    Sends only a subtitle to a specified player.
    Code (Text):
     Title.playSubTitle(player, fadeIn, stay, fadeOut, text);
    Sends a normal title without a subtitle to a specified player.
    Code (Text):
     Title.playTitle(player, fadeIn, stay, fadeOut, text);
    Sends a full title to a specified player and replaces %player% with the playername.
    Code (Text):
     Title.playTitle(player, fadeIn, stay, fadeOut, title, subtitle);









Recent Updates

  1. Metrics