|
|
@@ -252,23 +252,23 @@ public class AttackController : MonoBehaviour
|
|
|
public float attackInterval;
|
|
|
[DisplayOnly]
|
|
|
public int curDamage;
|
|
|
- [HideInInspector]
|
|
|
+ [DisplayOnly]
|
|
|
public bool canHitFly;
|
|
|
- [HideInInspector]
|
|
|
+ [DisplayOnly]
|
|
|
public int armorPiercing; //´©¼×ÂÊ
|
|
|
- [HideInInspector]
|
|
|
+ [DisplayOnly]
|
|
|
public AttackInfo attackInfo;
|
|
|
- [HideInInspector]
|
|
|
+ [DisplayOnly]
|
|
|
public GameObject addAttackEffect;
|
|
|
- [HideInInspector]
|
|
|
+ [DisplayOnly]
|
|
|
public SpecialSkills skill;
|
|
|
- [HideInInspector]
|
|
|
+ [DisplayOnly]
|
|
|
public GameObject attackEffect;
|
|
|
- [HideInInspector]
|
|
|
+ [DisplayOnly]
|
|
|
public Dictionary<string, GameObject> effects;
|
|
|
- [HideInInspector]
|
|
|
+ [DisplayOnly]
|
|
|
public GameObject effect;
|
|
|
- [HideInInspector]
|
|
|
+ [DisplayOnly]
|
|
|
public float attackDistance;
|
|
|
|
|
|
[Header("¹¥»÷·¶Î§")]
|
|
|
@@ -296,9 +296,11 @@ public class AttackController : MonoBehaviour
|
|
|
|
|
|
[Header("¹¥»÷ģʽ")]
|
|
|
public AttackMethod[] attackMethod;
|
|
|
- [DisplayOnly]
|
|
|
+ [HideInInspector]
|
|
|
public AttackMethod curAttackMethod;
|
|
|
|
|
|
+ private SoldierLevelRecord slr;
|
|
|
+
|
|
|
public void Init()
|
|
|
{
|
|
|
owner = GetComponent<Character>();
|
|
|
@@ -316,6 +318,7 @@ public class AttackController : MonoBehaviour
|
|
|
attackMethod[i].maxAttackDis);
|
|
|
}
|
|
|
}
|
|
|
+ slr = GameManager.instance.GetComponent<SoldierLevelRecord>();
|
|
|
}
|
|
|
|
|
|
private void OnEnable()
|
|
|
@@ -333,6 +336,17 @@ public class AttackController : MonoBehaviour
|
|
|
attackType = curAttackMethod.attackType;
|
|
|
canHitFly = curAttackMethod.canHitFly;
|
|
|
armorPiercing = curAttackMethod.armorPiercing;
|
|
|
+ Demonic dem = owner.GetComponent<Demonic>();
|
|
|
+ if (dem)
|
|
|
+ {
|
|
|
+ for(int i = 0; i < 3; i++)
|
|
|
+ {
|
|
|
+ if (GameManager.curSoldiers[i] == dem.soldierType)
|
|
|
+ {
|
|
|
+ armorPiercing += slr.seb[i].armorPiercing;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
attackInfo = curAttackMethod.attackInfo;
|
|
|
curDamage = attackInfo.damage;
|
|
|
attackTrigger = curAttackMethod.attackTrigger;
|