Interface WConfig
public interface WConfig
Represents the config API for PlayerWarps.
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addConfigBlacklist
(String file, List<String> paths) Add blacklist paths and sections for the config file.default String
formatNumber
(double number) formatNumber
(double number, boolean shortFormat) formatNumberShort
(double number) static void
getInstance
(Consumer<WConfig> api) Waits for the instance of the API when it is ready.getLanguageValue
(String key) getLanguageValue
(UUID uuid, String key)
-
Field Details
-
instance
-
apis
-
-
Method Details
-
getInstance
Waits for the instance of the API when it is ready.- Parameters:
api
- Callback with the instance of the API.
-
addConfigBlacklist
Add blacklist paths and sections for the config file.- Parameters:
file
- The file to blacklist the paths.paths
- The list of the blacklist paths.
-
formatNumber
- Parameters:
number
- The number to format.- Returns:
- The formatted number.
-
formatNumber
- Parameters:
number
- The number to format.shortFormat
- If the number should be formatted in a short format, in the config short formatting needs to be enabled as well.- Returns:
- The formatted number.
-
formatNumberShort
- Parameters:
number
- The number to short format.- Returns:
- The formatted number.
-
getLanguageValue
- Parameters:
key
- The key from the language file.- Returns:
- The language value based on the default language.
-
getLanguageValue
- Parameters:
key
- The key from the language file.uuid
- The uuid of the player to get the language type.- Returns:
- The language value.
-