diff options
author | David Walter Seikel | 2014-03-19 21:44:04 +1000 |
---|---|---|
committer | David Walter Seikel | 2014-03-19 21:44:04 +1000 |
commit | 4f788029394d84a839a72c24b637ba557514f2c7 (patch) | |
tree | bd3a417977fd8eb61381a72a09cfc8e63b287d4d | |
parent | An actual working example of a Lua skang module. (diff) | |
download | SledjHamr-4f788029394d84a839a72c24b637ba557514f2c7.zip SledjHamr-4f788029394d84a839a72c24b637ba557514f2c7.tar.gz SledjHamr-4f788029394d84a839a72c24b637ba557514f2c7.tar.bz2 SledjHamr-4f788029394d84a839a72c24b637ba557514f2c7.tar.xz |
"Simplify" test.c. B-)
-rw-r--r-- | ClientHamr/GuiLua/test.c | 20 |
1 files changed, 2 insertions, 18 deletions
diff --git a/ClientHamr/GuiLua/test.c b/ClientHamr/GuiLua/test.c index 2aa2a8d..4427724 100644 --- a/ClientHamr/GuiLua/test.c +++ b/ClientHamr/GuiLua/test.c | |||
@@ -1,20 +1,4 @@ | |||
1 | /* Should be a Lua module, roughly the same as - | 1 | /* Should be a Lua module, roughly the same as test.lua |
2 | |||
3 | local skang = require('skang') | ||
4 | local result = {}; | ||
5 | result.author = 'onefang' | ||
6 | result.version = '0.72 alpha 2004-11-19 16:28:00' | ||
7 | local bar | ||
8 | -- The first argument would be the name of a local variable / method. Which could be accessed via _G? | ||
9 | -- Not sure if we could use a global bar, AND use it directly. | ||
10 | result.bar = skang.newParam('bar', "Required", "Shortcut", "Default", "Help text") | ||
11 | result.func = skang.newCommand('number,data', 'Help Text', function (arg1, arg2) | ||
12 | -- do something here | ||
13 | end) | ||
14 | |||
15 | -- do something here | ||
16 | |||
17 | return result; | ||
18 | 2 | ||
19 | */ | 3 | */ |
20 | 4 | ||
@@ -35,4 +19,4 @@ hyphen and the bit before it. | |||
35 | 19 | ||
36 | Though it seems that chapter 26 is not in the same place? | 20 | Though it seems that chapter 26 is not in the same place? |
37 | 21 | ||
38 | */ \ No newline at end of file | 22 | */ |