Ejemplo n.º 1
0
        static void DoKillSteal()
        {
            foreach (var enemy in Enemies)
            {
                if (Q.Ready && enemy.IsValidTarget(Q.Data.ChargedMaxRange) && Q.Data.GetDamage(enemy) > enemy.APHealth() && (QData.Active || myHero.ManaPercent >= myMenu.Get <MenuSlider>("ksMPQ").CurrentValue) && myMenu.Get <MenuCheckbox>("ksQ").Checked)
                {
                    CastQ(enemy);
                    return;
                }

                if (W.Ready && enemy.IsValidTarget(W.Data.Range) && W.Data.GetDamage(enemy) > enemy.APHealth() && myHero.ManaPercent >= myMenu.Get <MenuSlider>("ksMPW").CurrentValue&& myMenu.Get <MenuCheckbox>("ksW").Checked)
                {
                    CastW(enemy);
                    return;
                }

                if (E.Ready && enemy.IsValidTarget(E.Data.Range) && E.Data.GetDamage(enemy) > enemy.APHealth() && myHero.ManaPercent >= myMenu.Get <MenuSlider>("ksMPE").CurrentValue&& myMenu.Get <MenuCheckbox>("ksE").Checked)
                {
                    CastE(enemy);
                    return;
                }

                if (Ignite != null && Ignite.IsReady() && enemy.IsValidTarget(Ignite.Range) && myHero.GetSummonerSpellDamage(enemy, Damage.SummonerSpell.Ignite) > enemy.ADHealth() + enemy.HPRegenPerSecond * 2.5f && myMenu.Get <MenuCheckbox>("ksIgnite").Checked)
                {
                    Ignite.Cast(enemy);
                }
            }
        }
Ejemplo n.º 2
0
 private void ks()
 {
     if (Settings.ksE && Settings.ksI && E.IsReady() && Ignite != null && Ignite.IsReady())
     {
         var enemy = EntityManager.Heroes.Enemies.Where(t => t.IsEnemy && !t.IsZombie && !t.IsDead && t.IsValid && !t.IsInvulnerable && t.IsInRange(Player.Instance.Position, Ignite.Range) && t.IsInRange(Player.Instance.Position, E.Range) && DamageLibrary.GetSummonerSpellDamage(Player.Instance, t, DamageLibrary.SummonerSpells.Ignite) + DamageLibrary.GetSpellDamage(Player.Instance, t, SpellSlot.E) > t.Health).FirstOrDefault();
         if (enemy != null)
         {
             E.Cast(enemy);
             Ignite.Cast(enemy);
             return;
         }
     }
     if (Settings.ksE && E.IsReady())
     {
         var enemy = EntityManager.Heroes.Enemies.Where(t => t.IsEnemy && !t.IsZombie && !t.IsDead && t.IsValid && !t.IsInvulnerable && t.IsInRange(Player.Instance.Position, E.Range) && DamageLibrary.GetSpellDamage(Player.Instance, t, SpellSlot.E) > Prediction.Health.GetPrediction(t, 250)).FirstOrDefault();
         if (enemy != null)
         {
             E.Cast(enemy);
         }
     }
     if (Settings.ksI && Ignite != null && Ignite.IsReady())
     {
         var enemy = EntityManager.Heroes.Enemies.Where(t => t.IsEnemy && !t.IsZombie && !t.IsDead && t.IsValid && !t.IsInvulnerable && t.IsInRange(Player.Instance.Position, Ignite.Range) && DamageLibrary.GetSummonerSpellDamage(Player.Instance, t, DamageLibrary.SummonerSpells.Ignite) > t.Health).FirstOrDefault();
         if (enemy != null)
         {
             Ignite.Cast(enemy);
         }
     }
 }
Ejemplo n.º 3
0
        public static void ExecuteCombo()
        {
            var target   = TargetSelector.GetTarget(SpellsManager.E.Range, DamageType.Magical);
            var FirstMob = EntityManager.MinionsAndMonsters.GetLaneMinions().Where(x => !x.IsDead && x.IsValidTarget(SpellsManager.W.Range)).OrderBy(x => x.Distance(myhero)).First();

            if ((target == null) || target.IsInvulnerable)
            {
                return;
            }

            if (ComboMenu["E"].Cast <CheckBox>().CurrentValue&& target.IsValidTarget(SpellsManager.E.Range) && SpellsManager.E.IsReady())
            {
                if (SpellsManager.E.GetPrediction(target).HitChance >= HitChance.High)
                {
                    SpellsManager.E.Cast(SpellsManager.E.GetPrediction(target).CastPosition);
                }
            }

            if (ComboMenu["Q"].Cast <CheckBox>().CurrentValue&& target.IsValidTarget(SpellsManager.Q.Range) && SpellsManager.Q.IsReady())
            {
                if (SpellsManager.Q.GetPrediction(target).HitChance >= HitChance.High)
                {
                    SpellsManager.Q.Cast(SpellsManager.Q.GetPrediction(target).CastPosition);
                }
            }

            if ((SpellsManager.W.IsReady() && ComboMenu["W"].Cast <CheckBox>().CurrentValue&& target.IsValidTarget(SpellsManager.W.Range) && myhero.CountEnemyMinionsInRange(myhero.Distance(target)) < myhero.Distance(FirstMob)) || (FirstMob == null && target.IsValidTarget(SpellsManager.W.Range) && SpellsManager.W.IsReady() && ComboMenu["W"].Cast <CheckBox>().CurrentValue))
            {
                SpellsManager.W.Cast();
            }

            if (ComboMenu["R"].Cast <CheckBox>().CurrentValue&& ComboMenu["RDirection"].Cast <ComboBox>().CurrentValue == 0 && SpellsManager.R.IsReady() && target.IsValidTarget(SpellsManager.E.Range))
            {
                var Rpos = Player.Instance.ServerPosition.Extend(target.ServerPosition, SpellsManager.R.Range);

                SpellsManager.R.Cast(Rpos.To3DWorld());
            }

            if (ComboMenu["R"].Cast <CheckBox>().CurrentValue&& ComboMenu["RDirection"].Cast <ComboBox>().CurrentValue == 1 && SpellsManager.R.IsReady() && target.IsValidTarget(SpellsManager.E.Range))
            {
                var Rpos = Player.Instance.ServerPosition.Extend(Game.CursorPos, SpellsManager.R.Range);
                SpellsManager.R.Cast(Rpos.To3DWorld());
            }

            var Summ = TargetSelector.GetTarget(Ignite.Range, DamageType.Mixed);

            if ((Summ == null) || Summ.IsInvulnerable)
            {
                return;
            }
            //Ignite
            if (ComboMenu["Ignite"].Cast <CheckBox>().CurrentValue)
            {
                if (Player.Instance.CountEnemyChampionsInRange(600) >= 1 && Ignite.IsReady() && Ignite.IsLearned && Summ.IsValidTarget(Ignite.Range) && target.HealthPercent <= ComboMenu["IgniteHealth"].Cast <Slider>().CurrentValue&& target.Health > target.GetRealDamage())
                {
                    Ignite.Cast(Summ);
                }
            }
        }
