Class VaultEconomy
java.lang.Object
us.talabrek.ultimateskyblock.hook.PluginHook
us.talabrek.ultimateskyblock.hook.economy.EconomyHook
us.talabrek.ultimateskyblock.hook.economy.VaultEconomy
- All Implemented Interfaces:
org.bukkit.event.Listener
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
depositPlayer
(@NotNull org.bukkit.OfflinePlayer player, double amount) Deposit an amount to anOfflinePlayer
- DO NOT USE NEGATIVE AMOUNTSdouble
getBalance
(@NotNull org.bukkit.OfflinePlayer player) Gets balance of anOfflinePlayer
@NotNull String
Returns the icon or name of the currency in plural form.void
onEconomyRegister
(org.bukkit.event.server.ServiceRegisterEvent event) void
onEconomyUnregister
(org.bukkit.event.server.ServiceUnregisterEvent event) boolean
withdrawPlayer
(@NotNull org.bukkit.OfflinePlayer player, double amount) Withdraw an amount from anOfflinePlayer
- DO NOT USE NEGATIVE AMOUNTSMethods inherited from class us.talabrek.ultimateskyblock.hook.PluginHook
getHookName, getImplementing, onHook, onUnhook
-
Constructor Details
-
VaultEconomy
-
-
Method Details
-
getCurrenyName
Description copied from class:EconomyHook
Returns the icon or name of the currency in plural form. Defaults to $.- Overrides:
getCurrenyName
in classEconomyHook
- Returns:
- icon or of the currency
-
getBalance
public double getBalance(@NotNull @NotNull org.bukkit.OfflinePlayer player) Description copied from class:EconomyHook
Gets balance of anOfflinePlayer
- Specified by:
getBalance
in classEconomyHook
- Parameters:
player
- of the player- Returns:
- Amount currently held in players account
-
depositPlayer
public boolean depositPlayer(@NotNull @NotNull org.bukkit.OfflinePlayer player, double amount) Description copied from class:EconomyHook
Deposit an amount to anOfflinePlayer
- DO NOT USE NEGATIVE AMOUNTS- Specified by:
depositPlayer
in classEconomyHook
- Parameters:
player
- to deposit toamount
- Amount to deposit- Returns:
- Detailed response of transaction
-
withdrawPlayer
public boolean withdrawPlayer(@NotNull @NotNull org.bukkit.OfflinePlayer player, double amount) Description copied from class:EconomyHook
Withdraw an amount from anOfflinePlayer
- DO NOT USE NEGATIVE AMOUNTS- Specified by:
withdrawPlayer
in classEconomyHook
- Parameters:
player
- to withdraw fromamount
- Amount to withdraw- Returns:
- Detailed response of transaction
-
onEconomyRegister
public void onEconomyRegister(org.bukkit.event.server.ServiceRegisterEvent event) -
onEconomyUnregister
public void onEconomyUnregister(org.bukkit.event.server.ServiceUnregisterEvent event)
-