Interface XPrisonMultipliersAPI
public interface XPrisonMultipliersAPI
API interface for managing multipliers related to sell amounts and tokens.
-
Method Summary
Modifier and TypeMethodDescriptionGets the current global sell multiplier.Gets the current global token multiplier.double
getPlayerMultiplier
(org.bukkit.entity.Player p, MultiplierType multiplierType) Gets the overall multiplier for a player based on the specified multiplier type.getRankMultiplier
(org.bukkit.entity.Player p) Gets the player's rank multiplier.getSellMultiplier
(org.bukkit.entity.Player p) Gets the player's sell multiplier.getTokenMultiplier
(org.bukkit.entity.Player p) Gets the player's token multiplier.default double
getTotalToDeposit
(org.bukkit.entity.Player p, double deposit, MultiplierType type) Calculates the total amount to deposit after applying the player's multiplier.
-
Method Details
-
getGlobalSellMultiplier
Multiplier getGlobalSellMultiplier()Gets the current global sell multiplier.- Returns:
- the global sell
Multiplier
-
getGlobalTokenMultiplier
Multiplier getGlobalTokenMultiplier()Gets the current global token multiplier.- Returns:
- the global token
Multiplier
-
getSellMultiplier
Gets the player's sell multiplier.- Parameters:
p
- the player- Returns:
- the
PlayerMultiplier
for selling
-
getTokenMultiplier
Gets the player's token multiplier.- Parameters:
p
- the player- Returns:
- the
PlayerMultiplier
for tokens
-
getRankMultiplier
Gets the player's rank multiplier.- Parameters:
p
- the player- Returns:
- the
PlayerMultiplier
for the player's rank
-
getPlayerMultiplier
Gets the overall multiplier for a player based on the specified multiplier type.- Parameters:
p
- the playermultiplierType
- the type of multiplier (SELL / TOKENS)- Returns:
- the overall multiplier as a double
-
getTotalToDeposit
Calculates the total amount to deposit after applying the player's multiplier.- Parameters:
p
- the playerdeposit
- the original amount to deposittype
- the multiplier type (tokens or money)- Returns:
- the new amount to deposit after applying multiplier
-