From 90a96ff7df096094ac7562df1ec92ad9b40a2e0e Mon Sep 17 00:00:00 2001 From: Cooldude2606 Date: Mon, 16 Oct 2017 20:45:18 +0100 Subject: [PATCH] More bugs --- locale/ExpGaming-Core/ExpGaming - Command Maker.lua | 3 +-- locale/ExpGaming-Core/ExpGaming - Server Interface.lua | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/locale/ExpGaming-Core/ExpGaming - Command Maker.lua b/locale/ExpGaming-Core/ExpGaming - Command Maker.lua index 1fc71c60..a4419829 100644 --- a/locale/ExpGaming-Core/ExpGaming - Command Maker.lua +++ b/locale/ExpGaming-Core/ExpGaming - Command Maker.lua @@ -51,7 +51,6 @@ local function load_command(command) --is the command all ready loaded if commands.commands[command.name] then return end --start loading command - global.exp_core.commands[command.name] = command debug_write({'COMMAND','LOAD'},command.name) --add command to game debug_write({'COMMAND','LOAD'},command) @@ -106,5 +105,5 @@ function get_commands(rank) end return to_return end -Event.register(Event.soft_init,function() global.exp_core.commands = {} for command_name,command in pairs(Exp_commands) do load_command(command) end end) +Event.register(Event.soft_init,function() global.exp_core.commands = Exp_commands for command_name,command in pairs(Exp_commands) do load_command(command) end end) Event.register(defines.events.on_player_joined_game,function() for command_name,command in pairs(Exp_commands) do load_command(command) end end) \ No newline at end of file diff --git a/locale/ExpGaming-Core/ExpGaming - Server Interface.lua b/locale/ExpGaming-Core/ExpGaming - Server Interface.lua index 63691e83..2f1500e8 100644 --- a/locale/ExpGaming-Core/ExpGaming - Server Interface.lua +++ b/locale/ExpGaming-Core/ExpGaming - Server Interface.lua @@ -31,7 +31,7 @@ end) --runs the preset callback with the uuid define_command('socket',{'server.socket-command-help'},{'uuid','args'},function(player,event,args) if global.exp_core.server.callbacks[args[1]] then - server.queue_callback(global.exp_core.server.callbacks[args[1].fun],{unpack(args,2)},args[1]) + server.queue_callback(global.exp_core.server.callbacks[args[1]].fun,{unpack(args,2)},args[1]) end end) --this is used when changing permission groups when the person does not have permsion to, can also be used to split a large event accross multiple ticks