Ejemplo n.º 4
0
        public override void Execute()
        {
            var target = TargetSelector.GetTarget(R.Range, DamageType.Mixed);

            if (target == null)
            {
                return;
            }
            if (Orbwalker.IsAutoAttacking && W.IsReady() && Settings.UseW)
            {
                W.Cast();
            }
            if (Settings.UseQ && Q.IsReady())
            {
                var minion =
                    EntityManager.MinionsAndMonsters.CombinedAttackable.Where(
                        m => Q.GetRealDamage(m) > m.Health && m.Distance(target) < Player.Instance.Distance(target) && Q.IsInRange(m)).OrderBy(m => m.Distance(target)).FirstOrDefault();
                if (minion.IsValidTarget())
                {
                    Q.Cast(target);
                }
                if (!Player.Instance.IsInAutoAttackRange(target) && Player.Instance.IsInRange(target, Q.Range))
                {
                    if (!W.IsOnCooldown && Settings.UseW)
                    {
                        W.Cast();
                    }
                    Q.Cast(target);
                }
            }
            if (Settings.UseE && E.IsReady() && Player.Instance.IsInRange(target, E.Range))
            {
                if (!W.IsOnCooldown && Settings.UseW)
                {
                    W.Cast();
                }
                E.Cast(target);
            }
            if (Settings.UseR && R.IsReady() && Player.Instance.IsInRange(target, R.Range) && Player.Instance.HasBuff("ireliatranscendentbladesspell"))
            {
                var minion =
                    EntityManager.MinionsAndMonsters.CombinedAttackable.Where(
                        m => R.GetRealDamage(m) + Q.GetRealDamage(m) > m.Health && R.GetRealDamage(m) < m.Health && m.Distance(target) < Player.Instance.Distance(target) && Q.IsInRange(m)).OrderBy(m => m.Distance(target)).FirstOrDefault();
                if (minion.IsValidTarget())
                {
                    R.Cast(minion);
                }
                else
                {
                    R.Cast(target);
                }
            }
            if ((Ignite.Slot != SpellSlot.Unknown) && Settings.UseF && Ignite.IsReady() && Ignite.GetRealDamage(target) > target.Health)
            {
                Ignite.Cast(target);
            }
        }
Ejemplo n.º 5
0
        // normal Combo Q E W
        public static void ExecuteCombo()
        {
            var target = TargetSelector.GetTarget(SpellsManager.Q.Range, DamageType.Magical);


            if ((target == null) || target.IsInvulnerable)
            {
                return;
            }


            if (ComboMenu["Q"].Cast <CheckBox>().CurrentValue&& target.IsValidTarget(SpellsManager.Q.Range) && SpellsManager.Q.IsReady())
            {
                SpellsManager.Q.Cast(target);
            }

            if (SpellsManager.W.IsReady() && ComboMenu["W"].Cast <CheckBox>().CurrentValue&& myhero.Distance(target) < myhero.AttackRange + 150 && !target.IsDead)
            {
                SpellsManager.W.Cast();
            }

            if (ComboMenu["R"].Cast <CheckBox>().CurrentValue&& SpellsManager.R.IsReady() && target.IsValidTarget(SpellsManager.R.Range) && Player.Instance.Spellbook.GetSpell(SpellSlot.R).Ammo >= ComboMenu["RAmmo"].Cast <Slider>().CurrentValue&& lastRCast + 3000 < Environment.TickCount)
            {
                var prediction = SpellsManager.R.GetPrediction(target);
                SpellsManager.R.Cast(SpellsManager.R.GetPrediction(target).CastPosition);
                lastRCast = Environment.TickCount;
            }

            var Summ = TargetSelector.GetTarget(Ignite.Range, DamageType.Mixed);

            if ((Summ == null) || Summ.IsInvulnerable)
            {
                return;
            }
            //Ignite
            if (ComboMenu["Ignite"].Cast <CheckBox>().CurrentValue)
            {
                if (Player.Instance.CountEnemyChampionsInRange(600) >= 1 && Ignite.IsReady() && Ignite.IsLearned && Summ.IsValidTarget(Ignite.Range) && target.HealthPercent <= ComboMenu["IgniteHealth"].Cast <Slider>().CurrentValue&& target.Health > target.GetRealDamage())
                {
                    Ignite.Cast(Summ);
                }
            }


            if (ComboMenu["Hextech"].Cast <CheckBox>().CurrentValue&& (KillStealMenu["HextechKS"].Cast <CheckBox>().CurrentValue == false || myhero.CountAllyChampionsInRange(800) >= 1))
            {
                if (Hextech.IsOwned() && Hextech.IsReady() && target.IsValidTarget(700))
                {
                    Hextech.Cast(target);
                }
                if (Bilgewater.IsOwned() && Bilgewater.IsReady() && target.IsValidTarget(700))
                {
                    Bilgewater.Cast(target);
                }
            }
        }
Ejemplo n.º 6
0
 private static void OnUpdate(EventArgs args)
 {
     if (_eMenu["flashe"].Cast <KeyBind>().CurrentValue)
     {
         FlashE();
     }
     SkinChange();
     if (MiscMenu["randuin"].Cast <CheckBox>().CurrentValue)
     {
         RanduinU();
     }
     HighestAuthority();
     if (MiscMenu["lvlup"].Cast <CheckBox>().CurrentValue)
     {
         LevelUpSpells();
     }
     {
         if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo))
         {
             Combo();
         }
     }
     if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.LaneClear))
     {
         LaneClear();
     }
     if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Flee))
     {
         Flee();
     }
     if (_eMenu["e"].Cast <KeyBind>().CurrentValue)
     {
         Ee();
     }
     if (_ultMenu["ult"].Cast <KeyBind>().CurrentValue)
     {
         Ult();
     }
     if (!_comboMenu["useignite"].Cast <CheckBox>().CurrentValue ||
         !Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo))
     {
         return;
     }
     foreach (
         var source in
         ObjectManager.Get <AIHeroClient>()
         .Where(
             a =>
             a.IsEnemy && a.IsValidTarget(Ignite.Range) &&
             a.Health < 50 + 20 * Shen.Level - (a.HPRegenRate / 5 * 3)))
     {
         Ignite.Cast(source);
         return;
     }
 }
Ejemplo n.º 7
0
        public static void IgniteLogic()
        {
            var target = TargetSelector.GetTarget(Ignite.Range, TargetSelector.DamageType.True);

            if (Ignite != null && target != null)
            {
                if (Calculation.getDmgPred(target, (Ignite.Range - target.Distance(Cassio.Player)) / target.MovementSpeed, true) > target.Health)
                {
                    Ignite.Cast(target);
                }
            }
        }
Ejemplo n.º 8
0
        protected override void Combo()
        {
            if (Target != null)
            {
                var bestCombo = GetBestCombo(Target);
                if (ComboMenu.CheckBox("Ignite") && Ignite.IsReady && bestCombo.IsKillable)
                {
                    Ignite.Cast(Target);
                }
                if (ComboMenu.Slider("E") > 0 && !MyHero.InAutoAttackRange(Target))
                {
                    if (ComboMenu.Slider("E") != 2 || bestCombo.IsKillable)
                    {
                        var path = Prediction.Position.GetRealPath(Target);
                        if (path.Any() && path.Last().Distance(MyHero, true) > Target.GetDistanceSqr(MyHero))
                        {
                            E.Cast(Target);
                        }
                    }
                }
                if (ComboMenu.CheckBox("W"))
                {
                    W.Cast(Target);
                }
                if (ComboMenu.CheckBox("Q"))
                {
                    CastQ(Target);
                }
                if (ComboMenu.CheckBox("QR"))
                {
                    if (bestCombo.IsKillable)
                    {
                        GapClose(Target);
                    }
                }
                if (ComboMenu.Slider("R") > 0)
                {
                    switch (ComboMenu.Slider("R"))
                    {
                    case 1:
                        CastR(Target);
                        break;

                    case 2:
                        R.Cast(Target);
                        break;
                    }
                }
            }
            base.Combo();
        }
Ejemplo n.º 9
0
        private static void Combo()
        {
            var target = TargetSelector.GetTarget(1000, DamageType.Magical, Player.Instance.Position);

            if (target != null && target.ValidTarget(1000))
            {
                if (check(combo, "CQ") && DemSpells.Q.CanCast(target) && DemSpells.Q.Cast())
                {
                    return;
                }

                CastW();

                if (check(combo, "CE") && DemSpells.W.CanCast(target))
                {
                    if (comb(combo, "EMode") == 0)
                    {
                        DemSpells.E.CastMinimumHitchance(target, slider(misc, "EPred"));
                    }
                    else
                    {
                        DemSpells.E.Cast(target.Position);
                    }
                }

                if (check(combo, "CR") && DemSpells.R.CanCast(target) && TotalRDamage(target) > (target.Health + (target.FlatHPRegenMod * 10)))
                {
                    if (DemSpells.E.IsReady() && EDamage(target) > target.Health)
                    {
                        return;
                    }

                    DemSpells.R.Cast(target);
                }

                if (check(combo, "Cignt") && Ignite.CanCast(target) && target.Health > ComboDamage(target) &&
                    myhero.GetSummonerSpellDamage(target, DamageLibrary.SummonerSpells.Ignite) > target.Health && (TotalRDamage(target) < target.Health &&
                                                                                                                   !target.HasBuff("mordekaisercotgpetbuff2")))
                {
                    if (target.Distance(myhero.Position) < (DemSpells.E.Range / 2))
                    {
                        return;
                    }

                    else
                    {
                        Ignite.Cast(target);
                    }
                }
            }
        }
