How to change player nametag color.

Discussion in 'Plugin Development' started by JoltTheBolt, May 13, 2022.

  1. Offline

    JoltTheBolt

    I am on 1.8. I want to change player's nametag color. I don't want to use packets. I'll use any other method. I have tried scoreboard but it does not seem to work:
    Code:
    [SYNTAX:JAVA]if (scoreboard.getTeam(p.getName()) == null);
                                {
                                    scoreboard.registerNewTeam(p.getName());
                                    scoreboard.getTeam(p.getName()).addPlayer(p);;
                                }
                                scoreboard.getTeam(p.getName()).setPrefix("ยง4");
    The color is just white.
     

Share This Page