src/me/neznamy/tab/shared/placeholders/Placeholders.java
public static String color(String textToTranslate){
		if (textToTranslate == null) return null;
		if (!textToTranslate.contains("&")) return textToTranslate;
		char[] b = textToTranslate.toCharArray();
		for (int i = 0; i < b.length - 1; i++) {
			if ((b[i] == '&') && ("0123456789AaBbCcDdEeFfKkLlMmNnOoRr".indexOf(b[(i + 1)]) > -1)){
				b[i] = colorChar;
				b[(i + 1)] = Character.toLowerCase(b[(i + 1)]);
			}
		}
		return new String(b);
	}
//code taken from bukkit, so it can work on bungee too
code taken from bukkit, so it can work on bungee too
code taken from bukkit so it can work on bungee too
public static String color(String textToTranslate){
		if (textToTranslate == null) return null;
		if (!textToTranslate.contains("&")) return textToTranslate;
		char[] b = textToTranslate.toCharArray();
		for (int i = 0; i < b.length - 1; i++) {
			if ((b[i] == '&') && ("0123456789AaBbCcDdEeFfKkLlMmNnOoRr".indexOf(b[(i + 1)]) > -1)){
				b[i] = colorChar;
				b[(i + 1)] = Character.toLowerCase(b[(i + 1)]);
			}
		}
		return new String(b);
	}
public static String color ( String textToTranslate ) { if ( textToTranslate == null ) return null ; if ( ! textToTranslate . contains ( "&" ) ) return textToTranslate ; char [ ] b = textToTranslate . toCharArray ( ) ; for ( int i = 0 ; i < b . length - 1 ; i ++ ) { if ( ( b [ i ] == '&' ) && ( "0123456789AaBbCcDdEeFfKkLlMmNnOoRr" . indexOf ( b [ ( i + 1 ) ] ) > - 1 ) ) { b [ i ] = colorChar ; b [ ( i + 1 ) ] = Character . toLowerCase ( b [ ( i + 1 ) ] ) ; } } return new String ( b ) ; }
code taken from bukkit, so it can work on bungee too
code taken from bukkit so it can work on bungee too