Ejemplo n.º 10
0
 private static void Game_OnTick(EventArgs args)
 {
     SkinChange();
     Killsteal();
     if (MiscMenu["lvlup"].Cast <CheckBox>().CurrentValue)
     {
         LevelUpSpells();
     }
     {
         if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo))
         {
             Combo();
         }
         if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Harass))
         {
             Harass();
         }
         if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.LaneClear))
         {
             LaneJungleClearA.LaneClear();
         }
         if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.LastHit))
         {
             LastHitA.LastHitB();
         }
         if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Flee))
         {
             Flee();
         }
         {
             {
                 if (!ComboMenu["useignite"].Cast <CheckBox>().CurrentValue ||
                     !Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo))
                 {
                     return;
                 }
                 foreach (
                     var source in
                     ObjectManager.Get <AIHeroClient>()
                     .Where(
                         a =>
                         a.IsEnemy && a.IsValidTarget(Ignite.Range) &&
                         a.Health < 50 + 20 * Kassawin.Level - a.HPRegenRate / 5 * 3))
                 {
                     Ignite.Cast(source);
                     return;
                 }
             }
         }
     }
 }
Ejemplo n.º 11
0
        private static void EQFlashBurst(AIHeroClient target)
        {
            if (MenuInit.BurstDot && IgniteSlot != SpellSlot.Unknown && Ignite.IsReady() &&
                Ignite.Cast(target, true) == Spell.CastStates.SuccessfullyCasted)
            {
                return;
            }

            if (target.IsValidTarget(W.Range) && W.Cast(true))
            {
                return;
            }

            if (MenuInit.BurstFlash && FlashSlot != SpellSlot.Unknown && Flash.IsReady())
            {
                if (qStack < 2 && Utils.TickCount - lastQTime >= 850 && Q.Cast(Game.CursorPos, true))
                {
                    return;
                }

                if (qStack == 2 && E.IsReady() && R.IsReady() && !isRActive && W.IsReady() &&
                    target.IsValidTarget(E.Range + Flash.Range + Q.Range - 100))
                {
                    E.Cast(target.Position, true);
                    LeagueSharp.Common.Utility.DelayAction.Add(10 + Game.Ping, () => R.Cast(true));
                    LeagueSharp.Common.Utility.DelayAction.Add(50 + Game.Ping, () => Flash.Cast(target.Position, true));
                    LeagueSharp.Common.Utility.DelayAction.Add(61 + Game.Ping, () => Riven.UseItem());
                    LeagueSharp.Common.Utility.DelayAction.Add(62 + Game.Ping, () => Q.Cast(target.Position, true));
                    LeagueSharp.Common.Utility.DelayAction.Add(70 + Game.Ping, () => W.Cast(true));
                    LeagueSharp.Common.Utility.DelayAction.Add(71 + Game.Ping, () => R.Cast(target.Position, true));
                }
            }
            else if (target.IsValidTarget(E.Range + Q.Range + Q.Range + Q.Range))
            {
                if (qStack < 2 && Utils.TickCount - lastQTime >= 850 && Q.Cast(Game.CursorPos, true))
                {
                    return;
                }

                if (qStack == 2 && E.IsReady() && R.IsReady() && !isRActive && W.IsReady() &&
                    target.IsValidTarget(E.Range + Q.Range - 100))
                {
                    E.Cast(target.Position, true);
                    LeagueSharp.Common.Utility.DelayAction.Add(10 + Game.Ping, () => R.Cast(true));
                    LeagueSharp.Common.Utility.DelayAction.Add(50 + Game.Ping, () => Q.Cast(target.Position, true));
                    LeagueSharp.Common.Utility.DelayAction.Add(61 + Game.Ping, () => Riven.UseItem());
                    LeagueSharp.Common.Utility.DelayAction.Add(62 + Game.Ping, () => W.Cast(true));
                    LeagueSharp.Common.Utility.DelayAction.Add(70 + Game.Ping, () => R.Cast(target.Position, true));
                }
            }
        }
Ejemplo n.º 12
0
        private static void ComboEvent()
        {
            try
            {
                var target =
                    TargetSelector.GetTarget(
                        EntityManager.Heroes.Enemies.Where(x => x.IsValidTarget(Q.Range) && !x.IsUnKillable()),
                        DamageType.Magical);

                if (target != null && target.IsValidTarget(Q.Range))
                {
                    if (ComboMenu["FlowersRyze.ComboMenu.Ignite"].Cast <CheckBox>().CurrentValue&& IgniteSlot != SpellSlot.Unknown &&
                        Ignite.IsReady() && target.IsValidTarget(600) &&
                        (target.Health < MyExtraManager.GetComboDamage(target) && target.IsValidTarget(400) ||
                         target.Health < Me.GetIgniteDamage(target)))
                    {
                        Ignite.Cast(target);
                    }

                    if (Core.GameTickCount - LastCastTime > 500)
                    {
                        switch (ComboMenu["FlowersRyze.ComboMenu.Mode"].Cast <ComboBox>().CurrentValue)
                        {
                        case 0:
                            NormalCombo(target, ComboMenu["FlowersRyze.ComboMenu.Q"].Cast <CheckBox>().CurrentValue,
                                        ComboMenu["FlowersRyze.ComboMenu.W"].Cast <CheckBox>().CurrentValue,
                                        ComboMenu["FlowersRyze.ComboMenu.E"].Cast <CheckBox>().CurrentValue);
                            break;

                        case 1:
                            ShieldCombo(target, ComboMenu["FlowersRyze.ComboMenu.Q"].Cast <CheckBox>().CurrentValue,
                                        ComboMenu["FlowersRyze.ComboMenu.W"].Cast <CheckBox>().CurrentValue,
                                        ComboMenu["FlowersRyze.ComboMenu.E"].Cast <CheckBox>().CurrentValue);
                            break;

                        default:
                            BurstCombo(target, ComboMenu["FlowersRyze.ComboMenu.Q"].Cast <CheckBox>().CurrentValue,
                                       ComboMenu["FlowersRyze.ComboMenu.W"].Cast <CheckBox>().CurrentValue,
                                       ComboMenu["FlowersRyze.ComboMenu.E"].Cast <CheckBox>().CurrentValue);
                            break;
                        }
                    }
                }
            }
            catch (Exception ex)
            {
                Console.WriteLine("Error in MyEventManager.ComboEvent." + ex);
            }
        }
Ejemplo n.º 13
0
 private static void IgniteOnTick()
 {
     if (PlayerHasIgnite && SummonerMenu.GetCheckBoxValue("check" + "ignite"))
     {
         var target = TargetSelector.GetTarget(Ignite.Range, DamageType.Mixed);
         if (target != null && Ignite.IsReady() && !target.IsInRange(Player.Instance, SummonerMenu.GetSliderValue("minimunRangeIgnite")))
         {
             var predictedHealth = Prediction.Health.GetPrediction(target, Game.Ping);
             if (predictedHealth <= GetTotalDamage(target) + IgniteDamage() && predictedHealth > IgniteDamage())
             {
                 Ignite.Cast(target);
             }
         }
     }
 }
Ejemplo n.º 14
0
        public static void UseIgnite(AIHeroClient target)
        {
            if (Ignite == null || !Ignite.IsReady() || target == null)
            {
                return;
            }

            target = EntityManager.Heroes.Enemies.Where(en => en.Distance(myHero) < 600 + en.BoundingRadius)
                     .OrderBy(en => en.Health)
                     .FirstOrDefault();
            if (target != null && myHero.Distance(target) < 600 + target.BoundingRadius)
            {
                Ignite.Cast(target);
            }
        }
