Exemplo n.º 1
0
 private static void AutoLogic()
 {
     if (Blits["misc"].Cast <CheckBox>().CurrentValue)
     {
         var max = EntityManager.Heroes.Enemies.Max(t => TargetSelector.GetPriority(t));
         foreach (
             var enemy in
             EntityManager.Heroes.Enemies.Where(
                 e =>
                 e.IsValidTarget(Q.Range) &&
                 !Blits["grabs" + e.ChampionName.ToLower()].Cast <CheckBox>().CurrentValue)
             .Where(enemy => TargetSelector.GetPriority(enemy) == max))
         {
             QLogic(enemy);
         }
     }
     if (Blits["misc"].Cast <CheckBox>().CurrentValue)
     {
         var enemy = EntityManager.Heroes.Enemies.Find(e => !Blits["grabs" + e.ChampionName.ToLower()].Cast <CheckBox>().CurrentValue&& e.IsValidTarget(Q.Range) &&
                                                       (Q.GetPrediction(e).HitChance == HitChance.Dashing || Q.GetPrediction(e).HitChance == HitChance.Immobile));
         if (enemy != null)
         {
             QLogic(enemy);
         }
     }
     if (Blits["misc"].Cast <CheckBox>().CurrentValue)
     {
         var enemy = EntityManager.Heroes.Enemies.Find(e => e.IsValidTarget(R.Range) && Blitz.GetSpellDamage(e, SpellSlot.R) >= Prediction.Health.GetPrediction(e, R.CastDelay));
         if (enemy != null)
         {
             R.Cast();
         }
     }
 }