Package de.kentoj.scrowlib.economy
Class InMemoryEconomyService
java.lang.Object
de.kentoj.scrowlib.economy.InMemoryEconomyService
- All Implemented Interfaces:
EconomyService
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddepositCoins(UUID playerId, int amount) adds coins to the players accountintvoidbooleantryWithdrawCoins(UUID playerId, int amount) tries to take coins from the player's account or returns false on insufficient funds
-
Constructor Details
-
InMemoryEconomyService
public InMemoryEconomyService()
-
-
Method Details
-
getCoins
- Specified by:
getCoinsin interfaceEconomyService
-
setCoins
- Specified by:
setCoinsin interfaceEconomyService- Parameters:
playerId- uuid of player
-
depositCoins
Description copied from interface:EconomyServiceadds coins to the players account- Specified by:
depositCoinsin interfaceEconomyService- Parameters:
playerId- uuid of player
-
tryWithdrawCoins
Description copied from interface:EconomyServicetries to take coins from the player's account or returns false on insufficient funds- Specified by:
tryWithdrawCoinsin interfaceEconomyService- Parameters:
playerId- uuid of player- Returns:
- true on success, false on insufficient funds
-