/// <summary> /// 对单一目标造成物理攻击伤害 /// </summary> /// <param name="atkInfo">攻击方</param> /// <param name="defInfo">防守方</param> public static void CalcAtkDamage(CharacterInfo atkInfo, CharacterInfo defInfo) { //Debug.Log("CalcAtkDamage"); if (atkInfo == null || defInfo == null) { return; } int attackDamage = atkInfo.GetAttr(CharAttr.AttackDamage); if (attackDamage != -1) { defInfo.ChangeAttr(CharAttr.Hp, -attackDamage); //Debug.Log(defInfo.GetAttr(CharAttr.Hp)); } }