Skip to content

Commit

Permalink
Add new createAccount methods with parameter to indicate if player ac…
Browse files Browse the repository at this point in the history
…count or not.
  • Loading branch information
creatorfromhell committed Dec 18, 2024
1 parent 6579ca3 commit 5725fb0
Showing 1 changed file with 24 additions and 1 deletion.
25 changes: 24 additions & 1 deletion src/main/java/net/milkbowl/vault2/economy/Economy.java
Original file line number Diff line number Diff line change
Expand Up @@ -187,14 +187,25 @@ public interface Economy {
*/

/**
* Attempts to create a account for the given UUID.
* Attempts to create an account for the given UUID.
*
* @param accountID UUID associated with the account.
* @param name UUID associated with the account.
* @return true if the account creation was successful.
*/
boolean createAccount(final UUID accountID, final String name);

/**
* Creates a new account with the provided information.
*
* @param accountID The UUID of the account to be created.
* @param name The name associated with the account.
* @param player A flag indicating if the account is a player account.
*
* @return true if the account was successfully created, false otherwise.
*/
boolean createAccount(final UUID accountID, final String name, final boolean player);

/**
* Attempts to create an account for the given UUID on the specified world
* IMPLEMENTATION SPECIFIC - if an economy plugin does not support this then
Expand All @@ -207,6 +218,18 @@ public interface Economy {
*/
boolean createAccount(final UUID accountID, final String name, final String worldName);

/**
* Creates a new account with the given parameters.
*
* @param accountID The UUID of the account to be created.
* @param name The name of the account holder.
* @param worldName The world name associated with the account.
* @param player A boolean indicating if the account belongs to a player.
*
* @return True if the account was successfully created, false otherwise.
*/
boolean createAccount(final UUID accountID, final String name, final String worldName, final boolean player);

/**
* Returns a map that represents all the UUIDs which have accounts in the
* plugin, as well as their last-known-name. This is used for Vault's economy
Expand Down

0 comments on commit 5725fb0

Please sign in to comment.