API Methods

This page is dedicated to explain how PartiesAPI methods work.

You can find the Javadoc here: http://api.alessiodp.com/javadoc/parties/

You can use classes Party and PartyPlayer to edit the data, if you change something you need to update them, see below:

PartiesAPI api = Parties.getApi(); // Get Parties API
Party party = api.getParty("MyParty"); // Get the party 'MyParty'
party.setDescription("just a new description"); // Change the description
api.updateParty(party); // Update the party

Another example:

UUID playerUUID; // Get a player uuid
PartiesAPI api = Parties.getApi(); // Get Parties API
PartyPlayer player = api.getPartyPlayer(playerUUID); // Get the player that have as UUID 'playerUUID'
player.setPartyName("MyParty"); // Change the party of the player to 'MyParty'
player.setRank(1); // Set the player rank to 1
api.updatePartyPlayer(player); // Update the player


If you are using a code that is deprecated, you really should update it. I will deprecate methods that will be removed with future updates.