From 67f822eeb04229c06b42297675cfa53bdcb414de Mon Sep 17 00:00:00 2001 From: David Walter Seikel Date: Thu, 27 Mar 2014 00:00:54 +1000 Subject: No need to pass module to skang.thing(), it can work it out. --- ClientHamr/GuiLua/test.lua | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'ClientHamr/GuiLua/test.lua') diff --git a/ClientHamr/GuiLua/test.lua b/ClientHamr/GuiLua/test.lua index 6a38cde..5a5fda1 100644 --- a/ClientHamr/GuiLua/test.lua +++ b/ClientHamr/GuiLua/test.lua @@ -30,11 +30,12 @@ print('code') -- A variable that is private to this module. local foo -skang.thing(_M, 'fooble,f', 'Help text goes here', 1, 'number', '"edit", "The fooble:", 1, 1, 10, 50', true) -skang.thing(_M, 'bar', 'Help text', "Default") +skang.thing('fooble,f', 'Help text goes here', 1, 'number', '"edit", "The fooble:", 1, 1, 10, 50', true) +skang.thing('bar', 'Help text', "Default") +skang.thing('foo') -- We can use inline functions if we don't need the function internally. -skang.thing(_M, 'ffunc', 'Help Text', function (arg1, arg2) +skang.thing('ffunc', 'Help Text', function (arg1, arg2) print('Inside test.ffunc ' .. arg1 .. ', ' .. arg2) end, 'number,string') -- cgit v1.1