development/Common/Utility/source/Script/bind_action.cpp
// will return connection action (input connection) which then can be manipulated
// and used
will return connection action (input connection) which then can be manipulated
and used
will return connection action ( input connection ) which then can be manipulated and used
int action(lua_State* L)                                            
    {
        std::string name = luaL_checkstring(L, 1);
        luabind::object g = luabind::globals(L);
        luabind::object lua_yaget = luabind::gettable(g, "yaget");
        InputManager *input = luabind::object_cast<InputManager *>(lua_yaget["input"]);
        void *conUserData = lua_newuserdata(L, sizeof(LuaActionFunctor));  , udata
         new(conUserData)LuaActionFunctor(*input, name);
        luaL_getmetatable(L, "yaget.dispatcher.input");                 , udata, mt
        lua_setmetatable(L, -2);                                        , udata
        return 1;
    }
int action ( lua_State * L ) { std :: string name = luaL_checkstring ( L , 1 ) ; luabind :: object g = luabind :: globals ( L ) ; luabind :: object lua_yaget = luabind :: gettable ( g , " " ) ; InputManager * input = luabind :: object_cast < InputManager * > ( lua_yaget [ " " ] ) ; void * conUserData = lua_newuserdata ( L , sizeof ( LuaActionFunctor ) ) ; new ( conUserData ) LuaActionFunctor ( * input , name ) ; luaL_getmetatable ( L , " " ) ; lua_setmetatable ( L , -2 ) ; return 1 ; }
will return connection action (input connection) which then can be manipulated
and used
will return connection action ( input connection ) which then can be manipulated and used
// name //lua_stackdump(L); // name, udata /*LuaActionFunctor *act =*/ // name, udata, mt // name, udata // return the user data