System.err.println("[bPermissions] Some silly developer is checking for a blank world!");
return "BLANKWORLD";
}
WorldPermissions perms = wpm.getPermissionSet(world).getWorldPermissions();
Group gr = perms.getGroup(group);
if(gr.contains(valueToGet))
return gr.getValue(valueToGet);
String value = "";
int priority = -1;
for (Permission perm : gr.getEffectivePermissions()) {
if (perm.isTrue()) {
String name = perm.name();
String[] index = name.split("\\.", 3);
if (index.length == 3 && index[0].equals(valueToGet)) {
int pr = Integer.parseInt(index[1]);
if (pr > priority) {
value = index[2];
priority = pr;
}
}
}
}
gr.setValue(valueToGet, value);
return value;
}