static int _m_LoadAssetWithSubAssetsAsync(RealStatePtr L)
        {
            ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);


            UnityEngine.AssetBundle __cl_gen_to_be_invoked = (UnityEngine.AssetBundle)translator.FastGetCSObj(L, 1);


            int __gen_param_count = LuaAPI.lua_gettop(L);

            try {
                if (__gen_param_count == 2 && (LuaAPI.lua_isnil(L, 2) || LuaAPI.lua_type(L, 2) == LuaTypes.LUA_TSTRING))
                {
                    string name = LuaAPI.lua_tostring(L, 2);

                    UnityEngine.AssetBundleRequest __cl_gen_ret = __cl_gen_to_be_invoked.LoadAssetWithSubAssetsAsync(name);
                    translator.Push(L, __cl_gen_ret);



                    return(1);
                }
                if (__gen_param_count == 3 && (LuaAPI.lua_isnil(L, 2) || LuaAPI.lua_type(L, 2) == LuaTypes.LUA_TSTRING) && translator.Assignable <System.Type>(L, 3))
                {
                    string      name = LuaAPI.lua_tostring(L, 2);
                    System.Type type = (System.Type)translator.GetObject(L, 3, typeof(System.Type));

                    UnityEngine.AssetBundleRequest __cl_gen_ret = __cl_gen_to_be_invoked.LoadAssetWithSubAssetsAsync(name, type);
                    translator.Push(L, __cl_gen_ret);



                    return(1);
                }
            } catch (System.Exception __gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + __gen_e));
            }

            return(LuaAPI.luaL_error(L, "invalid arguments to UnityEngine.AssetBundle.LoadAssetWithSubAssetsAsync!"));
        }
        static StackObject *SetResult_5(ILIntepreter __intp, StackObject *__esp, IList <object> __mStack, CLRMethod __method, bool isNewObj)
        {
            ILRuntime.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
            StackObject *ptr_of_this_method;
            StackObject *__ret = ILIntepreter.Minus(__esp, 2);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
            UnityEngine.AssetBundle @ret = (UnityEngine.AssetBundle) typeof(UnityEngine.AssetBundle).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack), (CLR.Utils.Extensions.TypeFlags) 0);
            __intp.Free(ptr_of_this_method);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 2);
            ptr_of_this_method = ILIntepreter.GetObjectAndResolveReference(ptr_of_this_method);
            ET.ETAsyncTaskMethodBuilder <UnityEngine.AssetBundle> instance_of_this_method = (ET.ETAsyncTaskMethodBuilder <UnityEngine.AssetBundle>) typeof(ET.ETAsyncTaskMethodBuilder <UnityEngine.AssetBundle>).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack), (CLR.Utils.Extensions.TypeFlags) 16);

            instance_of_this_method.SetResult(@ret);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 2);
            WriteBackInstance(__domain, ptr_of_this_method, __mStack, ref instance_of_this_method);

            __intp.Free(ptr_of_this_method);
            return(__ret);
        }
Esempio n. 3
0
        public void __Gen_Delegate_Imp2(bool p0, UnityEngine.AssetBundle p1)
        {
#if THREAD_SAFE || HOTFIX_ENABLE
            lock (luaEnv.luaEnvLock)
            {
#endif
            RealStatePtr L = luaEnv.rawL;
            int errFunc    = LuaAPI.pcall_prepare(L, errorFuncRef, luaReference);
            ObjectTranslator translator = luaEnv.translator;
            LuaAPI.lua_pushboolean(L, p0);
            translator.Push(L, p1);

            PCall(L, 2, 0, errFunc);



            LuaAPI.lua_settop(L, errFunc - 1);

#if THREAD_SAFE || HOTFIX_ENABLE
        }
#endif
        }
