Example #1
0
        public CoroutineHandler StartHandler(IEnumerator rIEnum)
        {
            var rCoroutineObj         = UtilTool.CreateGameObject(mCoroutineRootObj, "cotoutine");
            CoroutineHandler rHandler = rCoroutineObj.ReceiveComponent <CoroutineHandler>();

            rHandler.StartHandler(rIEnum);
            return(rHandler);
        }
Example #2
0
 public void Stop(CoroutineHandler rCoroutineHandler)
 {
     if (rCoroutineHandler != null)
     {
         rCoroutineHandler.StopAllCoroutines();
         GameObject.DestroyImmediate(rCoroutineHandler.gameObject);
         rCoroutineHandler.Coroutine = null;
     }
     rCoroutineHandler = null;
 }