This update addresses the Myriad API. The custom return classes have been deprecated in favor of simple objects
All existing API calls will function, but are showing as deprecated and may be removed in an upcoming version.
New API calls as follows:
Code (Java):
/** * Gets the plugin version * @return Plugin Version */ String version
()
/** * Gets the players clan tag * @param uuid Player Unique Identifier * @return Players clan tag if they have one, otherwise, returns a blank string */ String getPlayerClanTag
(UUID uuid
)
/** * Returns true if the clan tag specified exists * @param tag Clan Tag * @return If true, clan exists */ boolean clanExists
(String tag
)
/** * Updates the specified clan with this clan object * Use getClanFromTag to get the clan, make changes, pass that value to modifyClan * @param clan Clan object * @return If true, clan was updated */ boolean modifyClan
(Clan clan
)
/** * Removes the clan specified * @param tag Clan tag * @return If true, clan was removed */ boolean removeClan
(String tag
)
/** * Gets a Clan from the clan tag * @param tag Clan tag * @return Clan object, null if not found */ Clan getClanFromTag
(String tag
)
/** * Gets a set of Clan objects that exist * @return All clans */ Set
<Clan
> getAllClans
()
/** * Creates a new clan. Will fail if the owner is in a clan, or if the tag or name already exists * Can also fail if the owner does not have the required funds to create the clan * @param owner Clan owner * @param tag Clan tag * @param name Clan name * @return If true, clan was created successfully */ boolean createNewClan
(UUID owner,
String tag,
String name
)
/** * Returns true if the player is a pending member of a clan * @param uuid Player unique identifier * @return If true, player is a pending member already */ boolean playerIsPending
(UUID uuid
)
/** * Adds a player to the pending list of the clan * If the player is already pending elsewhere, they will be removed from that pending list * @param uuid Player unique identifier * @param tag Clan tag to add to */ void addPlayerToPending
(UUID uuid,
String tag
)
/** * Removes a player from any pending list * @param uuid Player unique identifier */ void removePlayerFromPending
(UUID uuid
)
/** * Adds a player as a clan member * @param uuid Player unique identifier * @param tag Clan tag to add to */ void addPlayerAsClanMember
(UUID uuid,
String tag
)
/** * Removes a player from any clan they are in * @param uuid Player unique identifier */ void removePlayerFromClans
(UUID uuid
)
/** * Adds a Message for a player * @param message Player message */ void addPlayerMessage
(Message message
)
/** * Gets all messages assigned to a player * @param message_to Player unique identifier * @return */ Set
<Message
> getPlayerMessages
(UUID message_to
)
/** * Transfers funds from a player to a clan * Requires Vault * @param offlinePlayer Player to transfer from * @param tag Clan tag to transfer to * @param amount Amount to transfer */ void transferFundsPlayerToClan
(OfflinePlayer offlinePlayer,
String tag,
Double amount
)
/** * Transfers funds from a clan to a player * Requires Vault * @param offlinePlayer Player to transfer to * @param tag Clan tag to transfer from * @param amount Amount to transfer */ void transferFundsClanToPlayer
(OfflinePlayer offlinePlayer,
String tag,
Double amount
)
/** * Removes funds from a clan * Requires Vault * @param tag Clan tag to remove funds from * @param amount Amount to remove */ void removeClanFunds
(String tag,
Double amount
)