Esempio n. 4
0
        static int _m_Unload(RealStatePtr L)
        {
            ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);


            UnityEngine.AssetBundle __cl_gen_to_be_invoked = (UnityEngine.AssetBundle)translator.FastGetCSObj(L, 1);


            try {
                {
                    bool unloadAllLoadedObjects = LuaAPI.lua_toboolean(L, 2);

                    __cl_gen_to_be_invoked.Unload(unloadAllLoadedObjects);



                    return(0);
                }
            } catch (System.Exception __gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + __gen_e));
            }
        }
        static StackObject *LoadAssetWithSubAssetsAsync_28(ILIntepreter __intp, StackObject *__esp, IList <object> __mStack, CLRMethod __method, bool isNewObj)
        {
            ILRuntime.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
            StackObject *ptr_of_this_method;
            StackObject *__ret = ILIntepreter.Minus(__esp, 3);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
            System.Type @type = (System.Type) typeof(System.Type).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 2);
            System.String @name = (System.String) typeof(System.String).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 3);
            UnityEngine.AssetBundle instance_of_this_method = (UnityEngine.AssetBundle) typeof(UnityEngine.AssetBundle).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            var result_of_this_method = instance_of_this_method.LoadAssetWithSubAssetsAsync(@name, @type);

            return(ILIntepreter.PushObject(__ret, __mStack, result_of_this_method));
        }
Esempio n. 6
0
        static StackObject *Add_2(ILIntepreter __intp, StackObject *__esp, IList <object> __mStack, CLRMethod __method, bool isNewObj)
        {
            ILRuntime.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
            StackObject *ptr_of_this_method;
            StackObject *__ret = ILIntepreter.Minus(__esp, 3);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
            UnityEngine.AssetBundle @value = (UnityEngine.AssetBundle) typeof(UnityEngine.AssetBundle).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 2);
            System.String @key = (System.String) typeof(System.String).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 3);
            System.Collections.Generic.Dictionary <System.String, UnityEngine.AssetBundle> instance_of_this_method = (System.Collections.Generic.Dictionary <System.String, UnityEngine.AssetBundle>) typeof(System.Collections.Generic.Dictionary <System.String, UnityEngine.AssetBundle>).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            instance_of_this_method.Add(@key, @value);

            return(__ret);
        }
        static int _m_GetAllScenePaths(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);


                UnityEngine.AssetBundle gen_to_be_invoked = (UnityEngine.AssetBundle)translator.FastGetCSObj(L, 1);



                {
                    string[] gen_ret = gen_to_be_invoked.GetAllScenePaths(  );
                    translator.Push(L, gen_ret);



                    return(1);
                }
            } catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }
        }
        static int _m_LoadFromMemory_xlua_st_(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);



                int gen_param_count = LuaAPI.lua_gettop(L);

                if (gen_param_count == 1 && (LuaAPI.lua_isnil(L, 1) || LuaAPI.lua_type(L, 1) == LuaTypes.LUA_TSTRING))
                {
                    byte[] _binary = LuaAPI.lua_tobytes(L, 1);

                    UnityEngine.AssetBundle gen_ret = UnityEngine.AssetBundle.LoadFromMemory(_binary);
                    translator.Push(L, gen_ret);



                    return(1);
                }
                if (gen_param_count == 2 && (LuaAPI.lua_isnil(L, 1) || LuaAPI.lua_type(L, 1) == LuaTypes.LUA_TSTRING) && LuaTypes.LUA_TNUMBER == LuaAPI.lua_type(L, 2))
                {
                    byte[] _binary = LuaAPI.lua_tobytes(L, 1);
                    uint   _crc    = LuaAPI.xlua_touint(L, 2);

                    UnityEngine.AssetBundle gen_ret = UnityEngine.AssetBundle.LoadFromMemory(_binary, _crc);
                    translator.Push(L, gen_ret);



                    return(1);
                }
            } catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }

            return(LuaAPI.luaL_error(L, "invalid arguments to UnityEngine.AssetBundle.LoadFromMemory!"));
        }
