/// <summary> /// 开始执行SkillBlock /// </summary> private void DoBlockEvent(List <SkillEvent> events) { foreach (var e in events) { SkillEventFactory.Inst.DoEvent(e, this.battle, this, battle.GetHero(skillTargetId)); } }
/// <summary> /// 压入一个指令 /// </summary> /// <param name="cmd"></param> public void EnqueueCmd(Cmd cmd) { cmdCacheList.Add(cmd); // this.InputSate.SetData("OnInput" , cmd); var b = battle.GetHero((int)cmd.Params[0]); b.Input(cmd); }
/// <summary> /// 检测是否结束战斗 /// </summary> /// <returns></returns> private bool CheckBattleEnd() { for (int i = 0; i < 6; i++) { var v = battle.GetHero(i); if (v != null) { if (v.HeroLogic.IsSurvival) { break; } } if (i == 5) { return(true); } } for (int i = 6; i < 12; i++) { var v = battle.GetHero(i); if (v != null) { if (v.HeroLogic.IsSurvival) { break; } } if (i == 11) { return(true); } } return(false); }