diff options
author | Perttu Ahola <celeron55@gmail.com> | 2012-04-13 17:20:43 +0300 |
---|---|---|
committer | Perttu Ahola <celeron55@gmail.com> | 2012-04-13 17:20:48 +0300 |
commit | 24603d7ad3421284246116656abb533098a24631 (patch) | |
tree | dd84204bd3b8c174c935b2e617a85e1ec5883470 /builtin | |
parent | 1eac6ff8ff1bde7d4cceb80147ad2347b871c18d (diff) | |
download | minetest-24603d7ad3421284246116656abb533098a24631.tar.gz minetest-24603d7ad3421284246116656abb533098a24631.tar.bz2 minetest-24603d7ad3421284246116656abb533098a24631.zip |
Fix executing register_chatcommand-defined commands even in the middle of a chat line
Diffstat (limited to 'builtin')
-rw-r--r-- | builtin/chatcommands.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/chatcommands.lua b/builtin/chatcommands.lua index e5d31c6aa..7845c7083 100644 --- a/builtin/chatcommands.lua +++ b/builtin/chatcommands.lua @@ -14,7 +14,7 @@ function minetest.register_chatcommand(cmd, def) end minetest.register_on_chat_message(function(name, message) - local cmd, param = string.match(message, "/([^ ]+) *(.*)") + local cmd, param = string.match(message, "^/([^ ]+) *(.*)") if not param then param = "" end |