PlayerDisplayModifier with scoreboard team.

Discussion in 'Spigot Plugin Development' started by Sletonn, Dec 2, 2019 at 1:38 AM.

  1. So basically I'm using this class (that I've updated) : PlayerDisplayModifier
    It allows me to change a player's skin and and it's name (in case if the player is a youtuber and does not want to be focused).

    The problem is I'm using bukkit scoreboard api to color a player's name (I do it with teams obviously). But when they are disguised, their name appears in white.
    I actually have no idea on how to change their name's color once they are disguised (via packet I guess is the only solution).

    I think that I got to give a look at PacketPlayOutScoreboardTeam but I have absolutely no idea what to do.

    Thank you for any kind of help.
    #1 Sletonn, Dec 2, 2019 at 1:38 AM
    Last edited: Dec 2, 2019 at 3:08 AM
  2. Create an offline player with the new custom gameprofile you generated for them. Then add that offline player to the team, instead of the actual player.