From be9d9264ae299eb1a0eca44d08a47ac1e75c5d3e Mon Sep 17 00:00:00 2001 From: N0tMyFaultOG Date: Thu, 19 Nov 2020 22:29:44 +0100 Subject: [PATCH] Make use of Permission class in tab completion Plus document a few more permission nodes --- Bukkit/src/main/resources/plugin.yml | 32 +++++++++++++++++++ .../com/plotsquared/core/command/Area.java | 12 +++---- .../com/plotsquared/core/command/Cluster.java | 24 +++++++------- .../plotsquared/core/command/Download.java | 6 ++-- .../com/plotsquared/core/command/Grant.java | 6 ++-- .../com/plotsquared/core/command/Inbox.java | 9 +++--- .../com/plotsquared/core/command/Rate.java | 6 ++-- .../core/command/SchematicCmd.java | 8 ++--- .../com/plotsquared/core/command/Set.java | 24 +++++++------- .../com/plotsquared/core/command/Target.java | 4 +-- .../plotsquared/core/command/Template.java | 7 ++-- .../core/permissions/Permission.java | 29 ++++++++++++++++- 12 files changed, 114 insertions(+), 53 deletions(-) diff --git a/Bukkit/src/main/resources/plugin.yml b/Bukkit/src/main/resources/plugin.yml index a600a5490..fc926be42 100644 --- a/Bukkit/src/main/resources/plugin.yml +++ b/Bukkit/src/main/resources/plugin.yml @@ -95,6 +95,30 @@ permissions: default: false plots.set.flag.other: default: false + plots.set: + default: false + plots.set.biome: + default: false + plots.set.alias: + default: false + plots.set.home: + default: false + plots.set.main: + default: false + plots.set.floor: + default: false + plots.set.air: + default: false + plots.set.all: + default: false + plots.set.border: + default: false + plots.set.wall: + default: false + plots.set.outline: + default: false + plots.set.middle: + default: false plots.set.flag: default: false plots.flag.remove: @@ -107,6 +131,8 @@ permissions: default: false plots.list.shared: default: false + plots.target: + default: false plots.list.world: default: false plots.list.top: @@ -157,6 +183,12 @@ permissions: default: false plots.rate: default: false + plots.template.export: + default: false + plots.template.import: + default: false + plots.template: + default: false plots.admin: default: false diff --git a/Core/src/main/java/com/plotsquared/core/command/Area.java b/Core/src/main/java/com/plotsquared/core/command/Area.java index 0263ead44..836e8eb53 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Area.java +++ b/Core/src/main/java/com/plotsquared/core/command/Area.java @@ -684,25 +684,25 @@ public class Area extends SubCommand { public Collection tab(final PlotPlayer player, final String[] args, final boolean space) { if (args.length == 1) { final List completions = new LinkedList<>(); - if (Permissions.hasPermission(player, "plots.area.create")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_AREA_CREATE)) { completions.add("create"); } - if (Permissions.hasPermission(player, "plots.area.create")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_AREA_CREATE)) { completions.add("single"); } - if (Permissions.hasPermission(player, "plots.area.list")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_AREA_LIST)) { completions.add("list"); } - if (Permissions.hasPermission(player, "plots.area.info")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_AREA_INFO)) { completions.add("info"); } - if (Permissions.hasPermission(player, "plots.area.tp")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_AREA_TP)) { completions.add("tp"); } final List commands = completions.stream().filter(completion -> completion.toLowerCase().startsWith(args[0].toLowerCase())) .map(completion -> new Command(null, true, completion, "", RequiredType.NONE, CommandCategory.ADMINISTRATION) { }).collect(Collectors.toCollection(LinkedList::new)); - if (Permissions.hasPermission(player, "plots.area") && args[0].length() > 0) { + if (Permissions.hasPermission(player, Permission.PERMISSION_AREA) && args[0].length() > 0) { commands.addAll(TabCompletions.completePlayers(args[0], Collections.emptyList())); } return commands; diff --git a/Core/src/main/java/com/plotsquared/core/command/Cluster.java b/Core/src/main/java/com/plotsquared/core/command/Cluster.java index 21e38ea92..6ce2db8d5 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Cluster.java +++ b/Core/src/main/java/com/plotsquared/core/command/Cluster.java @@ -823,43 +823,43 @@ public class Cluster extends SubCommand { public Collection tab(final PlotPlayer player, final String[] args, final boolean space) { if (args.length == 1) { final List completions = new LinkedList<>(); - if (Permissions.hasPermission(player, "plots.cluster.list")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_CLUSTER_LIST)) { completions.add("list"); } - if (Permissions.hasPermission(player, "plots.cluster.create")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_CLUSTER_CREATE)) { completions.add("create"); } - if (Permissions.hasPermission(player, "plots.cluster.delete")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_CLUSTER_DELETE)) { completions.add("delete"); } - if (Permissions.hasPermission(player, "plots.cluster.resize")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_CLUSTER_RESIZE)) { completions.add("resize"); } - if (Permissions.hasPermission(player, "plots.cluster.invite")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_CLUSTER_INVITE)) { completions.add("invite"); } - if (Permissions.hasPermission(player, "plots.cluster.kick")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_CLUSTER_KICK)) { completions.add("kick"); } - if (Permissions.hasPermission(player, "plots.cluster.leave")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_CLUSTER_KICK)) { completions.add("leave"); } - if (Permissions.hasPermission(player, "plots.cluster.members")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_CLUSTER_HELPERS)) { completions.add("members"); } - if (Permissions.hasPermission(player, "plots.cluster.info")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_CLUSTER_INFO)) { completions.add("info"); } - if (Permissions.hasPermission(player, "plots.cluster.tp")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_CLUSTER_TP)) { completions.add("tp"); } - if (Permissions.hasPermission(player, "plots.cluster.sethome")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_CLUSTER_SETHOME)) { completions.add("sethome"); } final List commands = completions.stream().filter(completion -> completion.toLowerCase().startsWith(args[0].toLowerCase())) .map(completion -> new Command(null, true, completion, "", RequiredType.NONE, CommandCategory.ADMINISTRATION) { }).collect(Collectors.toCollection(LinkedList::new)); - if (Permissions.hasPermission(player, "plots.cluster") && args[0].length() > 0) { + if (Permissions.hasPermission(player, Permission.PERMISSION_CLUSTER) && args[0].length() > 0) { commands.addAll(TabCompletions.completePlayers(args[0], Collections.emptyList())); } return commands; diff --git a/Core/src/main/java/com/plotsquared/core/command/Download.java b/Core/src/main/java/com/plotsquared/core/command/Download.java index 457b62eca..ab49b5235 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Download.java +++ b/Core/src/main/java/com/plotsquared/core/command/Download.java @@ -157,16 +157,16 @@ public class Download extends SubCommand { public Collection tab(final PlotPlayer player, final String[] args, final boolean space) { if (args.length == 1) { final List completions = new LinkedList<>(); - if (Permissions.hasPermission(player, "plots.download")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_DOWNLOAD)) { completions.add("schem"); } - if (Permissions.hasPermission(player, "plots.download.world")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_DOWNLOAD_WORLD)) { completions.add("world"); } final List commands = completions.stream().filter(completion -> completion.toLowerCase().startsWith(args[0].toLowerCase())) .map(completion -> new Command(null, true, completion, "", RequiredType.NONE, CommandCategory.ADMINISTRATION) { }).collect(Collectors.toCollection(LinkedList::new)); - if (Permissions.hasPermission(player, "plots.download") && args[0].length() > 0) { + if (Permissions.hasPermission(player, Permission.PERMISSION_DOWNLOAD) && args[0].length() > 0) { commands.addAll(TabCompletions.completePlayers(args[0], Collections.emptyList())); } return commands; diff --git a/Core/src/main/java/com/plotsquared/core/command/Grant.java b/Core/src/main/java/com/plotsquared/core/command/Grant.java index aaea5a68a..3c60c6462 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Grant.java +++ b/Core/src/main/java/com/plotsquared/core/command/Grant.java @@ -144,16 +144,16 @@ public class Grant extends Command { @Override public Collection tab(final PlotPlayer player, final String[] args, final boolean space) { if (args.length == 1) { final List completions = new LinkedList<>(); - if (Permissions.hasPermission(player, "plots.grant.add")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_GRANT_ADD)) { completions.add("add"); } - if (Permissions.hasPermission(player, "plots.grant.check")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_GRANT_CHECK)) { completions.add("check"); } final List commands = completions.stream().filter(completion -> completion.toLowerCase().startsWith(args[0].toLowerCase())) .map(completion -> new Command(null, true, completion, "", RequiredType.NONE, CommandCategory.ADMINISTRATION) { }).collect(Collectors.toCollection(LinkedList::new)); - if (Permissions.hasPermission(player, "plots.grant") && args[0].length() > 0) { + if (Permissions.hasPermission(player, Permission.PERMISSION_GRANT_SINGLE) && args[0].length() > 0) { commands.addAll(TabCompletions.completePlayers(args[0], Collections.emptyList())); } return commands; diff --git a/Core/src/main/java/com/plotsquared/core/command/Inbox.java b/Core/src/main/java/com/plotsquared/core/command/Inbox.java index 5c2235654..3d79e33b0 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Inbox.java +++ b/Core/src/main/java/com/plotsquared/core/command/Inbox.java @@ -28,6 +28,7 @@ package com.plotsquared.core.command; import com.google.inject.TypeLiteral; import com.plotsquared.core.configuration.caption.StaticCaption; import com.plotsquared.core.configuration.caption.TranslatableCaption; +import com.plotsquared.core.permissions.Permission; import com.plotsquared.core.player.MetaDataAccess; import com.plotsquared.core.player.MetaDataKey; import com.plotsquared.core.player.PlotPlayer; @@ -274,19 +275,19 @@ public class Inbox extends SubCommand { public Collection tab(final PlotPlayer player, final String[] args, final boolean space) { if (args.length == 1) { final List completions = new LinkedList<>(); - if (Permissions.hasPermission(player, "plots.inbox.read.owner")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_INBOX_READ_OWNER)) { completions.add("owner"); } - if (Permissions.hasPermission(player, "plots.inbox.read.public")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_INBOX_READ_PUBLIC)) { completions.add("public"); } - if (Permissions.hasPermission(player, "plots.inbox.read.report")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_INBOX_READ_REPORT)) { completions.add("report"); } final List commands = completions.stream().filter(completion -> completion.toLowerCase().startsWith(args[0].toLowerCase())) .map(completion -> new Command(null, true, completion, "", RequiredType.PLAYER, CommandCategory.CHAT) { }).collect(Collectors.toCollection(LinkedList::new)); - if (Permissions.hasPermission(player, "plots.inbox") && args[0].length() > 0) { + if (Permissions.hasPermission(player, Permission.PERMISSION_INBOX) && args[0].length() > 0) { commands.addAll(TabCompletions.completePlayers(args[0], Collections.emptyList())); } return commands; diff --git a/Core/src/main/java/com/plotsquared/core/command/Rate.java b/Core/src/main/java/com/plotsquared/core/command/Rate.java index d40b1239c..583e05921 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Rate.java +++ b/Core/src/main/java/com/plotsquared/core/command/Rate.java @@ -293,16 +293,16 @@ public class Rate extends SubCommand { public Collection tab(final PlotPlayer player, final String[] args, final boolean space) { if (args.length == 1) { final List completions = new LinkedList<>(); - if (Permissions.hasPermission(player, "plots.rate")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_RATE)) { completions.add("1 - 10"); } - if (Permissions.hasPermission(player, "plots.admin.command.purge.ratings")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_ADMIN_COMMAND_PURGE_RATINGS)) { completions.add("purge"); } final List commands = completions.stream().filter(completion -> completion.toLowerCase().startsWith(args[0].toLowerCase())) .map(completion -> new Command(null, true, completion, "", RequiredType.PLAYER, CommandCategory.INFO) { }).collect(Collectors.toCollection(LinkedList::new)); - if (Permissions.hasPermission(player, "plots.rate") && args[0].length() > 0) { + if (Permissions.hasPermission(player, Permission.PERMISSION_RATE) && args[0].length() > 0) { commands.addAll(TabCompletions.completePlayers(args[0], Collections.emptyList())); } return commands; diff --git a/Core/src/main/java/com/plotsquared/core/command/SchematicCmd.java b/Core/src/main/java/com/plotsquared/core/command/SchematicCmd.java index fb636b419..9a38dbc64 100644 --- a/Core/src/main/java/com/plotsquared/core/command/SchematicCmd.java +++ b/Core/src/main/java/com/plotsquared/core/command/SchematicCmd.java @@ -280,19 +280,19 @@ public class SchematicCmd extends SubCommand { public Collection tab(final PlotPlayer player, final String[] args, final boolean space) { if (args.length == 1) { final List completions = new LinkedList<>(); - if (Permissions.hasPermission(player, "plots.schematic.save")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SCHEMATIC_SAVE)) { completions.add("save"); } - if (Permissions.hasPermission(player, "plots.schematic.list")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SCHEMATIC_LIST)) { completions.add("list"); } - if (Permissions.hasPermission(player, "plots.schematic.paste")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SCHEMATIC_PASTE)) { completions.add("paste"); } final List commands = completions.stream().filter(completion -> completion.toLowerCase().startsWith(args[0].toLowerCase())) .map(completion -> new Command(null, true, completion, "", RequiredType.NONE, CommandCategory.ADMINISTRATION) { }).collect(Collectors.toCollection(LinkedList::new)); - if (Permissions.hasPermission(player, "plots.schematic") && args[0].length() > 0) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SCHEMATIC) && args[0].length() > 0) { commands.addAll(TabCompletions.completePlayers(args[0], Collections.emptyList())); } return commands; diff --git a/Core/src/main/java/com/plotsquared/core/command/Set.java b/Core/src/main/java/com/plotsquared/core/command/Set.java index c0d318c5f..97a8fdedf 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Set.java +++ b/Core/src/main/java/com/plotsquared/core/command/Set.java @@ -227,44 +227,44 @@ public class Set extends SubCommand { if (args.length == 1) { final List completions = new LinkedList<>(); - if (Permissions.hasPermission(player, "plots.set.biome")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SET_BIOME)) { completions.add("biome"); } - if (Permissions.hasPermission(player, "plots.set.alias")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SET_ALIAS)) { completions.add("alias"); } - if (Permissions.hasPermission(player, "plots.set.home")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SET_HOME)) { completions.add("home"); } - if (Permissions.hasPermission(player, "plots.set.main")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SET_MAIN)) { completions.add("main"); } - if (Permissions.hasPermission(player, "plots.set.floor")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SET_FLOOR)) { completions.add("floor"); } - if (Permissions.hasPermission(player, "plots.set.air")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SET_AIR)) { completions.add("air"); } - if (Permissions.hasPermission(player, "plots.set.all")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SET_ALL)) { completions.add("all"); } - if (Permissions.hasPermission(player, "plots.set.border")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SET_BORDER)) { completions.add("border"); } - if (Permissions.hasPermission(player, "plots.set.wall")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SET_WALL)) { completions.add("wall"); } - if (Permissions.hasPermission(player, "plots.set.outline")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SET_OUTLINE)) { completions.add("outline"); } - if (Permissions.hasPermission(player, "plots.set.middle")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SET_MIDDLE)) { completions.add("middle"); } final List commands = completions.stream().filter(completion -> completion.toLowerCase().startsWith(args[0].toLowerCase())) .map(completion -> new Command(null, true, completion, "", RequiredType.NONE, CommandCategory.APPEARANCE) { }).collect(Collectors.toCollection(LinkedList::new)); - if (Permissions.hasPermission(player, "plots.set") && args[0].length() > 0) { + if (Permissions.hasPermission(player, Permission.PERMISSION_SET) && args[0].length() > 0) { commands.addAll(TabCompletions.completePlayers(args[0], Collections.emptyList())); } return commands; diff --git a/Core/src/main/java/com/plotsquared/core/command/Target.java b/Core/src/main/java/com/plotsquared/core/command/Target.java index eccb5056a..e8ce8de52 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Target.java +++ b/Core/src/main/java/com/plotsquared/core/command/Target.java @@ -85,10 +85,10 @@ public class Target extends SubCommand { player.sendMessage(TranslatableCaption.of("compass.compass_target")); return true; } - @Override public Collection tab(final PlotPlayer player, String[] args, boolean space) { + @Override public Collection tab(final PlotPlayer player, String[] args, boolean space) { return Stream.of("", "nearest") .filter(value -> value.startsWith(args[0].toLowerCase(Locale.ENGLISH))) - .map(value -> new Command(null, false, value, "plots.target", RequiredType.NONE, null) { + .map(value -> new Command(null, false, value, "plots.target", RequiredType.PLAYER, null) { }).collect(Collectors.toList()); } } diff --git a/Core/src/main/java/com/plotsquared/core/command/Template.java b/Core/src/main/java/com/plotsquared/core/command/Template.java index b511f7f88..a11d380ab 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Template.java +++ b/Core/src/main/java/com/plotsquared/core/command/Template.java @@ -37,6 +37,7 @@ import com.plotsquared.core.configuration.InvalidConfigurationException; import com.plotsquared.core.configuration.Settings; import com.plotsquared.core.configuration.file.YamlConfiguration; import com.plotsquared.core.events.TeleportCause; +import com.plotsquared.core.permissions.Permission; import com.plotsquared.core.player.PlotPlayer; import com.plotsquared.core.plot.PlotArea; import com.plotsquared.core.plot.PlotManager; @@ -272,16 +273,16 @@ public class Template extends SubCommand { @Override public Collection tab(final PlotPlayer player, final String[] args, final boolean space) { if (args.length == 1) { final List completions = new LinkedList<>(); - if (Permissions.hasPermission(player, "plots.template.export")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_TEMPLATE_EXPORT)) { completions.add("export"); } - if (Permissions.hasPermission(player, "plots.template.import")) { + if (Permissions.hasPermission(player, Permission.PERMISSION_TEMPLATE_IMPORT)) { completions.add("import"); } final List commands = completions.stream().filter(completion -> completion.toLowerCase().startsWith(args[0].toLowerCase())) .map(completion -> new Command(null, true, completion, "", RequiredType.NONE, CommandCategory.ADMINISTRATION) { }).collect(Collectors.toCollection(LinkedList::new)); - if (Permissions.hasPermission(player, "plots.template") && args[0].length() > 0) { + if (Permissions.hasPermission(player, Permission.PERMISSION_TEMPLATE) && args[0].length() > 0) { commands.addAll(TabCompletions.completePlayers(args[0], Collections.emptyList())); } return commands; diff --git a/Core/src/main/java/com/plotsquared/core/permissions/Permission.java b/Core/src/main/java/com/plotsquared/core/permissions/Permission.java index 0237ba468..7a9faebe0 100644 --- a/Core/src/main/java/com/plotsquared/core/permissions/Permission.java +++ b/Core/src/main/java/com/plotsquared/core/permissions/Permission.java @@ -84,6 +84,7 @@ public enum Permission { PERMISSION_AREA_LIST("plots.area.list"), PERMISSION_AREA_REGEN("plots.area.regen"), PERMISSION_AREA_TP("plots.area.tp"), + PERMISSION_AREA("plots.area"), PERMISSION_AUTO_MEGA("plots.auto.mega"), PERMISSION_CLAIM_SCHEMATIC("plots.claim.%s"), PERMISSION_ADMIN_COMMAND_SCHEMATIC("plots.admin.command.schematic"), @@ -117,16 +118,36 @@ public enum Permission { PERMISSION_DENY_EVERYONE("plots.deny.everyone"), PERMISSION_ADMIN_COMMAND_DONE("plots.admin.command.done"), PERMISSION_ADMIN_COMMAND_DOWNLOAD("plots.admin.command.download"), + PERMISSION_DOWNLOAD("plots.download"), PERMISSION_DOWNLOAD_WORLD("plots.download.world"), PERMISSION_SET_FLAG_OTHER("plots.set.flag.other"), PERMISSION_SET_FLAG("plots.set.flag"), PERMISSION_SET_FLAG_KEY("plots.set.flag.%s"), PERMISSION_SET_FLAG_KEY_VALUE("plots.set.flag.%s.%s"), + PERMISSION_SET("plots.set"), + PERMISSION_SET_BIOME("plots.set.biome"), + PERMISSION_SET_ALIAS("plots.set.alias"), + PERMISSION_SET_HOME("plots.set.home"), + PERMISSION_SET_MAIN("plots.set.main"), + PERMISSION_SET_FLOOR("plots.set.floor"), + PERMISSION_SET_AIR("plots.set.air"), + PERMISSION_SET_ALL("plots.set.all"), + PERMISSION_SET_BORDER("plots.set.border"), + PERMISSION_SET_WALL("plots.set.wall"), + PERMISSION_SET_OUTLINE("plots.set.outline"), + PERMISSION_SET_MIDDLE("plots.set.middle"), + PERMISSION_TARGET("plots.target"), + PERMISSION_TEMPLATE("plots.template"), + PERMISSION_TEMPLATE_IMPORT("plots.template.import"), + PERMISSION_TEMPLATE_EXPORT("plots.template.import"), PERMISSION_FLAG_REMOVE("plots.flag.remove"), PERMISSION_FLAG_ADD("plots.flag.add"), PERMISSION_FLAG_LIST("plots.flag.list"), PERMISSION_ADMIN_COMMAND_KICK("plots.admin.command.kick"), + PERMISSION_GRANT_SINGLE("plots.grant"), PERMISSION_GRANT("plots.grant.%s"), + PERMISSION_GRANT_ADD("plots.grant.add"), + PERMISSION_GRANT_CHECK("plots.grant.check"), PERMISSION_LIST_FOR_SALE("plots.list.forsale"), PERMISSION_LIST_MINE("plots.list.mine"), PERMISSION_LIST_SHARED("plots.list.shared"), @@ -144,9 +165,14 @@ public enum Permission { PERMISSION_ADMIN_COMMAND_MERGE("plots.admin.command.merge"), PERMISSION_ADMIN_COMMAND_SET_OWNER("plots.admin.command.setowner"), PERMISSION_COMMENT("plots.comment"), + PERMISSION_INBOX("plots.inbox"), + PERMISSION_INBOX_READ_OWNER("plots.inbox.read.owner"), + PERMISSION_INBOX_READ_PUBLIC("plots.inbox.read.public"), + PERMISSION_INBOX_READ_REPORT("plots.inbox.read.report"), PERMISSION_ADMIN_COMMAND_REMOVE("plots.admin.command.remove"), PERMISSION_ADMIN_COMMAND_SAVE("plots.admin.command.save"), PERMISSION_ADMIN_COMMAND_SCHEMATIC_PASTE("plots.admin.command.schematic.paste"), + PERMISSION_SCHEMATIC("plots.schematic.paste"), PERMISSION_SCHEMATIC_PASTE("plots.schematic.paste"), PERMISSION_SCHEMATIC_LIST("plots.schematic.list"), PERMISSION_SCHEMATIC_SAVE("plots.schematic.save"), @@ -171,7 +197,8 @@ public enum Permission { PERMISSION_BACKUP_LOAD("plots.backup.load"), PERMISSION_ADMIN_BACKUP_OTHER("plots.admin.backup.other"), PERMISSION_ADMIN_ALLOW_UNSAFE("plots.admin.unsafe"), - PERMISSION_ADMIN_DEBUG_OTHER("plots.admin.debug.other"); + PERMISSION_ADMIN_DEBUG_OTHER("plots.admin.debug.other"), + PERMISSION_RATE("plots.rate"); // private final String text;