Esempio n. 9
0
        static int _m_LoadAllAssetsAsync(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);


                UnityEngine.AssetBundle gen_to_be_invoked = (UnityEngine.AssetBundle)translator.FastGetCSObj(L, 1);


                int gen_param_count = LuaAPI.lua_gettop(L);

                if (gen_param_count == 1)
                {
                    UnityEngine.AssetBundleRequest gen_ret = gen_to_be_invoked.LoadAllAssetsAsync(  );
                    translator.Push(L, gen_ret);



                    return(1);
                }
                if (gen_param_count == 2 && translator.Assignable <System.Type>(L, 2))
                {
                    System.Type _type = (System.Type)translator.GetObject(L, 2, typeof(System.Type));

                    UnityEngine.AssetBundleRequest gen_ret = gen_to_be_invoked.LoadAllAssetsAsync(
                        _type);
                    translator.Push(L, gen_ret);



                    return(1);
                }
            } catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }

            return(LuaAPI.luaL_error(L, "invalid arguments to UnityEngine.AssetBundle.LoadAllAssetsAsync!"));
        }
Esempio n. 10
0
        private static void MenuItem_CreateAssetBundleWithAssetsPath()
        {
            //事前処理。
            {
                BlueBack.AssetLib.Editor.DeleteDirectoryWithAssetsPath.TryDelete("Out/AssetBundleIn");
                BlueBack.AssetLib.Editor.DeleteDirectoryWithAssetsPath.TryDelete("Out/AssetBundleOut");
                BlueBack.AssetLib.Editor.CreateDirectoryWithAssetsPath.Create("Out/AssetBundleIn");
                BlueBack.AssetLib.Editor.CreateDirectoryWithAssetsPath.Create("Out/AssetBundleOut");
                BlueBack.AssetLib.Editor.SaveTextWithAssetsPath.SaveNoBomUtf8("text", "Out/AssetBundleIn/text.txt", BlueBack.AssetLib.LineFeedOption.CRLF);
                BlueBack.AssetLib.Editor.RefreshAssetDatabase.Refresh();
            }

            //CreateAssetBundleWithAssetsPath
            {
                BlueBack.AssetLib.Editor.CreateAssetBundleWithAssetsPath.Create(
                    "Out/AssetBundleOut",
                    new UnityEditor.AssetBundleBuild[] {
                    new UnityEditor.AssetBundleBuild()
                    {
                        assetBundleName    = "test.assetbundle",
                        assetBundleVariant = null,
                        assetNames         = new string[] { "Assets/Out/AssetBundleIn/text.txt" },
                        addressableNames   = null,
                    }
                },
                    UnityEditor.BuildAssetBundleOptions.None,
                    UnityEditor.EditorUserBuildSettings.activeBuildTarget
                    );
                BlueBack.AssetLib.Editor.RefreshAssetDatabase.Refresh();
            }

            //ログ。
            {
                UnityEngine.AssetBundle t_assetbundle = UnityEngine.AssetBundle.LoadFromFile("Assets/Out/AssetBundleOut/test.assetbundle");
                UnityEngine.Debug.Log(t_assetbundle.LoadAsset <UnityEngine.TextAsset>("text").text);
                t_assetbundle.Unload(false);
            }
        }
Esempio n. 11
0
        static int _m_LoadLuaFromAssetBundle(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);


                Casinos.LuaMgr gen_to_be_invoked = (Casinos.LuaMgr)translator.FastGetCSObj(L, 1);



                {
                    UnityEngine.AssetBundle _ab = (UnityEngine.AssetBundle)translator.GetObject(L, 2, typeof(UnityEngine.AssetBundle));

                    gen_to_be_invoked.LoadLuaFromAssetBundle(_ab);



                    return(0);
                }
            } catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }
        }
Esempio n. 12
0
        static int _m_Contains(RealStatePtr L)
        {
            ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);


            UnityEngine.AssetBundle __cl_gen_to_be_invoked = (UnityEngine.AssetBundle)translator.FastGetCSObj(L, 1);


            try {
                {
                    string name = LuaAPI.lua_tostring(L, 2);

                    bool __cl_gen_ret = __cl_gen_to_be_invoked.Contains(name);
                    LuaAPI.lua_pushboolean(L, __cl_gen_ret);



                    return(1);
                }
            } catch (System.Exception __gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + __gen_e));
            }
        }
        static int _m_Awake(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);


                DCET.Model.AssetsLoaderAsync gen_to_be_invoked = (DCET.Model.AssetsLoaderAsync)translator.FastGetCSObj(L, 1);



                {
                    UnityEngine.AssetBundle _ab = (UnityEngine.AssetBundle)translator.GetObject(L, 2, typeof(UnityEngine.AssetBundle));

                    gen_to_be_invoked.Awake(_ab);



                    return(0);
                }
            } catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }
        }
