public abstract class AbstractEconomy extends Object implements Economy
| Constructor and Description |
|---|
AbstractEconomy() |
| Modifier and Type | Method and Description |
|---|---|
EconomyResponse |
createBank(String name,
org.bukkit.OfflinePlayer player)
Creates a bank account with the specified name and the player as the owner
|
boolean |
createPlayerAccount(org.bukkit.OfflinePlayer player)
Attempts to create a player account for the given player
|
boolean |
createPlayerAccount(org.bukkit.OfflinePlayer player,
String worldName)
Attempts to create a player account for the given player on the specified world
IMPLEMENTATION SPECIFIC - if an economy plugin does not support this then false will always be returned.
|
EconomyResponse |
depositPlayer(org.bukkit.OfflinePlayer player,
double amount)
Deposit an amount to a player - DO NOT USE NEGATIVE AMOUNTS
|
EconomyResponse |
depositPlayer(org.bukkit.OfflinePlayer player,
String worldName,
double amount)
Deposit an amount to a player - DO NOT USE NEGATIVE AMOUNTS
IMPLEMENTATION SPECIFIC - if an economy plugin does not support this the global balance will be returned.
|
double |
getBalance(org.bukkit.OfflinePlayer player)
Gets balance of a player
|
double |
getBalance(org.bukkit.OfflinePlayer player,
String world)
Gets balance of a player on the specified world.
|
boolean |
has(org.bukkit.OfflinePlayer player,
double amount)
Checks if the player account has the amount - DO NOT USE NEGATIVE AMOUNTS
|
boolean |
has(org.bukkit.OfflinePlayer player,
String worldName,
double amount)
Checks if the player account has the amount in a given world - DO NOT USE NEGATIVE AMOUNTS
IMPLEMENTATION SPECIFIC - if an economy plugin does not support this the global balance will be returned.
|
boolean |
hasAccount(org.bukkit.OfflinePlayer player)
Checks if this player has an account on the server yet
This will always return true if the player has joined the server at least once
as all major economy plugins auto-generate a player account when the player joins the server
|
boolean |
hasAccount(org.bukkit.OfflinePlayer player,
String worldName)
Checks if this player has an account on the server yet on the given world
This will always return true if the player has joined the server at least once
as all major economy plugins auto-generate a player account when the player joins the server
|
EconomyResponse |
isBankMember(String name,
org.bukkit.OfflinePlayer player)
Check if the player is a member of the bank account
|
EconomyResponse |
isBankOwner(String name,
org.bukkit.OfflinePlayer player)
Check if a player is the owner of a bank account
|
EconomyResponse |
withdrawPlayer(org.bukkit.OfflinePlayer player,
double amount)
Withdraw an amount from a player - DO NOT USE NEGATIVE AMOUNTS
|
EconomyResponse |
withdrawPlayer(org.bukkit.OfflinePlayer player,
String worldName,
double amount)
Withdraw an amount from a player on a given world - DO NOT USE NEGATIVE AMOUNTS
IMPLEMENTATION SPECIFIC - if an economy plugin does not support this the global balance will be returned.
|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitbankBalance, bankDeposit, bankHas, bankWithdraw, createBank, createPlayerAccount, createPlayerAccount, currencyNamePlural, currencyNameSingular, deleteBank, depositPlayer, depositPlayer, format, fractionalDigits, getBalance, getBalance, getBanks, getName, has, has, hasAccount, hasAccount, hasBankSupport, isBankMember, isBankOwner, isEnabled, withdrawPlayer, withdrawPlayerpublic AbstractEconomy()
public boolean hasAccount(org.bukkit.OfflinePlayer player)
EconomyhasAccount in interface Economyplayer - to checkpublic boolean hasAccount(org.bukkit.OfflinePlayer player, String worldName)
EconomyhasAccount in interface Economyplayer - to check in the worldworldName - world-specific accountpublic double getBalance(org.bukkit.OfflinePlayer player)
EconomygetBalance in interface Economyplayer - of the playerpublic double getBalance(org.bukkit.OfflinePlayer player, String world)
EconomygetBalance in interface Economyplayer - to checkworld - name of the worldpublic boolean has(org.bukkit.OfflinePlayer player, double amount)
Economypublic boolean has(org.bukkit.OfflinePlayer player, String worldName, double amount)
Economypublic EconomyResponse withdrawPlayer(org.bukkit.OfflinePlayer player, double amount)
EconomywithdrawPlayer in interface Economyplayer - to withdraw fromamount - Amount to withdrawpublic EconomyResponse withdrawPlayer(org.bukkit.OfflinePlayer player, String worldName, double amount)
EconomywithdrawPlayer in interface Economyplayer - to withdraw fromworldName - - name of the worldamount - Amount to withdrawpublic EconomyResponse depositPlayer(org.bukkit.OfflinePlayer player, double amount)
EconomydepositPlayer in interface Economyplayer - to deposit toamount - Amount to depositpublic EconomyResponse depositPlayer(org.bukkit.OfflinePlayer player, String worldName, double amount)
EconomydepositPlayer in interface Economyplayer - to deposit toworldName - name of the worldamount - Amount to depositpublic EconomyResponse createBank(String name, org.bukkit.OfflinePlayer player)
EconomycreateBank in interface Economyname - of accountplayer - the account should be linked topublic EconomyResponse isBankOwner(String name, org.bukkit.OfflinePlayer player)
EconomyisBankOwner in interface Economyname - of the accountplayer - to check for ownershippublic EconomyResponse isBankMember(String name, org.bukkit.OfflinePlayer player)
EconomyisBankMember in interface Economyname - of the accountplayer - to check membershippublic boolean createPlayerAccount(org.bukkit.OfflinePlayer player)
EconomycreatePlayerAccount in interface Economyplayer - OfflinePlayerpublic boolean createPlayerAccount(org.bukkit.OfflinePlayer player, String worldName)
EconomycreatePlayerAccount in interface Economyplayer - OfflinePlayerworldName - String name of the worldMilkbowl, 2020