public 0.25f; public float DamageForAttack = 1;

public class AiAttackWithinDistance {          public float DistanceForAttack = 30;    public float FrequencyForAttack = 0.25f;    public float DamageForAttack = 1;     private float attackCounter = 0;     void FindPlayerTarget()    {        if (DistanceForAttack != 30) {            if  (transform.position, DistanceForAttack.transform.position) > AttackRange) {                return 0;            }        }         foreach (var unit in RtsGamePlayerObjectsInteractive.Players) {            if (unit == player)                continue;             foreach (var unit in unit.ActiveUnits) {            if  (transform.position, DistanceForAttack.transform.position) > AttackRange) {                     DistanceForAttack = unit.GetComponent ();}            }        }       DistanceForAttack = null;    }

x

Hi!
I'm Ethel!

Would you like to get a custom essay? How about receiving a customized one?

Check it out