From b4106eb988ec8a15f91a20ece7272d3e5267051d Mon Sep 17 00:00:00 2001 From: Aleos Date: Mon, 16 Oct 2017 14:49:39 -0400 Subject: [PATCH] Adjusted script command bindatcmd (#2518) * Fixes #2513. * Defaulted the char-command level to 100. Thanks to @mazvi and @Lemongrass3110! --- doc/script_commands.txt | 1 + src/map/script.cpp | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/doc/script_commands.txt b/doc/script_commands.txt index c1da016db0..5b1fd7f623 100644 --- a/doc/script_commands.txt +++ b/doc/script_commands.txt @@ -7328,6 +7328,7 @@ The commands can also run without an attached rid. This command will bind a NPC event label to an atcommand. Upon execution of the atcommand, the user will invoke the NPC event label. Each atcommand is only allowed one binding. If you rebind, it will override the original binding. +Note: The default level for atcommand is 0 while the default level for charcommand is 100. The following variables are set upon execution: .@atcmd_command$ = The name of the @command used. diff --git a/src/map/script.cpp b/src/map/script.cpp index 4fa680af9e..2515f5c885 100644 --- a/src/map/script.cpp +++ b/src/map/script.cpp @@ -20826,7 +20826,7 @@ BUILDIN_FUNC(freeloop) { BUILDIN_FUNC(bindatcmd) { const char* atcmd; const char* eventName; - int i, level = 0, level2 = 0; + int i, level = 0, level2 = 100; bool create = false; atcmd = script_getstr(st,2);