//bool isHasPlayerACAudio = false; protected virtual void GetAC() { //判断有没有 攻击动作 没有直接退出 if (!_gameBody.GetDB().animation.HasAnimation(ACName)) { print("没有攻击动作 直接退出!!"); ReSetAll(); return; } //防止 侦听 进入 gamebody _gameBody.IsSFSkill = true; //转向 //收招延迟时间 if (ACOverYCTimes != 0) { _gameBody.GetACMsgOverYC(ACOverYCTimes); } //角色 释放动作 print(" ********************************************************** @@@@@@@@@@@@@@@ acName " + ACName); _gameBody.GetAcMsg(ACName); //if (!isHasPlayerACAudio) //{ // isHasPlayerACAudio = true; //} if (ACAudio) { ACAudio.Play(); } //print(" 临时 提高硬直 "+AddYZ); if (AddYZ != 0) { GetComponent <TempAddValues>().TempAddYZ(AddYZ, AddYZTimes); } //起始效果 提示音 光 提示特效 等 //这里是否有 什么释放动作 慢动作 减速 +硬直 等 地上的前置特效 //起手慢动作 if (qishoudongzuoyanchi != 0) { _gameBody.GetPause(qishoudongzuoyanchi, 0); } //print("_gameBody.GetDB().animation.timeScale: "+ _gameBody.GetDB().animation.timeScale); //_gameBody.GetDB().animation.timeScale = 0; //print("_gameBody.GetDB().animation.timeScale2 : " + _gameBody.GetDB().animation.timeScale); }
// Update is called once per frame void Update() { //print("-----------------------------------------------------------------> "+GlobalTools.GetRandomNum(2)); JiShuQi(); if (GetComponent <RoleDate>().isDie) { init(); return; } if (GetComponent <RoleDate>().isBeHiting) { init(); return; } if (!isFanjiing) { return; } if (isGongjiing && _gameBody.IsAtkOver()) { init(); return; } if (isQhuaing) { if (_gameBody.GetQianhuaOver()) { isQhuaing = false; } return; } if (_gameBody && _gameBody.GetBackUpOver()) { if (isQianHua && !isQianh) { isQianh = true; isQhuaing = true; //qianhua _gameBody.Qianhua(); return; } if (!isGongji) { isGongji = true; //判断是否包含该攻击动作 没有的话 返回 //if (!_gameBody.IsHanAC(FANJI)) //{ // isGongji = false; // isFanjiing = false; // return; //} //判断是否是技能攻击 if (skillAtkName != "") { string[] strArr = skillAtkName.Split('|'); int length = strArr.Length; string _skilName = skillAtkName; if (length > 1) { int i = GlobalTools.GetRandomNum(length); print(" fanjinums i = " + i); _skilName = strArr[i]; } print(" ******************************************反击的 技能名字 " + _skilName); if (GetComponent <AIAirBase>()) { GetComponent <AIAirBase>().GetAtkFSByName(_skilName); } else { GetComponent <AIBase>().GetAtkFSByName(_skilName); } init(); return; } else { _gameBody.GetAtk(FANJI); } if (atkDelayTimes != 0) { _gameBody.GetPause(atkDelayTimes); } isGongjiing = true; //print("-------------------------------------------------------反击"); //是否提高硬直 if (isAddYZ) { GetComponent <RoleDate>().addYZ(addYZNum); isHasHFYZ = false; } } } }