Class ChatColors

java.lang.Object
io.github.bakedlibs.dough.common.ChatColors

public final class ChatColors extends Object
This class contains some utilities related to ChatColor.
Author:
TheBusyBiscuit
  • Method Details

    • color

      @Nonnull public static String color(@Nonnull String input)
      This is just a simple shortcut for: ChatColor.translateAlternateColorCodes('&', input)
      Parameters:
      input - The String that should be colored
      Returns:
      The colored String
    • alternating

      @Nonnull public static String alternating(@Nonnull String text, ChatColor... colors)
      This method colors the given String in alternating Colors. ChatColors.alternating("Hello World", ChatColor.YELLOW, ChatColor.RED) will yield a String where each letter is yellow or red (in alternating patterns).
      Parameters:
      text - The String that should be colored
      colors - The Colors that should be applied
      Returns:
      The colored String