diff options
author | snowleo <schneeleo@gmail.com> | 2011-06-08 03:30:32 +0200 |
---|---|---|
committer | snowleo <schneeleo@gmail.com> | 2011-06-08 03:30:32 +0200 |
commit | 99268b9d9e4e2398968230959d8ae1b12f8d50cb (patch) | |
tree | 6b7ca22b94a1f6259c65b000f0ab30faa2fb4b7b | |
parent | bcf81d9f0a30b109292815047b0cece2eb0339b9 (diff) | |
download | Essentials-99268b9d9e4e2398968230959d8ae1b12f8d50cb.tar Essentials-99268b9d9e4e2398968230959d8ae1b12f8d50cb.tar.gz Essentials-99268b9d9e4e2398968230959d8ae1b12f8d50cb.tar.lz Essentials-99268b9d9e4e2398968230959d8ae1b12f8d50cb.tar.xz Essentials-99268b9d9e4e2398968230959d8ae1b12f8d50cb.zip |
The sign permissions will be:
essentials.signs.create.*
essentials.signs.use.*
essentials.signs.break.*
-rw-r--r-- | Essentials/src/com/earth2me/essentials/signs/EssentialsSign.java | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/Essentials/src/com/earth2me/essentials/signs/EssentialsSign.java b/Essentials/src/com/earth2me/essentials/signs/EssentialsSign.java index 3d5546e5e..f5a88467c 100644 --- a/Essentials/src/com/earth2me/essentials/signs/EssentialsSign.java +++ b/Essentials/src/com/earth2me/essentials/signs/EssentialsSign.java @@ -31,7 +31,8 @@ public class EssentialsSign final ISign sign = new EventSign(event); sign.setLine(0, String.format(FORMAT_FAIL, this.signName)); final User user = ess.getUser(event.getPlayer()); - if (!user.isAuthorized("essentials.signs." + signName.toLowerCase() + ".create")) + if (!(user.isAuthorized("essentials.signs." + signName.toLowerCase() + ".create") + || user.isAuthorized("essentials.signs.create." + signName.toLowerCase()))) { return false; } @@ -63,7 +64,8 @@ public class EssentialsSign final User user = ess.getUser(event.getPlayer()); try { - return user.isAuthorized("essentials.signs." + signName.toLowerCase() + ".use") + return (user.isAuthorized("essentials.signs." + signName.toLowerCase() + ".use") + || user.isAuthorized("essentials.signs.use." + signName.toLowerCase())) && onSignInteract(sign, user, getUsername(user), ess); } catch (ChargeException ex) @@ -84,7 +86,7 @@ public class EssentialsSign final User user = ess.getUser(event.getPlayer()); try { - return user.isAuthorized("essentials.signs." + signName.toLowerCase() + ".break") + return user.isAuthorized("essentials.signs.break." + signName.toLowerCase()) && onSignBreak(sign, user, getUsername(user), ess); } catch (SignException ex) |