Beispiel #1
0
    public override void Shoot(Unit target)
    {
        if (Attack.AttemptShoot())
        {
            Attack.DamageTo(target.Health);
        }

        base.LookAt(target);
    }
Beispiel #2
0
 public override void Shoot(Unit target)
 {
     if (Attack.AttemptShoot())
     {
         var rocket = Instantiate(_rocket, _spawnPositionRocket.position, Quaternion.identity);
         rocket.Target       = target;
         rocket.OnEnterUnit += RocketDamageTo;
     }
     LookAt(target);
 }