Skip to content

Commit

Permalink
fixed /list issue
Browse files Browse the repository at this point in the history
  • Loading branch information
cytocracy committed Jul 29, 2021
1 parent ec54a8d commit 2b558e8
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -633,27 +633,24 @@ public boolean onCommand(CommandSender sender, Command cmd, String label, String
String visitors = "";
Integer onlineammount = Bukkit.getOnlinePlayers().size();


for (int i = 0; i < Bukkit.getOnlinePlayers().size(); i++) {

String name = player.getName();
for (Player p : Bukkit.getOnlinePlayers()){
String name = p.getName();

name = name.concat(", ");

if (player.hasPermission("meta.rank.owner")) {
if (p.hasPermission("meta.rank.owner")) {
owners = owners.concat(name);
} else if (player.hasPermission("meta.rank.dev")) {
} else if (p.hasPermission("meta.rank.dev")) {
devs = devs.concat(name);
} else if (player.hasPermission("meta.rank.builders")) {
} else if (p.hasPermission("meta.rank.builders")) {
builders = builders.concat(name);
} else if (player.hasPermission("meta.rank.staff")) {
} else if (p.hasPermission("meta.rank.staff")) {
staff = staff.concat(name);
} else if (player.hasPermission("meta.rank.supporters")) {
} else if (p.hasPermission("meta.rank.supporters")) {
supporters = supporters.concat(name);
} else {
visitors = visitors.concat(name);
}

}

if (owners.length() != 0){
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/plugin.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: ParadisuPlugin
version: 2.6.4
version: 2.6.5
authors: [JakeDaDream, RealInstantRamen, andyinnie, _Kastle, cytocracy]
main: me.jakedadream.ParadisuPlugin.paradisumain
api-version: 1.16
Expand Down

0 comments on commit 2b558e8

Please sign in to comment.