|
|
||
|
Leigh McRae wrote:TOLUA_API void tolua_pushusertype (lua_State* L, void* value, const char* type)
Class Foo;
Foo* pFoo = new Foo();
tolua_pushusertype( L, pFoo, "Foo" );
Off hand I can't remeber how to determine ownership of pFoo.
Thanks. Ownership detection should not be a problem in my case.
(looks like I'll probably have to design a lighter interface for performance reasons, though).
tolua_pushusertype(L, pFoo, tolua_type_Foo);
Cheers, Andrea.