title: Replacing UUID of player to player's name
body: <p>I am trying to send a message to the player with his saved friends. These friends are saved in a .yml file, but only the UUIDS of each individual player.</p>
  
  <p>I am then trying to replace the UUID or convert it to the players name when the message is displayed (if that made sense)</p>
  
  <p>CODE:</p>
  
  <pre><code>p.sendMessage("§7▄▄▄▄▄▄▄▄▄▄▄▄§aFriend System - page 1 of 1§7▄▄▄▄▄▄▄▄▄▄▄▄");
  
            int i = 1;
            int length = cfg.getList(p.getUniqueId() + ".Friends").size();
            if (length != 0)
            {
              while (i &lt;= length)
              {
                String uuid = (String)cfg.getList(p.getUniqueId() + ".Friends").get(i - 1);
                ProxiedPlayer p2 = ProxyServer.getInstance().getPlayer(UUID.fromString(uuid));
                if (p2 != null)
                {
                  TextComponent prefix = new TextComponent(Main.prefix);
  
                  TextComponent join = new TextComponent("§a§lONLINE");
  
  
  
                  prefix.addExtra("§9" + p2.getName());
                  prefix.addExtra(" ");
                  prefix.addExtra(join);
  
                  p.sendMessage(prefix);
                }
                else
                {
                  String name = getNamebyUUID(uuid);
                  if (name != null)
                  {
                    p.sendMessage(Main.prefix + "§9" + name + " §c§lOFFLINE");
                    Main.names.put(uuid, name);
  
                  }
                  else if (Main.names.containsKey(uuid))
                  {
                    p.sendMessage(Main.prefix + "§9" + (String)Main.names.get(uuid) + " §8[§c§lOFFLINE§8]");
                  }
                  else
                  {
                    p.sendMessage(Main.prefix + "§cThis is not a valid player!");
                  }
                }
                i++;
              }
            }
            else
            {
              p.sendMessage(Main.prefix + "§cYou don't have any friends.");
            }
          }
          catch (IOException e)
          {
            e.printStackTrace();
          }
        }
  </code></pre>