mirror of
https://github.com/EngineHub/WorldGuard.git
synced 2024-11-28 05:25:20 +01:00
Changed the /region flag flags list to check permissions.
This commit is contained in:
parent
64b12f8497
commit
beb10e22f2
@ -494,6 +494,23 @@ public static void flag(CommandContext args, WorldGuardPlugin plugin,
|
|||||||
if (list.length() > 0) {
|
if (list.length() > 0) {
|
||||||
list.append(", ");
|
list.append(", ");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (region.isOwner(localPlayer)) {
|
||||||
|
if (!plugin.hasPermission(sender, "worldguard.region.flag.flags."
|
||||||
|
+ flag.getName() + ".owner." + id.toLowerCase())) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
} else if (region.isMember(localPlayer)) {
|
||||||
|
if (!plugin.hasPermission(sender, "worldguard.region.flag.flags."
|
||||||
|
+ flag.getName() + ".member." + id.toLowerCase())) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if (!plugin.hasPermission(sender, "worldguard.region.flag.flags."
|
||||||
|
+ flag.getName() + "." + id.toLowerCase())) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
list.append(flag.getName());
|
list.append(flag.getName());
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user