lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


In my program there's a C++ object, and corresponding Lua table with it's
data. I want to connect them to each other. Connecting the C++ object to the
table isn't difficult - there's just a field in teh table "__handle" that
stores light user data pointer to the object, but I can't figure a good way
to connect table to the object, since you can't get table handle from lua.

Right now I'm keeping a global table in lua with unique ID for each object
table, and get access via this ID, but this method isn't very good.

If anyone has any ideas on the subject, please reply.

With respect,
Grisha