From 438a2f702778d2455c3f1308f5b828a54b0067b3 Mon Sep 17 00:00:00 2001 From: NEMESIS13cz Date: Sun, 1 Nov 2015 14:08:48 +0100 Subject: Added permissions for warn and warnp --- misc.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/misc.py b/misc.py index e5727bc..c6da200 100644 --- a/misc.py +++ b/misc.py @@ -263,7 +263,10 @@ def on_modules_command(sender, command, label, args): amax = 0, helpSubcmd = True) def warn_command(sender, command, label, args): - broadcast(None, " &b= &2&lLag incoming! &r-%s" % sender.getDisplayName()) + if sender.hasPermission("utils.warn"): + broadcast(None, " &b= &2&lLag incoming! &r-%s" % sender.getDisplayName()) + else: + noperm(sender) @simplecommand("warnp", @@ -272,7 +275,10 @@ def warn_command(sender, command, label, args): amax = 0, helpSubcmd = True) def warnp_command(sender, command, label, args): - broadcast(None, " &b= &2&lPossible lag incoming! &r-%s" % sender.getDisplayName()) + if sender.hasPermission("utils.warnp"): + broadcast(None, " &b= &2&lPossible lag incoming! &r-%s" % sender.getDisplayName()) + else: + noperm(sender) -- cgit v1.2.3