Does ToLua++ support std::vectors and lists, so I can do stuff like this?:
C++:
class Entity
{
std::list<Entity*> kids
};
Lua:
local child
for child in entity.kids do
--do stuff
end
ToLua++, vectors, and lists
It's quite a workaround, but there appears to be a way to do this here:
http://stackoverflow.com/questions/837772/how-do-i-pass-a-list-of-objects-from-c-to-lua
http://stackoverflow.com/questions/837772/how-do-i-pass-a-list-of-objects-from-c-to-lua
What is the reason you want to make a copy of the std container in Lua? Is the boundary jumping causing a problem when you implement a Lua iterator for the container?
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement