Exemplo n.º 1
0
 public void setNick(Text.Literal str) {
   nickname = str == null ? null : str + TextColors.RESET;
   save();
   if (str != null) {
     if (getPlayer().isOnline()) {
       getOnlinePlayer()
           .offer(
               getOnlinePlayer().getDisplayNameData().setDisplayName(nickname.replace("&y", "")));
     }
   } else {
     if (getPlayer().isOnline()) {
       getPlayer().getPlayer().setDisplayName(getPlayer().getPlayer().getName());
     }
   }
   JsonConfig data = getPlayerConfig();
   data.set("nick", str);
   data.save(UltimateFileLoader.getPlayerFile(getPlayer()));
 }
Exemplo n.º 2
0
 public File getPlayerFile() {
   return UltimateFileLoader.getPlayerFile(getPlayer());
 }
Exemplo n.º 3
0
 // Configuration
 public JsonConfig getPlayerConfig() {
   return UltimateFileLoader.getPlayerConfig(getPlayer());
 }