Esempio n. 14
0
        static int _m_GetAssetBundleCache(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);


                AssetBundles.AssetBundleManager gen_to_be_invoked = (AssetBundles.AssetBundleManager)translator.FastGetCSObj(L, 1);



                {
                    string _assetbundleName = LuaAPI.lua_tostring(L, 2);

                    UnityEngine.AssetBundle gen_ret = gen_to_be_invoked.GetAssetBundleCache(_assetbundleName);
                    translator.Push(L, gen_ret);



                    return(1);
                }
            } catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }
        }
        static int _m_UnloadAsync(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);


                UnityEngine.AssetBundle gen_to_be_invoked = (UnityEngine.AssetBundle)translator.FastGetCSObj(L, 1);



                {
                    bool _unloadAllLoadedObjects = LuaAPI.lua_toboolean(L, 2);

                    var gen_ret = gen_to_be_invoked.UnloadAsync(_unloadAllLoadedObjects);
                    translator.Push(L, gen_ret);



                    return(1);
                }
            } catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }
        }
        static StackObject *LoadAsset_21(ILIntepreter __intp, StackObject *__esp, IList <object> __mStack, CLRMethod __method, bool isNewObj)
        {
            ILRuntime.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
            StackObject *ptr_of_this_method;
            StackObject *__ret = ILIntepreter.Minus(__esp, 2);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
            System.String @name = (System.String) typeof(System.String).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 2);
            UnityEngine.AssetBundle instance_of_this_method = (UnityEngine.AssetBundle) typeof(UnityEngine.AssetBundle).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            var result_of_this_method = instance_of_this_method.LoadAsset(@name);

            object obj_result_of_this_method = result_of_this_method;

            if (obj_result_of_this_method is CrossBindingAdaptorType)
            {
                return(ILIntepreter.PushObject(__ret, __mStack, ((CrossBindingAdaptorType)obj_result_of_this_method).ILInstance));
            }
            return(ILIntepreter.PushObject(__ret, __mStack, result_of_this_method));
        }
Esempio n. 17
0
        static int _m_GetAssetBundle(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);


                DCET.Model.ResourcesComponent gen_to_be_invoked = (DCET.Model.ResourcesComponent)translator.FastGetCSObj(L, 1);



                {
                    string _abName = LuaAPI.lua_tostring(L, 2);

                    UnityEngine.AssetBundle gen_ret = gen_to_be_invoked.GetAssetBundle(_abName);
                    translator.Push(L, gen_ret);



                    return(1);
                }
            } catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }
        }
Esempio n. 18
0
        static int _m_ReloadAssets(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);


                FairyGUI.UIPackage gen_to_be_invoked = (FairyGUI.UIPackage)translator.FastGetCSObj(L, 1);


                int gen_param_count = LuaAPI.lua_gettop(L);

                if (gen_param_count == 1)
                {
                    gen_to_be_invoked.ReloadAssets(  );



                    return(0);
                }
                if (gen_param_count == 2 && translator.Assignable <UnityEngine.AssetBundle>(L, 2))
                {
                    UnityEngine.AssetBundle _resBundle = (UnityEngine.AssetBundle)translator.GetObject(L, 2, typeof(UnityEngine.AssetBundle));

                    gen_to_be_invoked.ReloadAssets(
                        _resBundle);



                    return(0);
                }
            } catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }

            return(LuaAPI.luaL_error(L, "invalid arguments to FairyGUI.UIPackage.ReloadAssets!"));
        }
Esempio n. 19
0
 /** ロード。すべて。
  *
  *      a_assetbundle		: アセットバンドル。
  *
  */
 public static UnityEngine.Object[] LoadAll(UnityEngine.AssetBundle a_assetbundle)
 {
     return(a_assetbundle.LoadAllAssets());
 }
