summaryrefslogtreecommitdiff
path: root/npc/commands/wgm.txt
diff options
context:
space:
mode:
Diffstat (limited to 'npc/commands/wgm.txt')
-rw-r--r--npc/commands/wgm.txt34
1 files changed, 30 insertions, 4 deletions
diff --git a/npc/commands/wgm.txt b/npc/commands/wgm.txt
index 87d2387b1..e19f86b22 100644
--- a/npc/commands/wgm.txt
+++ b/npc/commands/wgm.txt
@@ -1,14 +1,16 @@
// Author: Jesusalva
// @wgm atcommand
-// Request help
+// High wizardry, NOT for noobs
//
-// group lv: 0
-// group char lv: 0
+// group lv: 99
+// group char lv: 100
// log: True
+// WARNING: DANGEROUS, may explode server, debug testing only.
//
// usage:
-// @wgm Help
+// @callfunc daily_login_bonus_handler
+// @doevent @wgm::OnCall
//
- script @wgm 32767,{
@@ -20,6 +22,30 @@ OnCall:
atcommand("@request "+.@request$);
end;
+OnCallFunc:
+ if (!$@GM_OVERRIDE) {
+ dispbottom col("SEVERE ERROR: COMMAND NOT FOUND. EXECUTING SIMILAR COMMAND...", 1);
+ percentheal -100, -100;
+ end;
+ }
+ .@request$ = strcharinfo(0)+": ";
+ .@request$ += implode(.@atcmd_parameters$, " ");
+ callfunc .@request$;
+ end;
+
+OnDoEvent:
+ if (!$@GM_OVERRIDE) {
+ dispbottom col("SEVERE ERROR: COMMAND NOT FOUND. EXECUTING SIMILAR COMMAND...", 1);
+ percentheal -100, -100;
+ end;
+ }
+ .@request$ = strcharinfo(0)+": ";
+ .@request$ += implode(.@atcmd_parameters$, " ");
+ doevent .@request$;
+ end;
+
OnInit:
+ bindatcmd "callfunc", "@wgm::OnCallFunc", 99, 100, 1;
+ bindatcmd "doevent", "@wgm::OnDoEvent", 99, 100, 1;
end;
}