Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Player p = Bukkit.getPlayer("Wazup92");
- PartyGamesAPI.isInArena(p); //Returns true if player is inside an arena, does not matter if he is playing or not.
- PartyGamesAPI.getArenaName(p); //Returns arena name, must check if player is in an arena first!
- PartyGamesAPI.isSpectating(p); //Returns true if the player is inside an arena and is spectating (not participating as a player in any of the minigames)
- PartyGamesAPI.isPlaying(p); //Returns true if player is inside an arena and is playing (not spectating)
- PartyGamesAPI.getMinigamesFolderPath(); //Returns the path to the minigames folder. Generally speaking, you do not need to use this.
- //The methods below are all useful tools for when registering your own minigames!
- Cuboid cuboid = PartyGamesAPI.getPlayerSelection(p); //Returns the player selection that was made using partygames wand!
- if(cuboid != null) {
- Bukkit.broadcastMessage("Iterating over: " + cuboid.getSize() + " blocks and setting them to air!");
- Iterator<Block> iterator = cuboid.iterator();
- while(iterator.hasNext()) iterator.next().setType(Material.AIR);
- }
- PartyGamesAPI.removePlayerSelection(p); //Sets a player partygames selection to null
- PartyGamesAPI.MakeSpectator(p, true); //Gives the player the spectator effects (Invisibility and flight or simply gamemode 3 when available), this should be used when a player is eliminated from a minigame
- PartyGamesAPI.MakeSpectator(p, false); //Removes the player spectator effects (This should be run on eliminated players when the minigame is finished)
- PartyGamesAPI.getMessage("No-Permission"); //Returns the message tagged as 'No-Permission' in customization.yml
- Arena someArena = null; //You can get an arena when registering a custom minigame and extending the MiniGame class
- PartyGamesAPI.sendRoundConclusion(someArena, new String[] {"Wazup92", "Wazup91", "Wazup90"}); //The second parameter is a String[] whose size must be at least 3!
- PartyGamesAPI.getItemStackFromString("WOOD_SWORD : 1 : enchant:DAMAGE_ALL:1"); //This is a method that reads a string and converts it to an item stack!
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement