@Override public boolean subtract(String playerName, double amount) { if (canAfford(playerName, amount)) { return plugin.setPlayerMoney( playerName, plugin.getPlayerMoneyDouble(playerName) - amount, false); } return false; }
@Override public boolean canAfford(String playerName, double amount) { double balance = plugin.getPlayerMoneyDouble(playerName); if (balance >= amount) { return true; } return false; }
@Override public boolean add(String playerName, double amount) { return plugin.setPlayerMoney( playerName, plugin.getPlayerMoneyDouble(playerName) + amount, false); }
@Override public double getBalance(String playerName) { return plugin.getPlayerMoneyDouble(playerName); }