Package com.palmergames.bukkit.util
Class Colors
java.lang.Object
com.palmergames.bukkit.util.Colors
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic String
colorNation
(Nation nation) static String
colorNation
(String nationName) static String
static String
static boolean
containsColourCode
(String input) static String
getLegacyFromNamedTextColor
(net.kyori.adventure.text.format.NamedTextColor colour) static String
static String
static String
static @Nullable net.kyori.adventure.text.format.NamedTextColor
toNamedTextColor
(@NotNull String color) static String
static String
translateLegacyCharacters
(String input) static String
translateLegacyHex
(String input) Converts non-minimessage hex formats to minimessage.
-
Field Details
-
Black
- See Also:
-
Green
- See Also:
-
Blue
- See Also:
-
Red
- See Also:
-
Purple
- See Also:
-
Gold
- See Also:
-
LightGray
- See Also:
-
Gray
- See Also:
-
DarkPurple
- See Also:
-
LightGreen
- See Also:
-
LightBlue
- See Also:
-
Rose
- See Also:
-
LightPurple
- See Also:
-
Yellow
- See Also:
-
White
- See Also:
-
DARK_RED
- See Also:
-
RED
- See Also:
-
GOLD
- See Also:
-
YELLOW
- See Also:
-
DARK_GREEN
- See Also:
-
GREEN
- See Also:
-
DARK_AQUA
- See Also:
-
AQUA
- See Also:
-
DARK_BLUE
- See Also:
-
BLUE
- See Also:
-
LIGHT_PURPLE
- See Also:
-
DARK_PURPLE
- See Also:
-
WHITE
- See Also:
-
GRAY
- See Also:
-
DARK_GRAY
- See Also:
-
BLACK
- See Also:
-
OBFUSCATED
- See Also:
-
BOLD
- See Also:
-
STRIKETHROUGH
- See Also:
-
UNDERLINED
- See Also:
-
ITALIC
- See Also:
-
RESET
- See Also:
-
-
Constructor Details
-
Colors
public Colors()
-
-
Method Details
-
strip
-
translateColorCodes
-
translateLegacyCharacters
-
translateLegacyHex
Converts non-minimessage hex formats to minimessage.- Parameters:
input
- The input that may or may not contain hex.- Returns:
- The input, with the minimessage hex format.
-
toNamedTextColor
@Nullable public static @Nullable net.kyori.adventure.text.format.NamedTextColor toNamedTextColor(@NotNull @NotNull String color) - Parameters:
color
- A legacy color code or a MiniMessage<color>
tag- Returns:
- the
NamedTextColor
for the entered color string, or null if it is invalid.
-
colorTown
-
colorTown
-
colorNation
-
colorNation
-
getTownColor
-
getNationColor
-
containsColourCode
-
getLegacyFromNamedTextColor
public static String getLegacyFromNamedTextColor(net.kyori.adventure.text.format.NamedTextColor colour)
-