Ejemplo n.º 15
0
        private static void UseIgnite()
        {
            if (!Ignite.IsReady())
            {
                return;
            }
            var target = TargetSelector.GetTarget(Ignite.Range, DamageType.True);

            if (target != null && !target.IsZombie && !target.IsInvulnerable)
            {   //Overkill Protection
                if (target.Health > PredictDamage(target) && target.Health <= PredictDamage(target) + _Player.GetSummonerSpellDamage(target, DamageLibrary.SummonerSpells.Ignite))
                {
                    Ignite.Cast(target);
                }
            }
        }
Ejemplo n.º 16
0
 protected virtual void KillSteal()
 {
     foreach (var enemy in UnitManager.ValidEnemyHeroesInRange)
     {
         if (KillStealMenu.CheckBox("Ignite") && Ignite.IsKillable(enemy))
         {
             if (!MyHero.InAutoAttackRange(enemy) || MyHero.GetAttackDamage(enemy, true) <= enemy.TotalShieldHealth())
             {
                 Ignite.Cast(enemy);
             }
         }
         if (KillStealMenu.CheckBox("Smite") && Smite.IsKillable(enemy))
         {
             Smite.Cast(enemy);
         }
     }
 }
Ejemplo n.º 17
0
        private static void ComboEvent()
        {
            try
            {
                var target = TargetSelector.GetTarget(Q.Range);

                if (target != null && target.IsValidTarget(Q.Range))
                {
                    if (ComboMenu["FlowersRyze.ComboMenu.Ignite"].Enabled && IgniteSlot != SpellSlot.Unknown &&
                        Ignite.Ready && target.IsValidTarget(600) &&
                        (target.Health < MyExtraManager.GetComboDamage(target) && target.IsValidTarget(400) ||
                         target.Health < Me.GetIgniteDamage(target)))
                    {
                        Ignite.Cast(target);
                    }

                    if (Game.TickCount - LastCastTime > 500)
                    {
                        switch (ComboMenu["FlowersRyze.ComboMenu.Mode"].As <MenuList>().Value)
                        {
                        case 0:
                            NormalCombo(target, ComboMenu["FlowersRyze.ComboMenu.Q"].Enabled,
                                        ComboMenu["FlowersRyze.ComboMenu.W"].Enabled,
                                        ComboMenu["FlowersRyze.ComboMenu.E"].Enabled);
                            break;

                        case 1:
                            ShieldCombo(target, ComboMenu["FlowersRyze.ComboMenu.Q"].Enabled,
                                        ComboMenu["FlowersRyze.ComboMenu.W"].Enabled,
                                        ComboMenu["FlowersRyze.ComboMenu.E"].Enabled);
                            break;

                        default:
                            BurstCombo(target, ComboMenu["FlowersRyze.ComboMenu.Q"].Enabled,
                                       ComboMenu["FlowersRyze.ComboMenu.W"].Enabled,
                                       ComboMenu["FlowersRyze.ComboMenu.E"].Enabled);
                            break;
                        }
                    }
                }
            }
            catch (Exception ex)
            {
                Console.WriteLine("Error in MyEventManager.ComboEvent." + ex);
            }
        }
Ejemplo n.º 18
0
        public static void KillSteal()
        {
            if (Ignite != null && Config.Spell["eIg"].Cast <CheckBox>().CurrentValue)
            {
                switch (Config.Spell["Igstyle"].Cast <ComboBox>().CurrentValue)
                {
                case 0:
                {
                    var target = EntityManager.Heroes.Enemies.Where(t =>
                                                                    t.IsValidTarget(Ignite.Range) &&
                                                                    t.Health <= Player.Instance.GetSummonerSpellDamage(t, DamageLibrary.SummonerSpells.Ignite)).FirstOrDefault();

                    if (target != null && Config.Spell["Ig" + target.ChampionName].Cast <CheckBox>().CurrentValue&& Ignite.IsReady())
                    {
                        Ignite.Cast(target);
                    }
                }
                break;

                case 1:
                {
                    var target = EntityManager.Heroes.Enemies.Where(t =>
                                                                    t.IsValidTarget(Ignite.Range) &&
                                                                    t.Health <= Player.Instance.GetSummonerSpellDamage(t, DamageLibrary.SummonerSpells.Ignite) / 5).FirstOrDefault();

                    if (target != null && Config.Spell["Ig" + target.ChampionName].Cast <CheckBox>().CurrentValue&& Ignite.IsReady())
                    {
                        Ignite.Cast(target);
                    }
                }
                break;
                }
            }
            if (Smite != null && Config.Spell["esmiteKs"].Cast <CheckBox>().CurrentValue&& Extensions.CanUseOnChamp)
            {
                var target = EntityManager.Heroes.Enemies.Where(t =>
                                                                t.IsValidTarget(Smite.Range) &&
                                                                t.Health <= Player.Instance.GetSummonerSpellDamage(t, DamageLibrary.SummonerSpells.Smite)).FirstOrDefault();

                if (target != null && Config.Spell["Smite" + target.ChampionName].Cast <CheckBox>().CurrentValue&& Smite.IsReady())
                {
                    Smite.Cast(target);
                }
            }
        }
Ejemplo n.º 19
0
        public static void ExecuteCombo()
        {
            var target = TargetSelector.GetTarget(SpellsManager.Q.Range, DamageType.Magical);

            if ((target == null) || target.IsInvulnerable)
            {
                return;
            }

            if (ComboMenu["Q"].Cast <CheckBox>().CurrentValue&& target.IsValidTarget(SpellsManager.Q.Range) && SpellsManager.Q.IsReady())
            {
                var prediction = SpellsManager.Q.GetPrediction(target);
                SpellsManager.Q.Cast(SpellsManager.Q.GetPrediction(target).CastPosition);
            }

            if (ComboMenu["W"].Cast <CheckBox>().CurrentValue&& target.IsValidTarget(SpellsManager.W.Range) && SpellsManager.W.IsReady())
            {
                SpellsManager.W.Cast(target.Position);
            }

            if (ComboMenu["R"].Cast <CheckBox>().CurrentValue&& target.IsValidTarget(SpellsManager.R.Range) && SpellsManager.R.IsReady())
            {
                SpellsManager.R.Cast(target);
            }

            if (ComboMenu["RKillable"].Cast <CheckBox>().CurrentValue&& target.IsValidTarget(SpellsManager.R.Range) && SpellsManager.R.IsReady() && target.GetRDamage(SpellSlot.R) > target.Health)
            {
                SpellsManager.R.Cast(target);
            }

            var Summ = TargetSelector.GetTarget(Ignite.Range, DamageType.True);

            if ((Summ == null) || Summ.IsInvulnerable)
            {
                return;
            }
            //Ignite
            if (ComboMenu["Ignite"].Cast <CheckBox>().CurrentValue)
            {
                if (Player.Instance.CountEnemyChampionsInRange(600) >= 1 && Ignite.IsReady() && Ignite.IsLearned && Summ.IsValidTarget(Ignite.Range) && target.HealthPercent <= ComboMenu["IgniteHealth"].Cast <Slider>().CurrentValue&& target.Health > target.GetRealDamage())
                {
                    Ignite.Cast(Summ);
                }
            }
        }
Ejemplo n.º 20
0
        private static void KillSteal()
        {
            foreach (var hptarget in EntityManager.Enemies.Where(a => a.IsValidTarget(1200) && !a.IsDead))
            {
                if (!hptarget.IsValid || hptarget.IsDead || hptarget == null)
                {
                    return;
                }
                var Health = hptarget.Health;
                if (Ignite.IsReady())
                {
                    var dmgI = (50 + ((LeBlanc.Level) * 20));
                    if (LeBlanc.Distance(hptarget) < Q.Range && Health < dmgI)

                    {
                        Ignite.Cast(hptarget);
                    }
                }
            }
        }
