Solved Ordening Players in the Tab.

Discussion in 'Spigot Plugin Development' started by JoseGamer_PT, May 29, 2016.

  1. HELLO SPIGOT COMMUNITY!

    I have many server wich use this tab "system":

    [OWNER] TEST
    [ADMIN] TEST2
    [MOD] TEST3
    [PLAYER] TEST4

    in the tab.

    How i can do this?

    THANKS FOR YOUR TIME!
    - JOSE
     
  2. You can do this with Scoreboardteams ;)
     
  3. Make teams:

    AOwner
    BAdmin
    CMod
    DPlayer
     
  4. And?
     
  5. OMG
    Sabes fazer Scoreboard Mas nao sabes aplicar no tab ??
    -.- eu mando por skype!
     
  6. And if the player is a owner add them to that team Same with the others.
    Also take a look: https://www.spigotmc.org/threads/sorting-the-tab-list.38717/

    English please.
     
  7. Code (Text):

    //Admin -> 30
    //DEV -> 25
    //MODO -> 15
    / etc.....
    int level =30;
    String prefix ="§c[Admin]"

    String teamName ="t"+(30-level);
    StringTeamPrefix= prefix;

    if(Bukkit.getScoreboardManager().getMainScoreboard().getTeam(teamName)== null){
      Bukkit.getScoreboardManager().getMainScoreboard().registerNewTeam(teamName);
      Bukkit.getScoreboardManager().getMainScoreboard().getTeam(teamName).setPrefix(TeamPrefix);
      Bukkit.getScoreboardManager().getMainScoreboard().getTeam(teamName).setNameTagVisibility(NameTagVisibility.ALWAYS);
    }
    Bukkit.getScoreboardManager().getMainScoreboard().getTeam(teamName).addEntry(player.getName());
     
    Source: https://www.bukkit.fr/topic/19580-trier-manuellement-la-tablist/?page=2
     
  8. So so bom no scoreboard, nao em teams ;p
     
  9. English please.
     
  10. I am good with scoreboard, but i am not with teams ;p
     
    • Informative Informative x 1