Im trying to make a top 10 list which you can acces by a command, but I can't figure out how to do this. I want to show a player's name with a number next to it.
Why not use the chat. Code: Player[] otherplayers; //The other 10 players Player player; for (int i = 0; i < 10; i++){ player.sendMessage(otherplayers[i].getName()+" - "+i); }
Code: int i = getConfig().getInt("Somerandompath."+otherplayers[i].getName()); Im not really sure, I wrote that from my head.
I don't get it (maybe I sound dumb now xD) Im trying to get the highest number with names from a file: For example player1: 22 player2: 19 player3: 25 player4: 15 player5: 10 player6: 26 player7: 14 player8: 26 player9: 30 player10: 20 player11: 2 ... and so on. I want to display this in order from low to high.