Ejemplo n.º 21
0
        public static void Game_OnTick(EventArgs args)
        {
            if (!Summs.menu.CheckBoxValue("Ignite"))
            {
                return;
            }

            foreach (
                var target in
                EntityManager.Heroes.Enemies.Where(
                    e =>
                    Ignite.IsReady() && Summs.menu.CheckBoxValue("ignite" + e.Name()) && Player.Instance.GetAutoAttackDamage(e) * 2 < e.Health && e.IsKillable(600) &&
                    Player.Instance.GetSummonerSpellDamage(e, DamageLibrary.SummonerSpells.Ignite) >= e.TotalShieldHealth()))
            {
                if (target != null)
                {
                    Ignite.Cast(target);
                }
            }
        }
Ejemplo n.º 22
0
        public static void Game_OnTick(EventArgs args)
        {
            if (!Summs.menu.CheckBoxValue("Ignite"))
            {
                return;
            }

            if (!Ignite.IsReady())
            {
                return;
            }

            var targets = EntityManager.Heroes.Enemies.Where(e => e.IsKillable(600) && Player.Instance.GetSummonerSpellDamage(e, DamageLibrary.SummonerSpells.Ignite) >= e.TotalShieldHealth());
            var target  = targets.OrderByDescending(t => t.Distance(Player.Instance)).FirstOrDefault(t => Summs.menu.CheckBoxValue("ignite" + t.Name()) && t.Health >= Player.Instance.GetAutoAttackDamage(t));

            if (target != null)
            {
                Ignite.Cast(target);
            }
        }
Ejemplo n.º 23
0
        private static void BurstEvent()
        {
            try
            {
                if (!BurstMenu["FlowersRiven.BurstMenu.Key"].As <MenuKeyBind>().Enabled)
                {
                    return;
                }

                var target = TargetSelector.GetSelectedTarget();

                if (target == null || !target.IsValidTarget())
                {
                    return;
                }

                if (BurstMenu["FlowersRiven.BurstMenu.Ignite"].Enabled && IgniteSlot != SpellSlot.Unknown &&
                    Ignite.Ready && target.IsValidTarget(600))
                {
                    Ignite.Cast(target);
                }

                switch (BurstMenu["FlowersRiven.BurstMenu.Mode"].As <MenuList>().Value)
                {
                case 0:
                    BurstShyModeEvent(target, BurstMenu["FlowersRiven.BurstMenu.Flash"].Enabled);
                    break;

                case 1:
                    BurstEQ3ModeEvent(target, BurstMenu["FlowersRiven.BurstMenu.Flash"].Enabled);
                    break;
                }
            }
            catch (Exception ex)
            {
                Console.WriteLine("Error in MyEventManager.BurstEvent." + ex);
            }
        }
Ejemplo n.º 24
0
        private static void ComboEvent()
        {
            try
            {
                var target = TargetSelector.GetTarget(800);

                if (target != null && target.IsValidTarget(800f))
                {
                    if (ComboMenu["FlowersRiven.ComboMenu.Ignite"].Enabled && IgniteSlot != SpellSlot.Unknown &&
                        Ignite.Ready && target.IsValidTarget(600) &&
                        (target.Health < MyExtraManager.GetComboDamage(target) && target.IsValidTarget(400) ||
                         target.Health < Me.GetIgniteDamage(target)))
                    {
                        Ignite.Cast(target);
                    }

                    if (ComboMenu["FlowersRiven.ComboMenu.Youmuu"].Enabled)
                    {
                        UseYoumuu();
                    }

                    if (ComboMenu["FlowersRiven.ComboMenu.R"].As <MenuKeyBind>().Enabled&& R.Ready && !isRActive &&
                        ComboMenu["FlowersRiven.ComboMenu.RTargetFor" + target.ChampionName].Enabled &&
                        target.Health <= MyExtraManager.GetComboDamage(target) * 1.3 && target.IsValidTarget(600f))
                    {
                        MyExtraManager.R1Logic(target);
                    }

                    if (ComboMenu["FlowersRiven.ComboMenu.RMode"].As <MenuList>().Value != 3 && R.Ready && isRActive &&
                        ComboMenu["FlowersRiven.ComboMenu.RTargetFor" + target.ChampionName].Enabled)
                    {
                        MyExtraManager.R2Logic(target);
                    }

                    if (ComboMenu["FlowersRiven.ComboMenu.QGapcloser"].Enabled && Q.Ready &&
                        Game.TickCount - lastQTime > 1200 && !Me.IsDashing() && target.IsValidTarget(500f) &&
                        target.DistanceToPlayer() > Me.GetFullAttackRange(target) + 50 &&
                        Prediction.GetPrediction(target, 0.25f).UnitPosition.DistanceToPlayer() >
                        Me.GetFullAttackRange(target) + 50)
                    {
                        Q.Cast(target);
                        return;
                    }


                    if (ComboMenu["FlowersRiven.ComboMenu.EGapcloser"].Enabled && E.Ready && target.IsValidTarget(600) &&
                        target.DistanceToPlayer() > Me.GetFullAttackRange(target) + 50)
                    {
                        E.Cast(target.ServerPosition);
                    }


                    if (W.Ready && target.IsValidTarget(W.Range))
                    {
                        if (qStack == 0 && W.Cast())
                        {
                            return;
                        }

                        if (Q.Ready && qStack > 1 && W.Cast())
                        {
                            return;
                        }

                        if (Me.HasBuff("RivenFeint") && W.Cast())
                        {
                            return;
                        }

                        if (!target.IsFacing(Me))
                        {
                            W.Cast();
                        }
                    }
                }
            }
            catch (Exception ex)
            {
                Console.WriteLine("Error in MyEventManager.ComboEvent." + ex);
            }
        }
Ejemplo n.º 25
0
        private static void ComboEvent()
        {
            try
            {
                if (isCastingUlt)
                {
                    return;
                }

                var target = TargetSelector.GetTarget(E.Range + 300f);

                if (target != null && target.IsValidTarget(E.Range + 300f))
                {
                    if (ComboMenu["FlowersKatarina.ComboMenu.Ignite"].Enabled && IgniteSlot != SpellSlot.Unknown &&
                        Ignite.Ready && target.IsValidTarget(600) &&
                        (target.Health < MyExtraManager.GetComboDamage(target) && target.IsValidTarget(400) ||
                         target.Health < Me.GetIgniteDamage(target)))
                    {
                        Ignite.Cast(target);
                    }

                    //Item Hextech_Gunblade Bilgewater_Cutlass

                    if (ComboMenu["FlowersKatarina.ComboMenu.W"].Enabled &&
                        ComboMenu["FlowersKatarina.ComboMenu.WSmart"].Enabled && W.Ready &&
                        target.IsValidTarget(W.Range))
                    {
                        W.Cast();
                    }

                    switch (ComboMenu["FlowersKatarina.ComboMenu.Mode"].As <MenuList>().Value)
                    {
                    case 0:
                        MyExtraManager.QEWLogic(target, ComboMenu["FlowersKatarina.ComboMenu.Q"].Enabled,
                                                ComboMenu["FlowersKatarina.ComboMenu.W"].Enabled,
                                                ComboMenu["FlowersKatarina.ComboMenu.E"].Enabled);
                        break;

                    case 1:
                        MyExtraManager.EQWLogic(target, ComboMenu["FlowersKatarina.ComboMenu.Q"].Enabled,
                                                ComboMenu["FlowersKatarina.ComboMenu.W"].Enabled,
                                                ComboMenu["FlowersKatarina.ComboMenu.E"].Enabled);
                        break;
                    }

                    if (ComboMenu["FlowersKatarina.ComboMenu.R"].Enabled && R.Ready &&
                        Me.CountEnemyHeroesInRange(R.Range) > 0 && !Q.Ready && !W.Ready && !E.Ready)
                    {
                        if (ComboMenu["FlowersKatarina.ComboMenu.RAlways"].Enabled)
                        {
                            Orbwalker.AttackingEnabled = false;
                            Orbwalker.MovingEnabled    = false;
                            R.Cast();
                        }

                        if (ComboMenu["FlowersKatarina.ComboMenu.RKillAble"].Enabled &&
                            (target.Health <= MyExtraManager.GetComboDamage(target) ||
                             target.Health <= R.GetDamage(target) * 0.8) &&
                            target.Health > Q.GetDamage(target) + MyExtraManager.GetKataPassiveDamage(target) * 2)
                        {
                            Orbwalker.AttackingEnabled = false;
                            Orbwalker.MovingEnabled    = false;
                            R.Cast();
                        }

                        if (ComboMenu["FlowersKatarina.ComboMenu.RCountHit"].As <MenuSliderBool>().Enabled&&
                            Me.CountEnemyHeroesInRange(R.Range) >= ComboMenu["FlowersKatarina.ComboMenu.RCountHit"].As <MenuSliderBool>().Value)
                        {
                            Orbwalker.AttackingEnabled = false;
                            Orbwalker.MovingEnabled    = false;
                            R.Cast();
                        }
                    }
                }
            }
            catch (Exception ex)
            {
                Console.WriteLine("Error in MyEventManager.ComboEvent." + ex);
            }
        }
