lmao, thanks a lot XD
May end up asking even more questions. So far I like this forum better than Google as far as that is concerned @.@
edit: I actually already have a rather related question! XP Given that example above, how could I retrieve a list of of second-tier level items without their associated values and in the same format (List<String>) as plugin.config.getStringList(path) ? I've tried using the exact same method ie plugin.config.getStringList("FirstTier") and for some reason the .size() returns a 0 or a null or something along those lines. Which kinda throws a monkey wrench in my while or for loop. T.T In fact, I'll throw this in here to show you about what I'm doing, probably some very menial, stupid problem.
if (args[0].equalsIgnoreCase("aip")){
if (sender.isOp()){
plugin.log.info("Step 1");
List<String> userList = plugin.user.createSection("Users").getStringList("Users");
plugin.log.info("Step 2");
int i = 0;
while (i < plugin.user.getStringList("Users").size()){
plugin.log.info("Step 3");
List<String> ipList = plugin.user.getStringList("Users." + userList.size());
sender.sendMessage(ChatColor.AQUA + "IPs for " + userList.get(i) + ":");
for (int x = 0; x < ipList.size(); ++x){
plugin.log.info("Step 4");
sender.sendMessage(ChatColor.BLUE + ipList.get(x));
}
sender.sendMessage(ChatColor.AQUA + "-----------------");
++i;
}
return true;
}
sender.sendMessage(ChatColor.RED + "You must be OP to view others' IPs!");
return true;
}
Anyways, you can see I had it log Step # as a way to see how much of the code works. Step 1 and 2 works, doesn't get to 3. You can probably guess, but plugin.user is structured like:
User:
administrator:
- 127.0.0.1
herobrine:
- 192.168.0.2
So on and so forth.
There is probably so much wrong with just this chunk .-.