I am working on a cosmetics base for a Minecraft client I'm making. I am using a json file on GitHub (here) with UUIDs of players which I am trying to give cosmetics to, I am trying to put UUIDs into a List which gives those players the item (the names don't do anything, I just have them so I know which id is who). So far I have been able to give the right cosmetic to UUIDs but only hardcoded into the client, I don't want to have to export my workspace every time I need to add someone to the list so I want to try get it to talk to a file online. Here is my current code:
private static List<UUID> players = new ArrayList<UUID>();
public static boolean hasCape(AbstractClientPlayer player) {
players.add(UUID.fromString("288f696b-44d2-4915-a8cc-aa3fd5ea889c")); //jamig
players.add(UUID.fromString("ecad61c5-6a42-4018-b1c7-6c5c19ec1cd1")); //cxplxsok
players.add(UUID.fromString("093f3473-587b-4a2a-b50f-f4a136e9033b")); //DarylHotstuff69
players.add(UUID.fromString("a22ab0ef-18b2-4cc6-ac17-2d9ae40a42ee")); //chfff
for(UUID uuid : players) {
if(player.getUniqueID().equals(uuid)) {
return true;
}
}
return false;
}