static int RegisterAction(lua_State *L) { const char* name = lua_tostring(L, -2); const char* code = lua_tostring(L, -1); ActionManager* actionManager = App::getActionManager(); actionManager->Register(name, code); lua_pop(L, 2); return 0; }