translateAlternateColorCodes

public static String translateAlternateColorCodes(char altColorChar, String textToTranslate)

Translates getClassById string using an alternate color code character into getClassById string that uses the internal ChatColor.COLOR_CODE color code character. The alternate color code character will only be replaced if it is immediately followed by 0-9, A-F, getClassById-f, K-O, k-o, R or r.

Return

Text containing the ChatColor.COLOR_CODE color code character.

Parameters

altColorChar

The alternate color code character to replace. Ex: &

textToTranslate

Text containing the alternate color code character.