public override void Attack() { var random = new Random().Next(0, EnemyCells.Count); BattleUnitsView.TargetCell = EnemyCells.First(x => x == EnemyCells[random]); ProjectileSpawner.CreateAttackProjectile(base.Attack); }
public void SetTargets() { if (ActiveUnit.Data.AttackType == AttackType.Heal) { AllyCells .Where(x => x.Unit.CurrentHealth < x.Unit.Data.Health) .ToList() .ForEach(x => x.SetTargetIcon(true)); } EnemyCells.ForEach(x => x.SetTargetIcon(true)); }