Esempio n. 20
0
 public UnityDownloadableBundle(UnityEngine.AssetBundle bundle)
 {
     this.prefix = "Assets/Bundles/" + bundle.name + "/";
     this.bundle = bundle;
     ReadFileList();
 }
Esempio n. 21
0
 public LoadedAssetBundle(UnityEngine.AssetBundle assetBundle)
 {
     this.assetBundle = assetBundle;
 }
Esempio n. 22
0
 protected BaseAssetBundleCache(AssetCacheType AssetType, string AssetPath, UnityEngine.AssetBundleManifest Manifest)
     : base(AssetType, AssetPath)
 {
     this.Manifest_ = Manifest;
     this.Bundle_   = null;
 }
Esempio n. 23
0
 public override void start(System.Object obj)
 {
     UnityEngine.AssetBundle bundle = FResManager.getInstance().getRes(FResID.ASSETBUNDLE) as UnityEngine.AssetBundle;
     m_request = bundle.LoadAssetAsync(m_resPath.ToLower());   // AssetBundle中所有资源名称和路径都是小写
 }
Esempio n. 24
0
 public DependenciesBundle(UnityEngine.AssetBundle assetBundle)
 {
     Bundle   = assetBundle;
     refCount = 1;
 }
Esempio n. 25
0
 internal void SetBundle(UnityEngine.AssetBundle bundle)
 {
     Bundle = bundle;
 }
Esempio n. 26
0
 /** ロード。
  *
  *      a_assetbundle		: アセットバンドル。
  *      a_assetbundle_path	: アセットバンドル内の相対パス。
  *
  */
 public static T Load <T>(UnityEngine.AssetBundle a_assetbundle, string a_assetbundle_path)
     where T : UnityEngine.Object
 {
     return(a_assetbundle.LoadAsset <T>(a_assetbundle_path));
 }
Esempio n. 27
0
 /** ロード。すべて。指定型のみ。
  *
  *      a_assetbundle		: アセットバンドル。
  *
  */
 public static MultiResult <bool, System.Collections.Generic.List <T> > TryLoadAll <T>(UnityEngine.AssetBundle a_assetbundle)
     where T : UnityEngine.Object
 {
                 #pragma warning disable 0168
     try{
         return(new MultiResult <bool, System.Collections.Generic.List <T> >(true, LoadAll <T>(a_assetbundle)));
     }catch (System.Exception t_exception) {
                         #if (DEF_BLUEBACK_ASSETLIB_ASSERT)
         DebugTool.Assert(false, t_exception);
                         #endif
         return(new MultiResult <bool, System.Collections.Generic.List <T> >(false, null));
     }
                 #pragma warning restore
 }
