Package wtf.choco.veinminer.economy
Interface SimpleEconomy
- All Known Implementing Classes:
EmptyEconomy
,SimpleVaultEconomy
public interface SimpleEconomy
A wrapper for economic transactions
-
Method Summary
Modifier and TypeMethodDescriptionboolean
hasSufficientBalance
(@NotNull PlatformPlayer player, double amount) Check whether or not the provided player has a sufficient amount of money to be charged.boolean
shouldCharge
(@NotNull PlatformPlayer player) Check whether the provided player should have money withdrawn from their account before vein mining.void
withdraw
(@NotNull PlatformPlayer player, double amount) Withdraw money from the specified player.
-
Method Details
-
shouldCharge
Check whether the provided player should have money withdrawn from their account before vein mining.- Parameters:
player
- the player to check- Returns:
- true if money should be withdrawn, false otherwise
-
hasSufficientBalance
Check whether or not the provided player has a sufficient amount of money to be charged.- Parameters:
player
- the the player to checkamount
- the amount of money to withdraw- Returns:
- true if the player has a sufficient amount of money, false otherwise
-
withdraw
Withdraw money from the specified player.- Parameters:
player
- the player from whom money should be withdrawnamount
- the amount of money to withdraw
-