Пример #1
0
 public override void LastHit()
 {
     if (LaneClearMenu.CheckBoxValue("QLH") && Q.IsReady())
     {
         var barrel = BarrelsList.OrderByDescending(b => b.Barrel.CountEnemyMinionsInRange(E.Width)).FirstOrDefault(m => KillableBarrel(m) != null && m.Barrel.CountEnemyMinionsInRange(E.Width) > 0 && (KillableBarrel(m).IsValidTarget(Q.Range) || KillableBarrel(m).IsInRange(user, user.GetAutoAttackRange())));
         if (barrel != null)
         {
             var EkillMinions = EntityManager.MinionsAndMonsters.EnemyMinions.Count(m => BarrelKill(m) && BarrelsList.Any(b => b.Barrel.IsInRange(m, E.Width)) && m.IsValidTarget())
                                >= LaneClearMenu.SliderValue("EKill");
             if (KillableBarrel(barrel).IsValidTarget(user.GetAutoAttackRange()))
             {
                 Orbwalker.ForcedTarget = KillableBarrel(barrel);
             }
             else
             {
                 if (KillableBarrel(barrel).IsValidTarget(Q.Range) && EkillMinions)
                 {
                     Q.Cast(barrel.Barrel);
                 }
             }
         }
         else
         {
             if (LaneClearMenu.CompareSlider("Qmana", user.ManaPercent))
             {
                 foreach (var minion in EntityManager.MinionsAndMonsters.EnemyMinions.OrderByDescending(m => m.Distance(user)).Where(m => m.IsKillable(Q.Range) && Q.WillKill(m) && !BarrelsList.Any(b => b.Barrel.Distance(m) <= E.Width)))
                 {
                     Q.Cast(minion);
                 }
             }
         }
     }
 }
Пример #2
0
 public override void LaneClear()
 {
     Orbwalker.ForcedTarget = null;
     if (Q.IsReady())
     {
         if (E.IsReady() && LaneClearMenu.CheckBoxValue(SpellSlot.E))
         {
             foreach (var minion in EntityManager.MinionsAndMonsters.EnemyMinions.OrderBy(m => m.Health).Where(m => m.IsKillable(E.Range)))
             {
                 var pred = E.GetPrediction(minion);
                 if (EntityManager.MinionsAndMonsters.EnemyMinions.Count(e => e.Distance(pred.CastPosition) <= E.SetSkillshot().Width&& BarrelKill(e)) >= LaneClearMenu.SliderValue("EKill"))
                 {
                     if (BarrelsList.Count(b => b.Barrel.IsInRange(pred.CastPosition, E.SetSkillshot().Width)) < 1 ||
                         (BarrelsList.Count(b => b.Barrel.IsInRange(pred.CastPosition, ConnectionRange)) > 0 && BarrelsList.Count(b => b.Barrel.IsInRange(pred.CastPosition, E.SetSkillshot().Width)) < 1))
                     {
                         E.Cast(pred.CastPosition);
                         return;
                     }
                 }
             }
         }
         if (LaneClearMenu.CheckBoxValue(SpellSlot.Q))
         {
             var barrel = BarrelsList.OrderByDescending(b => b.Barrel.CountEnemyMinionsInRange(E.SetSkillshot().Width)).FirstOrDefault(m => KillableBarrel(m) != null && m.Barrel.CountEnemyMinionsInRange(E.SetSkillshot().Width) > 0 && (KillableBarrel(m).IsValidTarget(Q.Range) || KillableBarrel(m).IsInRange(user, user.GetAutoAttackRange())));
             if (barrel != null)
             {
                 var EkillMinions = EntityManager.MinionsAndMonsters.EnemyMinions.Count(m => BarrelKill(m) && BarrelsList.Any(b => b.Barrel.IsInRange(m, E.SetSkillshot().Width)) && m.IsValidTarget())
                                    >= LaneClearMenu.SliderValue("EKill");
                 var EHitMinions = EntityManager.MinionsAndMonsters.EnemyMinions.Count(m => BarrelsList.Any(b => b.Barrel.IsInRange(m, E.SetSkillshot().Width)) && m.IsValidTarget())
                                   >= LaneClearMenu.SliderValue("EHits");
                 if (KillableBarrel(barrel).IsValidTarget(user.GetAutoAttackRange()))
                 {
                     Orbwalker.ForcedTarget = KillableBarrel(barrel);
                 }
                 else
                 {
                     if (KillableBarrel(barrel).IsValidTarget(Q.Range) && (EkillMinions || EHitMinions))
                     {
                         Q.Cast(barrel.Barrel);
                     }
                 }
             }
             else
             {
                 if (LaneClearMenu.CompareSlider("Qmana", user.ManaPercent))
                 {
                     foreach (var minion in EntityManager.MinionsAndMonsters.EnemyMinions.OrderByDescending(m => m.Distance(user)).Where(m => m.IsKillable(Q.Range) && Q.WillKill(m) && !BarrelsList.Any(b => b.Barrel.Distance(m) <= E.SetSkillshot().Width)))
                     {
                         Q.Cast(minion);
                     }
                 }
             }
         }
     }
 }