mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2024-11-22 13:16:45 +01:00
Add plots.admin.area.sudo for permission to commands of the form "/plot <area> <command...>" as well as plots.admin
This commit is contained in:
parent
dc0126b53c
commit
434d219f41
@ -200,7 +200,7 @@ public class MainCommand extends Command {
|
|||||||
PlotArea area = player.getApplicablePlotArea();
|
PlotArea area = player.getApplicablePlotArea();
|
||||||
Plot newPlot = Plot.fromString(area, args[0]);
|
Plot newPlot = Plot.fromString(area, args[0]);
|
||||||
if (newPlot != null && (player instanceof ConsolePlayer || newPlot.getArea()
|
if (newPlot != null && (player instanceof ConsolePlayer || newPlot.getArea()
|
||||||
.equals(area) || Permissions.hasPermission(player, Captions.PERMISSION_ADMIN))
|
.equals(area) || Permissions.hasPermission(player, Captions.PERMISSION_ADMIN) || Permissions.hasPermission(player, Captions.PERMISSION_ADMIN_SUDO_AREA))
|
||||||
&& !newPlot.isDenied(player.getUUID())) {
|
&& !newPlot.isDenied(player.getUUID())) {
|
||||||
Location newLoc = newPlot.getCenter();
|
Location newLoc = newPlot.getCenter();
|
||||||
if (player.canTeleport(newLoc)) {
|
if (player.canTeleport(newLoc)) {
|
||||||
|
@ -46,6 +46,7 @@ public enum Captions {
|
|||||||
//<editor-fold desc="Static Permission">
|
//<editor-fold desc="Static Permission">
|
||||||
PERMISSION_STAR("*", "static.permissions"),
|
PERMISSION_STAR("*", "static.permissions"),
|
||||||
PERMISSION_ADMIN("plots.admin", "static.permissions"),
|
PERMISSION_ADMIN("plots.admin", "static.permissions"),
|
||||||
|
PERMISSION_ADMIN_SUDO_AREA("plots.admin.area.sudo", "static.permissions"),
|
||||||
PERMISSION_PROJECTILE_UNOWNED("plots.projectile.unowned", "static.permissions"),
|
PERMISSION_PROJECTILE_UNOWNED("plots.projectile.unowned", "static.permissions"),
|
||||||
PERMISSION_PROJECTILE_OTHER("plots.projectile.other", "static.permissions"),
|
PERMISSION_PROJECTILE_OTHER("plots.projectile.other", "static.permissions"),
|
||||||
PERMISSION_ADMIN_INTERACT_BLOCKED_CMDS("plots.admin.interact.blockedcommands", "static.permissions"),
|
PERMISSION_ADMIN_INTERACT_BLOCKED_CMDS("plots.admin.interact.blockedcommands", "static.permissions"),
|
||||||
|
Loading…
Reference in New Issue
Block a user