Esempio n. 28
0
        static int _m_AddPackage_xlua_st_(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);



                int gen_param_count = LuaAPI.lua_gettop(L);

                if (gen_param_count == 1 && translator.Assignable <UnityEngine.AssetBundle>(L, 1))
                {
                    UnityEngine.AssetBundle _bundle = (UnityEngine.AssetBundle)translator.GetObject(L, 1, typeof(UnityEngine.AssetBundle));

                    FairyGUI.UIPackage gen_ret = FairyGUI.UIPackage.AddPackage(_bundle);
                    translator.Push(L, gen_ret);



                    return(1);
                }
                if (gen_param_count == 1 && (LuaAPI.lua_isnil(L, 1) || LuaAPI.lua_type(L, 1) == LuaTypes.LUA_TSTRING))
                {
                    string _descFilePath = LuaAPI.lua_tostring(L, 1);

                    FairyGUI.UIPackage gen_ret = FairyGUI.UIPackage.AddPackage(_descFilePath);
                    translator.Push(L, gen_ret);



                    return(1);
                }
                if (gen_param_count == 2 && translator.Assignable <UnityEngine.AssetBundle>(L, 1) && translator.Assignable <UnityEngine.AssetBundle>(L, 2))
                {
                    UnityEngine.AssetBundle _desc = (UnityEngine.AssetBundle)translator.GetObject(L, 1, typeof(UnityEngine.AssetBundle));
                    UnityEngine.AssetBundle _res  = (UnityEngine.AssetBundle)translator.GetObject(L, 2, typeof(UnityEngine.AssetBundle));

                    FairyGUI.UIPackage gen_ret = FairyGUI.UIPackage.AddPackage(_desc, _res);
                    translator.Push(L, gen_ret);



                    return(1);
                }
                if (gen_param_count == 2 && (LuaAPI.lua_isnil(L, 1) || LuaAPI.lua_type(L, 1) == LuaTypes.LUA_TSTRING) && translator.Assignable <FairyGUI.UIPackage.LoadResource>(L, 2))
                {
                    string _assetPath = LuaAPI.lua_tostring(L, 1);
                    FairyGUI.UIPackage.LoadResource _loadFunc = translator.GetDelegate <FairyGUI.UIPackage.LoadResource>(L, 2);

                    FairyGUI.UIPackage gen_ret = FairyGUI.UIPackage.AddPackage(_assetPath, _loadFunc);
                    translator.Push(L, gen_ret);



                    return(1);
                }
                if (gen_param_count == 3 && translator.Assignable <UnityEngine.AssetBundle>(L, 1) && translator.Assignable <UnityEngine.AssetBundle>(L, 2) && (LuaAPI.lua_isnil(L, 3) || LuaAPI.lua_type(L, 3) == LuaTypes.LUA_TSTRING))
                {
                    UnityEngine.AssetBundle _desc = (UnityEngine.AssetBundle)translator.GetObject(L, 1, typeof(UnityEngine.AssetBundle));
                    UnityEngine.AssetBundle _res  = (UnityEngine.AssetBundle)translator.GetObject(L, 2, typeof(UnityEngine.AssetBundle));
                    string _mainAssetName         = LuaAPI.lua_tostring(L, 3);

                    FairyGUI.UIPackage gen_ret = FairyGUI.UIPackage.AddPackage(_desc, _res, _mainAssetName);
                    translator.Push(L, gen_ret);



                    return(1);
                }
                if (gen_param_count == 3 && (LuaAPI.lua_isnil(L, 1) || LuaAPI.lua_type(L, 1) == LuaTypes.LUA_TSTRING) && (LuaAPI.lua_isnil(L, 2) || LuaAPI.lua_type(L, 2) == LuaTypes.LUA_TSTRING) && translator.Assignable <FairyGUI.UIPackage.LoadResource>(L, 3))
                {
                    byte[] _descData        = LuaAPI.lua_tobytes(L, 1);
                    string _assetNamePrefix = LuaAPI.lua_tostring(L, 2);
                    FairyGUI.UIPackage.LoadResource _loadFunc = translator.GetDelegate <FairyGUI.UIPackage.LoadResource>(L, 3);

                    FairyGUI.UIPackage gen_ret = FairyGUI.UIPackage.AddPackage(_descData, _assetNamePrefix, _loadFunc);
                    translator.Push(L, gen_ret);



                    return(1);
                }
                if (gen_param_count == 3 && (LuaAPI.lua_isnil(L, 1) || LuaAPI.lua_type(L, 1) == LuaTypes.LUA_TSTRING) && (LuaAPI.lua_isnil(L, 2) || LuaAPI.lua_type(L, 2) == LuaTypes.LUA_TSTRING) && translator.Assignable <FairyGUI.UIPackage.LoadResourceAsync>(L, 3))
                {
                    byte[] _descData        = LuaAPI.lua_tobytes(L, 1);
                    string _assetNamePrefix = LuaAPI.lua_tostring(L, 2);
                    FairyGUI.UIPackage.LoadResourceAsync _loadFunc = translator.GetDelegate <FairyGUI.UIPackage.LoadResourceAsync>(L, 3);

                    FairyGUI.UIPackage gen_ret = FairyGUI.UIPackage.AddPackage(_descData, _assetNamePrefix, _loadFunc);
                    translator.Push(L, gen_ret);



                    return(1);
                }
            } catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }

            return(LuaAPI.luaL_error(L, "invalid arguments to FairyGUI.UIPackage.AddPackage!"));
        }
 public SceneSectionBundle(UnityEngine.AssetBundle bundle)
 {
     Bundle   = bundle;
     RefCount = 0;
 }