Ejemplo n.º 1
0
 public void GotoMainScene(FightResultQuitType type, System.Action loadFinishedCallback)
 {
     quitResultType = type;
     UIMgr.instance.CloseLayerBelow(Logic.UI.EUISortingLayer.FlyWord);
     FightController.instance.QuitFight(true, () =>
     {
         Logic.Game.Controller.GameController.instance.LoadUIResources(loadFinishedCallback);
     });
 }
Ejemplo n.º 2
0
        public void CloseDropItemAction(FightResultQuitType type, System.Action <FightResultQuitType> callback)
        {
            if (_isShowQuitAction)
            {
                return;
            }
            _isShowQuitAction = true;
            float time = 0.15f;

            LeanTween.scale(image_light.gameObject, Vector3.zero, time);

            int   count     = tranDropRoot.childCount;
            float shakeTime = 0.2f;

            if (count == 0)
            {
                callback(type);
            }
            else
            {
                for (int i = 0; i < count; i++)
                {
                    Transform  tran  = tranDropRoot.GetChild(i);
                    ScaleShake shake = tran.GetComponent <ScaleShake>();
                    shake.init(1, shakeTime, time, 0.1f, ScaleShake.ScaleShakeType.ScaleShake_Before);
                    CommonFadeToAnimation fadeTo = tran.gameObject.AddComponent <CommonFadeToAnimation>();
                    fadeTo.init(1, 0, time, time);
                    if (i == 0)
                    {
                        fadeTo.onComplete = () => {
                            _isShowQuitAction = false;
                            callback(type);
                        };
                    }
                }
            }
        }
Ejemplo n.º 3
0
 protected virtual void FightResultQuit(FightResultQuitType type)
 {
     FightResultProxy.instance.GotoMainScene(type, FightResultProxy.instance.QuitPvpRaceCallback);
 }
 protected override void FightResultQuit(FightResultQuitType type)
 {
     FightResultProxy.instance.GotoMainScene(type, FightResultProxy.instance.QuitWorldTreeCallback);
 }