Color Sign

Discussion in 'Spigot Plugin Development' started by BersamBas, Feb 9, 2018.

  1. So I have a colored sign place down and I'm trying to get the data on the 2nd line without the color.


    Code (Text):
                   Bukkit.broadcastMessage("EXAMS." + (sign.getLine(1)));
    It returns EXAMS.Data

    I tried,
    Code (Text):
                   Bukkit.broadcastMessage(ChatColor.RESET + "EXAMS." + (sign.getLine(1)));
    any solutions?
     
  2. Are you trying to use something in a file?

    if you were using config.yml it would be something like this:
    Code (Text):
    String message = config.getString("NAME OF YOUR STRING");

    Bukkit.broadcastMessage(ChatColor.RESET + message);
     
  3. Code (Text):

     Bukkit.broadcastMessage("EXAMS." + (ChatColor.stirpColor(sign.getLine(1))));
     
     
  4. Thanks
     
    #4 BersamBas, Feb 9, 2018
    Last edited: Feb 9, 2018

Share This Page