void Update() { if (Ruler == 0) { return; } if (MyKing.GetComponent <UnitBehavior>().enemiesBehind()) { RunAway(); } else { Normal(); } }
void Update() { if (Ruler == 0) { return; } if (MyKing.GetComponent <UnitBehavior>().enemiesInfront()) { Charge(); } else { StopCharge(); } }