From fa768d6b1301c8ed5806b36ea2671d8c672a572f Mon Sep 17 00:00:00 2001 From: Jesusaves Date: Tue, 20 Mar 2018 08:56:38 -0300 Subject: Stop using getgmlevel() and use is_gm() is_admin() and is_staff(). MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Our four power levels: getgmlevel() → Sponsors, etc. is_staff() → GM 5, Developers, test server, etc. is_gm() → GM 80, Game Master, controls the world is_admin() → GM 99, Administrator, controls the uniserver (pun intended) --- npc/commands/debug-look.txt | 2 +- npc/commands/debug-quest.txt | 2 +- npc/commands/event.txt | 2 +- npc/commands/motd.txt | 2 +- npc/commands/music.txt | 2 +- npc/commands/rate-management.txt | 4 ++-- npc/commands/scheduled-broadcasts.txt | 2 +- npc/commands/super-menu.txt | 10 +++++----- 8 files changed, 13 insertions(+), 13 deletions(-) (limited to 'npc/commands') diff --git a/npc/commands/debug-look.txt b/npc/commands/debug-look.txt index d2abec492..869616e2f 100644 --- a/npc/commands/debug-look.txt +++ b/npc/commands/debug-look.txt @@ -89,7 +89,7 @@ function script BarberDebug { end; OnCall: - if (!debug && !is_dev()) + if (!debug && !is_staff()) { end; } diff --git a/npc/commands/debug-quest.txt b/npc/commands/debug-quest.txt index 7cc3ff110..9c4254d60 100644 --- a/npc/commands/debug-quest.txt +++ b/npc/commands/debug-quest.txt @@ -61,7 +61,7 @@ function script GlobalQuestDebug { end; OnCall: - if (!debug && !is_trusted()) + if (!is_gm()) { end; } diff --git a/npc/commands/event.txt b/npc/commands/event.txt index 4d98dd002..144d51f0d 100644 --- a/npc/commands/event.txt +++ b/npc/commands/event.txt @@ -77,7 +77,7 @@ function script GlobalEventMenu { end; OnCall: - if (!is_evtc()) + if (!is_gm()) { end; } diff --git a/npc/commands/motd.txt b/npc/commands/motd.txt index d00ed5785..363aa1d6d 100644 --- a/npc/commands/motd.txt +++ b/npc/commands/motd.txt @@ -165,7 +165,7 @@ function script MOTDConfig { end; OnCall: - if (!is_dev()) + if (!is_admin()) { end; } diff --git a/npc/commands/music.txt b/npc/commands/music.txt index 144dc059a..68e4e229f 100644 --- a/npc/commands/music.txt +++ b/npc/commands/music.txt @@ -15,7 +15,7 @@ end; OnCall: - if (!is_evtc()) + if (!is_gm()) { end; } diff --git a/npc/commands/rate-management.txt b/npc/commands/rate-management.txt index 670d45d0c..a9cabd13c 100644 --- a/npc/commands/rate-management.txt +++ b/npc/commands/rate-management.txt @@ -20,7 +20,7 @@ } OnCall: - if (!is_evtc()) + if (!is_gm()) { end; } @@ -139,7 +139,7 @@ OnInit: } OnCall: - if (!is_evtc()) + if (!is_gm()) { end; } diff --git a/npc/commands/scheduled-broadcasts.txt b/npc/commands/scheduled-broadcasts.txt index 4ea5a5a71..ca57f8d2f 100644 --- a/npc/commands/scheduled-broadcasts.txt +++ b/npc/commands/scheduled-broadcasts.txt @@ -205,7 +205,7 @@ OnTimer3600000: end; OnCall: - if (!is_evtc() && !is_dev()) + if (!is_gm()) { end; } diff --git a/npc/commands/super-menu.txt b/npc/commands/super-menu.txt index 875111e38..98de5968d 100644 --- a/npc/commands/super-menu.txt +++ b/npc/commands/super-menu.txt @@ -1,7 +1,7 @@ function script SuperMenu { do { - if (debug && !is_dev()) + if (debug && !is_gm()) { GlobalDebugMenu; return; @@ -15,8 +15,8 @@ function script SuperMenu { next; select l("Scheduled broadcasts"), - l("MOTD"), - rif(is_evtc(), l("Event management")), + rif(is_admin(), l("MOTD")), + rif(is_gm(), l("Event management")), l("Debug"); switch (@menu) @@ -36,7 +36,7 @@ function script SuperMenu { OnCall: - if (!debug && !is_dev()) + if (!debug && !is_gm()) { dispbottom l("You do not have the required access privileges to use the Super Menu."); end; @@ -62,5 +62,5 @@ OnPCLoginEvent: OnInit: bindatcmd "super", "@super::OnCall", 80, 99, 0; - bindatcmd "numa", "@super::OnCall", 80, 99, 0; // alias for those used to TMW's @numa + //bindatcmd "numa", "@super::OnCall", 80, 99, 0; // alias for those used to TMW's @numa - none at the moment, iirc } -- cgit v1.2.3-70-g09d2