Example #1
0
    static int SetActiveLayer(IntPtr L)
    {
        try
        {
            int count = LuaDLL.lua_gettop(L);

            if (count == 3 && TypeChecker.CheckTypes <int, bool>(L, 2))
            {
                LuaFramework.SoundManager obj = (LuaFramework.SoundManager)ToLua.CheckObject(L, 1, typeof(LuaFramework.SoundManager));
                int  arg0 = (int)LuaDLL.lua_tonumber(L, 2);
                bool arg1 = LuaDLL.lua_toboolean(L, 3);
                obj.SetActiveLayer(arg0, arg1);
                return(0);
            }
            else if (count == 3 && TypeChecker.CheckTypes <LuaFramework.SoundManager.SoundType, bool>(L, 2))
            {
                LuaFramework.SoundManager           obj  = (LuaFramework.SoundManager)ToLua.CheckObject(L, 1, typeof(LuaFramework.SoundManager));
                LuaFramework.SoundManager.SoundType arg0 = (LuaFramework.SoundManager.SoundType)ToLua.ToObject(L, 2);
                bool arg1 = LuaDLL.lua_toboolean(L, 3);
                obj.SetActiveLayer(arg0, arg1);
                return(0);
            }
            else
            {
                return(LuaDLL.luaL_throw(L, "invalid arguments to method: LuaFramework.SoundManager.SetActiveLayer"));
            }
        }
        catch (Exception e)
        {
            return(LuaDLL.toluaL_exception(L, e));
        }
    }