private void GetResoures() { // --- 申请多个bundle 里面多个资源 //-- bundle 对应的名字 以下是二个bundle 包 string[] bundle = { "Loading", "Registing" }; string[][] resName = new string[2][]; //第一bundle 包里的资源名字 resName[0] = new string[1] { "Loading.prefab" }; //第二bundle 包里的 // ------- -----------------------------这里面要加后缀 .prefab .png----------TestTwo多个情况不用加---------- resName[1] = new string[1] { "Registing.prefab" }; // button_endless bool[][] singles = new bool[2][]; //第一bundle 包里的资源 是单个资源还是多个资源true 表示单个 singles[0] = new bool[1] { true }; //第二bundle 包里的资源 是单个资源还是多个资源true 表示单个 singles[1] = new bool[1] { true }; AssetRequesetMsg tmpMsg = ObjectPoolManager <AssetRequesetMsg> .Instance.GetFreeObject(); tmpMsg.ChangeEventMsg((ushort)AssetEvent.HunkMutiRes, (ushort)TestShopEvents.GetResources, "UIScence", bundle, resName, singles); Debug.Log(" back Id ==" + (ushort)TestShopEvents.GetResources); SendMsg(tmpMsg); ObjectPoolManager <AssetRequesetMsg> .Instance.ReleaseObject(tmpMsg); }
private void GetResoures() { // --- 申请多个bundle 里面多个资源 //-- bundle 对应的名字 以下是二个bundle 包 string[] bundle = { "Loading", "Registing" }; string[][] resName = new string[2][]; //第一bundle 包里的资源名字 resName[0] = new string[1] { "Loading.prefab" }; resName[1] = new string[1] { "Registing.prefab" }; // resName[2] = new string[1] { "Test.prefab" }; bool[][] singles = new bool[2][]; //第一bundle 包里的资源 是单个资源还是多个资源 true 表示单个 singles[0] = new bool[1] { true }; singles[1] = new bool[1] { true }; singles[2] = new bool[1] { true }; AssetRequesetMsg tmpMsg = ObjectPoolManager <AssetRequesetMsg> .Instance.GetFreeObject(); tmpMsg.ChangeEventMsg((ushort)AssetEvent.HunkMutiRes, (ushort)UIPlayerEvent.TeacherLoading, "UIScence", bundle, resName, singles); SendMsg(tmpMsg); ObjectPoolManager <AssetRequesetMsg> .Instance.ReleaseObject(tmpMsg); }
private void GetResoures() { // --- 申请多个bundle 里面多个资源 //-- bundle 对应的名字 以下是二个bundle 包 string[] bundle = { "Roles" }; string[][] resName = new string[1][]; //第一bundle 包里的资源名字 resName[0] = new string[2] { "Magician_idle.prefab", "Swordman_idle.prefab" }; //第二bundle 包里的 // ------- -----------------------------这里面要加后缀 .prefab .png----------TestTwo多个情况不用加---------- bool[][] singles = new bool[1][]; //第一bundle 包里的资源 是单个资源还是多个资源true 表示单个 singles[0] = new bool[2] { true, true }; //第二bundle 包里的资源 是单个资源还是多个资源true 表示单个 AssetRequesetMsg tmpMsg = ObjectPoolManager <AssetRequesetMsg> .Instance.GetFreeObject(); tmpMsg.ChangeEventMsg((ushort)AssetEvent.HunkMutiRes, (ushort)CharactorChooseRoleEvents.Initial, "ChooseRole", bundle, resName, singles); SendMsg(tmpMsg); ObjectPoolManager <AssetRequesetMsg> .Instance.ReleaseObject(tmpMsg); }
static int ChangeEventMsg(IntPtr L) { try { ToLua.CheckArgsCount(L, 7); AssetRequesetMsg obj = (AssetRequesetMsg)ToLua.CheckObject(L, 1, typeof(AssetRequesetMsg)); ushort arg0 = (ushort)LuaDLL.luaL_checknumber(L, 2); ushort arg1 = (ushort)LuaDLL.luaL_checknumber(L, 3); string arg2 = ToLua.CheckString(L, 4); string[] arg3 = ToLua.CheckStringArray(L, 5); string[][] arg4 = ToLua.CheckObjectArray <string[]>(L, 6); bool[][] arg5 = ToLua.CheckObjectArray <bool[]>(L, 7); obj.ChangeEventMsg(arg0, arg1, arg2, arg3, arg4, arg5); return(0); } catch (Exception e) { return(LuaDLL.toluaL_exception(L, e)); } }