Ejemplo n.º 26
0
        public override void Execute()
        {
            // Auto-toggle W off
            if (Settings.AutoWOff && WActive)
            {
                if (PlayerHealth < SettingsHealth.MinWHealth)
                {
                    Debug.WriteChat("Health below {0}%, turning W off", "" + SettingsHealth.MinWHealth);
                    W.Cast();
                }
                else
                {
                    var enemy =
                        EntityManager.Heroes.Enemies.FirstOrDefault(
                            e => !e.IsDead && e.Health > 0 && e.IsVisible && e.Distance(_PlayerPos) < 600);
                    var minion = EntityManager.MinionsAndMonsters.CombinedAttackable.FirstOrDefault(
                        e => !e.IsDead && e.Health > 0 && e.IsVisible && e.Distance(_PlayerPos) < 600);
                    if (enemy == null && minion == null)
                    {
                        Debug.WriteChat("No enemies around - turning W off.");
                        W.Cast();
                    }
                }
            }

            // Auto Q Harass
            if (SettingsHarass.AutoQ && Q.IsReady() && PlayerHealth >= SettingsHarass.MinAutoQHealth && !_Player.IsRecalling() && !PlayerIsUnderEnemyTurret() /* Don't harass under enemy turrets */ && !Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo) /* Don't Harass in Combo, it can mess it up */)
            {
                var enemies = EntityManager.Heroes.Enemies.Where(
                    e => e.IsValidTarget(SettingsCombo.MaxQDistance)).OrderBy(e => _Player.Distance(e));
                foreach (var enemy in enemies)
                {
                    if (
                        DrMundo.Config.ModesMenu.MenuModes["blacklist" + enemy.ChampionName].Cast <CheckBox>()
                        .CurrentValue)
                    {
                        continue;
                    }
                    var pred = Q.GetPrediction(enemy);
                    if (pred.HitChance >= SettingsPrediction.MinQHCAutoHarass)
                    {
                        Q.Cast(pred.CastPosition);
                        Debug.WriteChat("Casting Q in Auto Harass, Target: {0}, HitChance: {1}", enemy.ChampionName, pred.HitChance.ToString());
                        break;
                    }
                }
            }

            // KillSteal
            if (Settings.KsQ && Q.IsReady())
            {
                var enemies =
                    EntityManager.Heroes.Enemies.Where(
                        e => e.IsValidTarget(Q.Range) && e.TotalShieldHealth() < Damages.QDamage(e));
                foreach (var enemy in enemies)
                {
                    if (!enemy.HasBuffOfType(BuffType.SpellImmunity) && !enemy.HasBuffOfType(BuffType.SpellShield))
                    {
                        var pred = Q.GetPrediction(enemy);
                        if (pred.HitChance >= SettingsPrediction.MinQHCKillSteal)
                        {
                            Q.Cast(enemy);
                            Debug.WriteChat("Casting Q in KS on {0}, Enemy HP: {1}", "" + enemy.ChampionName,
                                            "" + enemy.Health);
                            break;
                        }
                    }
                }
            }
            if (Settings.KsIgnite && HasIgnite && Ignite.IsReady())
            {
                var enemy =
                    EntityManager.Heroes.Enemies.FirstOrDefault(
                        e => e.IsValidTarget(Ignite.Range) && e.TotalShieldHealth() < Damages.IgniteDmg(e));
                if (enemy != null)
                {
                    Ignite.Cast(enemy);
                    Debug.WriteChat("Casting Ignite in KS on {0}, Enemy HP: {1}", "" + enemy.ChampionName, "" + enemy.Health);
                }
            }

            // Automatic ult usage
            if (Settings.AutoR && R.IsReady() && !Player.Instance.IsRecalling() && !Player.Instance.IsInShopRange())
            {
                var enemiesAround = EntityManager.Heroes.Enemies.Count(e => e.Distance(Player.Instance) < 1500 && e.IsValidTarget());
                if (enemiesAround >= Settings.AutoRMinEnemies && Player.Instance.HealthPercent <= Settings.AutoRMinHP)
                {
                    R.Cast();
                    Debug.WriteChat("AutoCasting R, Enemies around: {0}, Current HP: {1}", "" + enemiesAround, "" + ((int)PlayerHealth));
                }
            }

            // Potion manager
            if (Settings.Potion && !Player.Instance.IsInShopRange() && Player.Instance.HealthPercent <= Settings.potionMinHP && !(Player.Instance.HasBuff("RegenerationPotion") || Player.Instance.HasBuff("ItemCrystalFlaskJungle") || Player.Instance.HasBuff("ItemMiniRegenPotion") || Player.Instance.HasBuff("ItemCrystalFlask") || Player.Instance.HasBuff("ItemDarkCrystalFlask")))
            {
                if (Item.HasItem(HealthPotion.Id) && Item.CanUseItem(HealthPotion.Id))
                {
                    Debug.WriteChat("Using HealthPotion because below {0}% HP - have {1}% HP", String.Format("{0}", Settings.potionMinHP), String.Format("{0:##.##}", Player.Instance.HealthPercent));
                    HealthPotion.Cast();
                    return;
                }
                if (Item.HasItem(HuntersPotion.Id) && Item.CanUseItem(HuntersPotion.Id))
                {
                    Debug.WriteChat("Using HuntersPotion because below {0}% HP - have {1}% HP", String.Format("{0}", Settings.potionMinHP), String.Format("{0:##.##}", Player.Instance.HealthPercent));
                    HealthPotion.Cast();
                    return;
                }
                if (Item.HasItem(TotalBiscuit.Id) && Item.CanUseItem(TotalBiscuit.Id))
                {
                    Debug.WriteChat("Using TotalBiscuitOfRejuvenation because below {0}% HP - have {1}% HP", String.Format("{0}", Settings.potionMinHP), String.Format("{0:##.##}", Player.Instance.HealthPercent));
                    TotalBiscuit.Cast();
                    return;
                }
                if (Item.HasItem(RefillablePotion.Id) && Item.CanUseItem(RefillablePotion.Id))
                {
                    Debug.WriteChat("Using RefillablePotion because below {0}% HP - have {1}% HP", String.Format("{0}", Settings.potionMinHP), String.Format("{0:##.##}", Player.Instance.HealthPercent));
                    RefillablePotion.Cast();
                    return;
                }
                if (Item.HasItem(CorruptingPotion.Id) && Item.CanUseItem(CorruptingPotion.Id))
                {
                    Debug.WriteChat("Using CorruptingPotion because below {0}% HP - have {1}% HP", String.Format("{0}", Settings.potionMinHP), String.Format("{0:##.##}", Player.Instance.HealthPercent));
                    CorruptingPotion.Cast();
                    return;
                }
            }
        }
