Set prefix before nickname

Is it avalible to set prefix before nickname upon one? If yes, how to do that?

I need that nickname upon a head looks like “[Prefix]Nickname”.

Yep its possible. What context do you want it?

Scoreboard teams? General? Etc?

edit:
Just seen that you said “upon a head” so that means you will need to do it via teams.

Assuming that you want a unquie prefix for every player, it means that a new team needs to be created for each player with that team consisting of just that single player.

Here is the general idea of what you need to do, I don’t know the context and I dont want to just spoonfeed you code, so im writing from memory. So any mistakes I make will still give the idea, but still force you to learn :wink:

Player player;
Team team = Team.builder().name(player.getName() + "pluginid").prefix(Text.builder("[prefix]").build()).build();
team.addMember(player.getTeamRepresentation());
Scoreboard board = player.getScoreboard();
board.registerTeam(team);

I belive you need to register all teams to that scoreboard for all players to see the change.