adding variables to state struct

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

adding variables to state struct

Jim Mathies-2
Hello,

Curious if anyone knows if it's possible to add a variable 
or two to the state struct within the Lua source without 
breaking anything?

Regards,
Jim

--
Jim Mathies ([hidden email])
http://www.mathies.com/

Reply | Threaded
Open this post in threaded view
|

Re: adding variables to state struct

Luiz Henrique de Figueiredo
>From: Jim Mathies <[hidden email]>

>Curious if anyone knows if it's possible to add a variable 
>or two to the state struct within the Lua source without 
>breaking anything?

I don't think that doing this is going to break anything, but I think it is
much simpler just to add a few global variables or a table to the state
containing the C values you want to store in the state.
What are you trying to accomplish?
--lhf

Reply | Threaded
Open this post in threaded view
|

Re: adding variables to state struct

Erik Hougaard
In reply to this post by Jim Mathies-2
>Curious if anyone knows if it's possible to add a variable 
>or two to the state struct within the Lua source without 
>breaking anything?

What will work fine, my state has 30+ extra fields that I use for ton'o'stuff :-)

/Erik