diff --git a/reports.py b/reports.py index f4462e7..a7b2b67 100644 --- a/reports.py +++ b/reports.py @@ -19,7 +19,8 @@ def print_help(sender): msg(sender, " &2/rp tp &eTeleport to report's location & show details") msg(sender, " &2/rp close &eResolve an open report") msg(sender, " &2/rp reopen &eReopen a resolved report") - msg(sender, " &2/rp del &eDelete a report (admin only)") + if sender.hasPermission(rp_permission + ".del"): + msg(sender, " &2/rp del &eDelete a report") def print_list(sender, closed): @@ -197,4 +198,4 @@ def get_reports(closed): def get_reporter(report): return server.getOfflinePlayer(juuid(report["uuid"])) -thread.start_new_thread(reports_reminder, ()) \ No newline at end of file +thread.start_new_thread(reports_reminder, ()) diff --git a/saylol.py b/saylol.py index f1854df..1ccce16 100644 --- a/saylol.py +++ b/saylol.py @@ -95,9 +95,14 @@ def on_lol_command(sender, command, label, args): msg(sender, "&cInvalid number '&e%s&c'" % args[1]) else: - msg(sender, "&a/lol &eSay random message") - msg(sender, "&a/lol list &eList all messages") - msg(sender, "&a/lol id &eSay specific message") - msg(sender, "&a/lol add &eAdd message") - msg(sender, "&a/lol del &eDelete message") + if sender.hasPermission("utils.lol"): + msg(sender, "&a/lol &eSay random message") + msg(sender, "&a/lol list &eList all messages") + if sender.hasPermission("utils.lol.id"): + msg(sender, "&a/lol id &eSay specific message") + if sender.hasPermission("utils.lol.modify"): + msg(sender, "&a/lol add &eAdd message") + msg(sender, "&a/lol del &eDelete message") + else: + noperm(sender) return True