Esempio n. 1
0
        public void OnLoaded(string url, Object obj, LOADSTATUS result, object extra)
        {
            if (obj != null)
            {
                curActorObj = Instantiate(obj as GameObject) as GameObject;

                MainPageActorEffectComp comp = curActorObj.GetComponent <MainPageActorEffectComp>();
                if (comp != null)
                {
                    if (comp.effectIds != null)
                    {
                        actorEffectList.AddRange(comp.effectIds);
                        string effPath = null;
                        //for (int j = 0; j < actorEffectList.Count; ++j )
                        if (actorEffectList.Count > curEffectResIndex)
                        {
                            effPath = string.Format("Effect/{0}", actorEffectList[curEffectResIndex]);
                            KHResource.LoadRes(effPath, OnEffectLoadedCallback);
                        }
                    }
                }

                //var aInfo1 = KHDataManager.CONFIG.NinjaDatas[actorId];
                UpdateActorPrefabSet(actorId, curActorCfg, CharacterPos);
            }
        }
Esempio n. 2
0
 public void OnEffectLoadedCallback(string url, Object obj, LOADSTATUS result, object extra)
 {
     if (curActorObj != null && curActorObj.activeSelf && actorEffectList.Count > 0)
     {
         curEffectResIndex++;
         //actorEffectList.RemoveAt(0);
         if (actorEffectList.Count > curEffectResIndex)
         {
             string path = string.Format("Effect/{0}", actorEffectList[curEffectResIndex]);
             KHResource.LoadRes(path, OnEffectLoadedCallback);
         }
     }
 }
Esempio n. 3
0
 public void OnEmptyCallback(string url, Object obj, LOADSTATUS result, object extra)
 {
 }