|
treimor Newbie
Joined: 14 Feb 2008 Posts: 9
|
Posted: Thu Mar 06, 2008 10:48 am
LUA Request for commands |
Maybe I missed a post somewhere, but i'm in need of some of the lua functionality, and cannot find where to get the basics.
Primarily, what are all the base calls for functions/commands from the cMud scripting language?
I'm curious how to call a cmud variable and command. I notice that zs.func.function_name("various", "parameters", "here") works, but i could not figure out how to reference the variables that are stored or the commands.
I understand there are comparable commands (print) in lua, but for instance if I needed to call echo from zScript, how would i? (first command that came to mind)
Also, if I need to reference a variable I have stored, such as "randomclass.counter" in lua, whats the equivalent lua call?
A simple primer on connecting lua to cmud's native commands / variables would be MUCH appreciated |
|
|
|
Fang Xianfu GURU
Joined: 26 Jan 2004 Posts: 5155 Location: United Kingdom
|
Posted: Thu Mar 06, 2008 10:53 am |
See the help. Basically, zs.cmd.whatever for commands, zs.var.whatever for vars, and zs.sys.whatever for predefined variables.
|
|
|
|
treimor Newbie
Joined: 14 Feb 2008 Posts: 9
|
Posted: Thu Mar 06, 2008 10:59 am |
excellent. Just what I was looking for. I scoured the lua tutorial / help pages and didn't find any of that information you provided. I appreciate your concise and perfect reply
|
|
|
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|