-- Module: luaconmod -- Version: 0.1.1-pre -- Author: reyalp (at) gmail.com -- Description: -- standalone luacon module -- see luacon.lua for more details -- -- If you load this with -- lua_modules "luacon.lua" -- then you will not be able to access data from other lua modules -- (unless you use IPC) -- -- Changelog: -- 0.1: -- initial release -- require('luacon') -- conventional name et.G_Printf = LuaCon.Printf -- namespace hack: -- don't want to prefix everything with et. for interactive use!$#! table.foreach(et, function (func, value) _G[func] = value; end) -- return 1 if intercepted, 0 if passthrough function et_ConsoleCommand() return LuaCon:DoCommand() -- if you wanted to process other command here you would do something like -- if LuaCon:DoCommand() == 1 then -- return 1 -- elseif (trap_Argv(0) == "myothercommand" ) then -- ... -- end end