Ejemplo n.º 27
0
        private static void Misc()
        {
            if (misc.check("KSR") && R.IsReady())
            {
                foreach (var hero in GameObjects.EnemyHeroes.Where(x => x.GetRealHealth(DamageType.Magical) < myhero.GetSpellDamage(x, SpellSlot.R) && R.CanCast(x) && !x.HaveSpellShield()).OrderByDescending(x => x.ChampionsKilled))
                {
                    if (hero != null)
                    {
                        R.Cast(hero);
                    }
                }
            }

            var target = TargetSelector.GetTarget(Q.Range, DamageType.Magical);

            if (target != null && target.IsValidTarget())
            {
                if (misc.check("KSQ") && Q.CanCast(target) && QDamage(target) > target.Health)
                {
                    var pred = Q.GetSPrediction(target);

                    //if (pred.HitChance >= hitQ) Q.Cast(pred.CastPosition);
                    Q.Cast(pred.CastPosition);
                }

                if (misc.check("KSW") && W.CanCast(target) && WDamage(target) > target.Health)
                {
                    var pred = W.GetSPrediction(target);

                    if (pred.HitChance >= hitW)
                    {
                        W.Cast(pred.CastPosition);
                    }
                }



                if (Ignite != null && misc.check("autoign") && Ignite.IsReady() && target.IsValidTarget(Ignite.Range) &&
                    myhero.GetSummonerSpellDamage(target, SummonerSpell.Ignite) > target.Health)
                {
                    Ignite.Cast(target);
                }
            }

            if (misc.check("KSJ") && W.IsReady() && GameObjects.JungleLegendary.Any())
            {
                var lmob = GameObjects.JungleLegendary.Where(x => x.IsValidTarget(W.Range) && HealthPrediction.GetPrediction(x, 1000) > 0 && myhero.GetSpellDamage(x, SpellSlot.W) > HealthPrediction.GetPrediction(x, 1000)).FirstOrDefault();

                if (lmob != null && W.IsInRange(lmob.Position))
                {
                    W.Cast(lmob.Position);
                }
            }

            if (misc.check("AUTOPOT") && !myhero.HasBuffOfType(BuffType.Heal) && myhero.HealthPercent <= slider(misc, "POTMIN"))
            {
                if (Items.CanUseItem(myhero, Potion.Id))
                {
                    Potion.Cast();
                }

                else if (Items.CanUseItem(myhero, Biscuit.Id))
                {
                    Biscuit.Cast();
                }

                else if (Items.CanUseItem(myhero, RPotion.Id))
                {
                    RPotion.Cast();
                }

                else if (Items.CanUseItem(myhero, CPotion.Id))
                {
                    CPotion.Cast();
                }
            }
            //myhero.SetSkin(comb(misc, "skinID"));
        }
Ejemplo n.º 28
0
        private static void Combo()
        {
            var target = TargetSelector.GetTarget(/*E.IsReady() ? E.Range + 375 : */ Q.Range, DamageType.Magical);

            if (target != null && target.IsValidTarget())
            {
                if (E.CanCast(target) && combo.check("CE") && !(combo.check("EIMMO") && target.HaveImmovableBuff()))
                {
                    var Epred = E.GetSPrediction(target);

                    switch (comb(combo, "CEMODE"))
                    {
                    case 0:
                        var pred1 = SPrediction.Prediction.GetFastUnitPosition(target, 0.75f);
                        if (E.IsInRange(pred1))
                        {
                            E.Cast(pred1);
                        }
                        else if (pred1.DistanceToPlayer() > E.Range && pred1.DistanceToPlayer() < E.Range + 370f)
                        {
                            E.Cast(myhero.Position.Extend(target.Position, 370f));
                        }
                        break;

                    case 1:
                        var way  = target.GetWaypoints().LastOrDefault();
                        var wayb = way != null && way.IsValid() ? target.DistanceToPlayer() < way.DistanceToPlayer() : false;
                        var dist = target.HaveImmovableBuff() ?
                                   310f : (target.IsFacing(myhero) ?
                                           (target.IsMoving || wayb ? 320f + 0.60f * target.MoveSpeed : 340f) : (target.IsMoving ? 230f - 0.60f * target.MoveSpeed : 260f));
                        var spot = target.Position.Extend(myhero.Position, dist);

                        if (E.IsInRange(spot))
                        {
                            E.Cast(spot);
                        }
                        break;

                    case 2:
                        var pred = E.GetAoeSPrediction();

                        if (pred.HitCount >= slider(combo, "CEAOE"))
                        {
                            E.Cast(pred.CastPosition);
                        }
                        break;
                    }
                }



                if (Q.CanCast(target) && combo.check("CQ"))
                {
                    var Qpred = Q.GetSPrediction(target);
                    var col   = Qpred.CollisionResult.Units.Any(x => x.Team != myhero.Team) ? Qpred.CollisionResult.Units.Count(x => x.Team != myhero.Team) < 2 : true;

                    if (col && Qpred.HitChance >= hitQ && Q.Cast(Qpred.CastPosition))
                    {
                        return;
                    }
                }

                if (W.CanCast(target) && combo.check("CW"))
                {
                    var Wpred = W.GetSPrediction(target);

                    switch (comb(combo, "CWMODE"))
                    {
                    case 0:
                        if (Wpred.HitChance >= hitW || Wpred.HitChance == HitChance.Immobile ||
                            (target.HasBuffOfType(BuffType.Slow) && Wpred.HitChance == HitChance.High))
                        {
                            W.Cast(Wpred.CastPosition);
                        }
                        break;

                    case 1:
                        W.Cast(target.Position);
                        break;

                    case 2:
                        if (target.HaveImmovableBuff())
                        {
                            W.Cast(Wpred.CastPosition);
                        }
                        break;
                    }
                }

                if (combo.check("CR") && R.IsReady() &&
                    R.IsInRange(target.Position) && (ComboDamage(target) > target.GetRealHealth(DamageType.Magical) ||
                                                     myhero.GetSpellDamage(target, SpellSlot.R) > target.GetRealHealth(DamageType.Magical)) && /*!target.HasBuff("bansheesveil") &&*/ !target.HasBuff("SamiraW") && !target.HaveSpellShield())
                {
                    if ((ComboDamage(target) - myhero.GetSpellDamage(target, SpellSlot.R)) > target.Health)
                    {
                        return;
                    }
                    R.Cast(target);
                }

                if (Ignite != null && combo.check("IgniteC") && Ignite.IsReady() && ComboDamage(target) < target.Health &&
                    Ignite.IsInRange(target.Position) && myhero.GetSummonerSpellDamage(target, SummonerSpell.Ignite) + ComboDamage(target) > target.Health)
                {
                    Ignite.Cast(target);
                }
            }
        }
