Exemplo n.º 1
0
    public override bool OnTick(Attackable target)
    {
        Collider[] enemiesCollider = Physics.OverlapSphere(target.transform.position, range);

        foreach (Collider c in enemiesCollider)
        {
            Attackable attackable = c.gameObject.GetComponent <Unit>();
            if (attackable != null && isValidTarget(attackable))
            {
                effect.Reset();
                attackable.AddEffect(effect);
            }
        }

        return(true);
    }
Exemplo n.º 2
0
 public override void ApplyOnTarget(Attackable target)
 {
     appliedTime = 0f;
     target.AddEffect(this);
 }
Exemplo n.º 3
0
 public override void ApplyOnTarget(Attackable target)
 {
     target.AddEffect(this);
 }