LuaGlue icon indicating copy to clipboard operation
LuaGlue copied to clipboard

Get c++ object instnce from lua

Open evangelist88 opened this issue 8 years ago • 1 comments

Hi all,

how can I get a c++ object instance from lua without call a "new" inside lua script?

In other words, I need to get a lua object from c++ code and viceversa.

Someone could help me

Thanks a lot

evangelist88 avatar May 25 '17 09:05 evangelist88

you can pass C++ objects into lua easily. If the method or function you bind to lua takes an object, it'll bind it properly. there are plenty of examples in the examples folder. If you could share a more concrete example of what you want to do I can help further.

Tomasu avatar May 25 '17 14:05 Tomasu