Ejemplo n.º 29
0
        // Combo  E Q W
        public static void Execute12()
        {
            var target = TargetSelector.GetTarget(SpellsManager.E.Range, DamageType.Mixed);

            if ((target == null) || target.IsInvulnerable)
            {
                return;
            }
            if (SpellsManager.E.IsReady() && ComboMenu["E"].Cast <CheckBox>().CurrentValue)
            {
                if (!ComboMenu["El"].Cast <CheckBox>().CurrentValue || !Player.Instance.IsInAutoAttackRange(target))
                {
                    if (HumanizeMenu["Humanize"].Cast <CheckBox>().CurrentValue)
                    {
                        Core.DelayAction(() => SpellsManager.E.Cast(target), HumanizeMenu["HumanizeE"].Cast <Slider>().CurrentValue);
                    }
                    else
                    {
                        SpellsManager.E.Cast(target);
                    }
                }
            }

            if (ComboMenu["Q"].Cast <CheckBox>().CurrentValue)
            {
                if (target.IsValidTarget(SpellsManager.Q.Range) && SpellsManager.Q.IsReady())
                {
                    if (HumanizeMenu["Humanize"].Cast <CheckBox>().CurrentValue)
                    {
                        Core.DelayAction(() => SpellsManager.Q.Cast(target), HumanizeMenu["HumanizeQ"].Cast <Slider>().CurrentValue);
                    }
                    else
                    {
                        SpellsManager.Q.Cast(target);
                    }
                }
            }

            if (ComboMenu["W"].Cast <CheckBox>().CurrentValue)
            {
                if (SpellsManager.W.IsReady() && target.IsValidTarget(SpellsManager.W.Range))
                {
                    if (HumanizeMenu["Humanize"].Cast <CheckBox>().CurrentValue)
                    {
                        Core.DelayAction(() => SpellsManager.W.Cast(), HumanizeMenu["HumanizerW"].Cast <Slider>().CurrentValue);
                    }
                    else
                    {
                        SpellsManager.W.Cast();
                    }
                }
            }

            var Summ = TargetSelector.GetTarget(Ignite.Range, DamageType.Mixed);

            if ((Summ == null) || Summ.IsInvulnerable)
            {
                return;
            }
            //Ignite
            if (ComboMenu["Ignite"].Cast <CheckBox>().CurrentValue)
            {
                if (Player.Instance.CountEnemiesInRange(600) >= 1 && Ignite.IsReady() && Ignite.IsLearned && Summ.IsValidTarget(Ignite.Range) && target.HealthPercent <= ComboMenu["IgniteHealth"].Cast <Slider>().CurrentValue)
                {
                    if (target.Health >
                        target.GetRealDamage())
                    {
                        Ignite.Cast(Summ);
                    }
                }
            }

            //var R1 = GetSlotFromComboBox(Menus.MiscMenu.GetComboBoxValue("R1"));
            if (ComboMenu["R"].Cast <CheckBox>().CurrentValue)
            {
                if (ComboMenu["R1"].Cast <CheckBox>().CurrentValue)
                {
                    if (SpellsManager.R.IsReady() && target.IsValidTarget(300) && target.HealthPercent <= ComboMenu["Rhealth"].Cast <Slider>().CurrentValue)
                    {
                        Orbwalker.DisableAttacking = true;
                        Orbwalker.DisableMovement  = true;
                        SpellsManager.R.Cast();
                        rStart = Environment.TickCount;
                    }
                }


                if (ComboMenu["R2"].Cast <CheckBox>().CurrentValue)
                {
                    if (SpellsManager.R.IsReady() && target.IsValidTarget(SpellsManager.R.Range) && target.HealthPercent <= ComboMenu["Rhealth"].Cast <Slider>().CurrentValue)
                    {
                        Orbwalker.DisableAttacking = true;
                        Orbwalker.DisableMovement  = true;
                        SpellsManager.R.Cast();
                        rStart = Environment.TickCount;
                    }
                }

                if (ComboMenu["R3"].Cast <CheckBox>().CurrentValue)
                {
                    if (SpellsManager.R.IsReady() && target.IsValidTarget(SpellsManager.W.Range) && target.HealthPercent <= ComboMenu["Rhealth"].Cast <Slider>().CurrentValue)
                    {
                        Orbwalker.DisableAttacking = true;
                        Orbwalker.DisableMovement  = true;
                        SpellsManager.R.Cast();
                        rStart = Environment.TickCount;
                    }
                }
            }
        }
Ejemplo n.º 30
0
        // W > Q > E > R
        public static void Execute()
        {
            var target = TargetSelector.GetTarget(SpellsManager.Q.Range, DamageType.Magical);

            if ((target == null) || target.IsInvulnerable)
            {
                return;
            }

            var Poisoned = EntityManager.Heroes.Enemies.Find(e => e.IsValidTarget(SpellsManager.E.Range) && e.HasBuffOfType(BuffType.Poison));

            //var Poisoned = EntityManager.Heroes.Enemies.Where(e => e.IsValidTarget(SpellsManager.E.Range)).OrderBy(e => e.HasBuffOfType(BuffType.Poison)).ThenBy(e => target).FirstOrDefault;

            if (SpellsManager.R.IsReady() && ComboMenu["R"].Cast <CheckBox>().CurrentValue&& ComboMenu[target.ChampionName].Cast <CheckBox>().CurrentValue&& !target.IsDead)
            {
                if (!ComboMenu["ROnly"].Cast <CheckBox>().CurrentValue)
                {
                    if (HumanizerMenu["Humanize"].Cast <CheckBox>().CurrentValue)
                    {
                        Core.DelayAction(() => SpellsManager.R.Cast(target), HumanizerMenu["HumanizeR"].Cast <Slider>().CurrentValue);
                    }
                    else
                    {
                        SpellsManager.R.Cast(target);
                    }
                }
            }

            if (SpellsManager.R.IsReady() && ComboMenu["R"].Cast <CheckBox>().CurrentValue&& ComboMenu["ROnly"].Cast <CheckBox>().CurrentValue&& !target.IsFacing(myhero) && ComboMenu[target.ChampionName].Cast <CheckBox>().CurrentValue&& !target.IsDead)
            {
                if (HumanizerMenu["Humanize"].Cast <CheckBox>().CurrentValue)
                {
                    Core.DelayAction(() => SpellsManager.R.Cast(target), HumanizerMenu["HumanizeR"].Cast <Slider>().CurrentValue);
                }
                else
                {
                    SpellsManager.R.Cast(target);
                }
            }


            if (ComboMenu["W"].Cast <CheckBox>().CurrentValue&& SpellsManager.W.IsReady() && target.IsValidTarget(SpellsManager.W.Range))
            {
                var prediction = SpellsManager.W.GetPrediction(target);
                if (HumanizerMenu["Humanize"].Cast <CheckBox>().CurrentValue)
                {
                    Core.DelayAction(() => SpellsManager.W.Cast(prediction.CastPosition), HumanizerMenu["HumanizeW"].Cast <Slider>().CurrentValue);
                }
                else
                {
                    SpellsManager.W.Cast(prediction.CastPosition);
                }
            }

            if (ComboMenu["Q"].Cast <CheckBox>().CurrentValue&& SpellsManager.Q.IsReady() && target.IsValidTarget(SpellsManager.Q.Range + 100))
            {
                var prediction = SpellsManager.Q.GetPrediction(target);
                if (HumanizerMenu["Humanize"].Cast <CheckBox>().CurrentValue)
                {
                    Core.DelayAction(() => SpellsManager.Q.Cast(prediction.CastPosition), HumanizerMenu["HumanizeQ"].Cast <Slider>().CurrentValue);
                }
                else
                {
                    SpellsManager.Q.Cast(prediction.CastPosition);
                }
            }

            if (SpellsManager.E.IsReady() && ComboMenu["E"].Cast <CheckBox>().CurrentValue&& Poisoned.IsValidTarget(SpellsManager.E.Range) && ComboMenu["EOnly"].Cast <CheckBox>().CurrentValue&& (SpellsManager.Q.IsOnCooldown || !target.IsInRange(myhero, SpellsManager.Q.Range)))
            {
                if (HumanizerMenu["Humanize"].Cast <CheckBox>().CurrentValue)
                {
                    Core.DelayAction(() => SpellsManager.E.Cast(Poisoned), HumanizerMenu["HumanizeE"].Cast <Slider>().CurrentValue);
                }
                else
                {
                    SpellsManager.E.Cast(Poisoned);
                }
            }

            else if (SpellsManager.E.IsReady() && ComboMenu["E"].Cast <CheckBox>().CurrentValue&& target.IsValidTarget(SpellsManager.E.Range) && (SpellsManager.Q.IsOnCooldown || !target.IsInRange(myhero, SpellsManager.Q.Range)))
            {
                if (HumanizerMenu["Humanize"].Cast <CheckBox>().CurrentValue)
                {
                    Core.DelayAction(() => SpellsManager.E.Cast(target), HumanizerMenu["HumanizeE"].Cast <Slider>().CurrentValue);
                }
                else
                {
                    SpellsManager.E.Cast(target);
                }
            }


            var Summ = TargetSelector.GetTarget(Ignite.Range, DamageType.Mixed);

            if ((Summ == null) || Summ.IsInvulnerable)
            {
                return;
            }
            //Ignite
            if (ComboMenu["Ignite"].Cast <CheckBox>().CurrentValue)
            {
                if (Player.Instance.CountEnemiesInRange(600) >= 1 && Ignite.IsReady() && Ignite.IsLearned && Summ.IsValidTarget(Ignite.Range))
                {
                    if (target.Health >
                        target.GetRealDamage())
                    {
                        Ignite.Cast(Summ);
                    }
                }
            }
        }