Creating nodes in C++ and Lua