// Update is called once per frame public void Update() { if (_paused) { return; } if (SkillStage == eSkillStage.RealEnd) { return; } if (SkillData == null) { SkillStage = eSkillStage.RealEnd; return; } //if (SkillStage == eSkillStage.Sing && SingTime > 0) //{ // //这里判断打断技能 // Actor ac = ActorMgr.Instance.GetActor(Attacker); // if (ac != null && ac.CheckFlag(eFlagType.MoveTarget)) // { // SkillMgr.Instance.CancelSkill(this); // return; // } //} for (int i = _stageList.Count - 1; i >= 0; --i) { ActionStage _curStage = _stageList[i]; _curStage.Update(); if (_curStage.CurrentStage == ActionStage.StageState.Stop) { _curStage = null; _stageList.RemoveAt(i); } } if (_elapseTime <= 0.0f) { if (SkillStage < eSkillStage.End) { StageForward(); } else if (_stageList.Count == 0 && PaddingNum <= 0) { StageForward(); } } _elapseTime -= Time.deltaTime; }
// Update is called once per frame public void Update() { if (_paused) { return; } if (WaitDestroy) { return; } if (BuffData == null) { WaitDestroy = true; return; } if (_end && _stageList.Count == 0) { WaitDestroy = true; return; } for (int i = _stageList.Count - 1; i >= 0; --i) { ActionStage _curStage = _stageList[i]; _curStage.Update(); if (_curStage.CurrentStage == ActionStage.StageState.Stop) { _curStage = null; _stageList.RemoveAt(i); } } if (_end) { return; } //if (ProcessInterface != null && ProcessInterface["OnUpdate"] != null) //{ // ((LuaFunction)ProcessInterface["OnUpdate"]).call(ActorMgr.Instance.GetActor(GetRealAttacker()), ActorMgr.Instance.GetActor(GetAttacker()), ProcessInterface); //} if (LifeTime > 0 && _curLifeTime >= LifeTime) { OnEnd(); return; } _curLifeTime += Time.deltaTime; if (FireTime <= 0f) { return; } if (_elapseTime <= 0f) { OnFire(); } _elapseTime -= Time.deltaTime; }