How to access variables from Lua?
2 posters
How to access variables from Lua?
After looking on the Lua tutorial I can see that you can access variables from other C files from inside Lua, but the tutorial only shows how to access variables inside the SIO2 struct, how to I access a variable made inside template.mm?
Thanks!
Thanks!
oioioi- Posts : 136
Join date : 2008-12-02
Location : Norway
Re: How to access variables from Lua?
I think you maybe misunderstood the scripting concept... In a nutshell...
1. You write some API (like SIO2)
2. You make a wrapper to expose all the API to LUA by creating a module
3. Within LUA you call the variables within the module.
If you want variables to be accessible from LUA you need to add them inside the wrapper and regenerate it.
Cheers,
1. You write some API (like SIO2)
2. You make a wrapper to expose all the API to LUA by creating a module
3. Within LUA you call the variables within the module.
If you want variables to be accessible from LUA you need to add them inside the wrapper and regenerate it.
Cheers,
Re: How to access variables from Lua?
Thanks I will try that tomorrow
oioioi- Posts : 136
Join date : 2008-12-02
Location : Norway
Permissions in this forum:
You cannot reply to topics in this forum