Added /me and fixed some bugs in Commands

This commit is contained in:
Cooldude2606
2019-03-02 21:08:22 +00:00
parent 89bd964498
commit f1ecaff4a5
5 changed files with 23 additions and 20 deletions

View File

@@ -1,7 +1,9 @@
local Commands = require 'expcore.commands'
require 'expcore.common_parse'
Commands.new_command('me','Sends an action message in the chat')
:add_param('action',false)
:enable_auto_concat()
:register(function(player,action,raw)
game.print(string.format('%s %s',player.name,action))
game.print(string.format('* %s %s *',player.name,action),player.chat_color)
end)