public static void Harass()
            {
                if (ManaManager.HaveNoEnoughMana(MenuManager.HarassMenu["MinMana"].GetValue <MenuSlider>()))
                {
                    return;
                }

                if (MenuManager.HarassMenu["Q"].GetValue <MenuBool>().Enabled&& SpellManager.Q.IsReady())
                {
                    var target = TargetSelector.GetTarget(SpellManager.Q.Range);

                    if (target != null && target.IsValidTarget(SpellManager.Q.Range))
                    {
                        var getPrediction = SpellManager.Q.GetPrediction(target, true);

                        if (getPrediction.Hitchance >= HitChance.High)
                        {
                            SpellManager.Q.Cast(getPrediction.CastPosition);
                        }
                    }
                }
            }
Exemple #2
0
        /// <summary>
        ///     Called when the game updates itself.
        /// </summary>
        /// <param name="args">The <see cref="EventArgs" /> instance containing the event data.</param>
        public static void Harass(EventArgs args)
        {
            if (!Targets.Target.LSIsValidTarget() ||
                Invulnerable.Check(Targets.Target))
            {
                return;
            }

            /// <summary>
            ///     The Q Harass Logic.
            /// </summary>
            if (Vars.Q.IsReady() &&
                Targets.Target.LSIsValidTarget(Vars.Q.Range) &&
                GameObjects.Player.ManaPercent >
                ManaManager.GetNeededMana(Vars.Q.Slot, Vars.getSliderItem(Vars.QMenu, "harass")) &&
                Vars.getSliderItem(Vars.QMenu, "harass") != 101)
            {
                Vars.Q.Cast(Targets.Target.LSIsValidTarget(300f)
                    ? Targets.Target.ServerPosition
                    : Vars.Q.GetPrediction(Targets.Target).CastPosition.LSExtend(GameObjects.Player.ServerPosition, -140f));
            }
        }
Exemple #3
0
        internal static void Init(Obj_AI_Base sender, GameObjectProcessSpellCastEventArgs Args)
        {
            if (sender == null || sender.IsMe || sender.IsAlly || !Args.SData.IsAutoAttack() || !Args.Target.IsMe)
            {
                return;
            }

            if (Orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && Menu.GetBool("ComboE") && E.IsReady() &&
                sender is AIHeroClient)
            {
                E.Cast();
            }

            if (Orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.LaneClear &&
                ManaManager.HasEnoughMana(Menu.GetSlider("JungleClearMana")) && ManaManager.SpellFarm &&
                Menu.GetBool("JungleClearE") && E.IsReady() && sender is Obj_AI_Minion &&
                MinionManager.GetMinions(Me.Position, 650f, MinionTypes.All, MinionTeam.Neutral,
                                         MinionOrderTypes.MaxHealth).Contains(sender) && Me.HealthPercent <= 70)
            {
                E.Cast();
            }
        }
Exemple #4
0
        /// <summary>
        ///     Fired when the game is updated.
        /// </summary>
        /// <param name="args">The <see cref="EventArgs" /> instance containing the event data.</param>
        public static void Clear(EventArgs args)
        {
            if (Bools.HasSheenBuff())
            {
                return;
            }

            /// <summary>
            ///     The Clear Q Logics.
            /// </summary>
            if (Vars.Q.IsReady())
            {
                /// <summary>
                ///     The JungleClear Q Logic.
                /// </summary>
                if (Targets.JungleMinions.Any() &&
                    GameObjects.Player.ManaPercent
                    > ManaManager.GetNeededMana(Vars.Q.Slot, Vars.Menu["spells"]["q"]["jungleclear"]) &&
                    !Vars.AnyWall(GameObjects.Player.ServerPosition, Targets.JungleMinions[0].ServerPosition) &&
                    Vars.Menu["spells"]["q"]["jungleclear"].GetValue <MenuSliderButton>().BValue)
                {
                    Vars.Q.Cast(Targets.JungleMinions[0].ServerPosition);
                }

                /// <summary>
                ///     The LaneClear Q Logic.
                /// </summary>
                if (Targets.Minions.Any() &&
                    GameObjects.Player.ManaPercent
                    > ManaManager.GetNeededMana(Vars.Q.Slot, Vars.Menu["spells"]["q"]["laneclear"]) &&
                    !Vars.AnyWall(
                        GameObjects.Player.ServerPosition,
                        (Vector3)Vars.Q.GetLineFarmLocation(Targets.Minions, Vars.Q.Width).Position) &&
                    Vars.Menu["spells"]["q"]["laneclear"].GetValue <MenuSliderButton>().BValue)
                {
                    Vars.Q.Cast(Vars.Q.GetLineFarmLocation(Targets.Minions, Vars.Q.Width).Position);
                }
            }
        }
Exemple #5
0
        private void Harass()
        {
            if (!ManaManager.HasMana("Harass"))
            {
                return;
            }

            if (Menu.Item("UseQHarass", true).GetValue <bool>())
            {
                Cast_Q();
            }

            if (Menu.Item("UseWHarass", true).GetValue <bool>())
            {
                Cast_W();
            }

            if (Menu.Item("UseEHarass", true).GetValue <bool>())
            {
                Cast_E();
            }
        }
Exemple #6
0
        private void LaneClear()
        {
            if (ManaManager.HasEnoughMana(Menu.GetSlider("LaneClearMana")) && ManaManager.SpellFarm)
            {
                if (Menu.GetBool("LaneClearQ") && Q.IsReady())
                {
                    var Minions = MinionManager.GetMinions(Me.Position, Q.Range);

                    if (Minions.Any())
                    {
                        var QFarm =
                            MinionManager.GetBestLineFarmLocation(Minions.Select(x => x.Position.To2D()).ToList(),
                                                                  Q.Width, Q.Range);

                        if (QFarm.MinionsHit >= Menu.GetSlider("LaneClearQCount"))
                        {
                            Q.Cast(QFarm.Position);
                        }
                    }
                }
            }
        }
Exemple #7
0
        /// <summary>
        ///     Called when the game updates itself.
        /// </summary>
        /// <param name="args">The <see cref="EventArgs" /> instance containing the event data.</param>
        public static void Harass(EventArgs args)
        {
            if (!Targets.Target.IsValidTarget() || Invulnerable.Check(Targets.Target, DamageType.Magical))
            {
                return;
            }

            /// <summary>
            ///     The Q Harass Logic.
            /// </summary>
            if (Vars.Q.IsReady() &&
                Targets.Target.IsValidTarget(Vars.Q.Range) &&
                GameObjects.Player.HealthPercent
                > ManaManager.GetNeededMana(Vars.Q.Slot, Vars.Menu["spells"]["q"]["harass"]) &&
                Vars.Menu["spells"]["q"]["harass"].GetValue <MenuSliderButton>().BValue)
            {
                if (!Vars.Q.GetPrediction(Targets.Target).CollisionObjects.Any())
                {
                    Vars.Q.Cast(Vars.Q.GetPrediction(Targets.Target).UnitPosition);
                }
            }
        }
Exemple #8
0
        /// <summary>
        ///     Called when the game updates itself.
        /// </summary>
        /// <param name="args">The <see cref="EventArgs" /> instance containing the event data.</param>
        public static void Harass(EventArgs args)
        {
            if (!Targets.Target.IsValidTarget() || Invulnerable.Check(Targets.Target) ||
                Vars.R.Instance.Name.Equals("QuinnRFinale"))
            {
                return;
            }

            /// <summary>
            ///     The Q Harass Logic.
            /// </summary>
            if (Vars.Q.IsReady() && Targets.Target.IsValidTarget(Vars.Q.Range) &&
                GameObjects.Player.ManaPercent
                > ManaManager.GetNeededMana(Vars.Q.Slot, Vars.Menu["spells"]["q"]["harass"]) &&
                Vars.Menu["spells"]["q"]["harass"].GetValue <MenuSliderButton>().BValue)
            {
                if (!Vars.Q.GetPrediction(Targets.Target).CollisionObjects.Any(c => Targets.Minions.Contains(c)))
                {
                    Vars.Q.Cast(Vars.Q.GetPrediction(Targets.Target).UnitPosition);
                }
            }
        }
Exemple #9
0
        /// <summary>
        ///     Fired when the game is updated.
        /// </summary>
        /// <param name="args">The <see cref="EventArgs" /> instance containing the event data.</param>
        public static void Clear(EventArgs args)
        {
            if (Bools.HasSheenBuff())
            {
                return;
            }

            /// <summary>
            ///     The Q LaneClear Logic.
            /// </summary>
            if (Vars.Q.IsReady() &&
                Targets.Minions.Any() &&
                GameObjects.Player.ManaPercent >
                ManaManager.GetNeededMana(Vars.Q.Slot, Vars.getSliderItem(Vars.QMenu, "laneclear")) &&
                Vars.getSliderItem(Vars.QMenu, "laneclear") != 101)
            {
                if (Targets.Minions.Count(m => m.Distance(Targets.Minions[0]) < 200f) >= 3)
                {
                    Vars.Q.Cast(Targets.Minions[0].ServerPosition);
                }
            }
        }
Exemple #10
0
        private void Farm()
        {
            if (!ManaManager.HasMana("LaneClear"))
            {
                return;
            }

            var useQ = Menu.Item("UseQFarm", true).GetValue <bool>();

            var minion = MinionManager.GetMinions(ObjectManager.Player.ServerPosition, Q.Range, MinionTypes.All, MinionTeam.NotAlly);
            var min    = Menu.Item("MinFarm", true).GetValue <Slider>().Value;

            if (useQ)
            {
                var pred = Q.GetLineFarmLocation(minion);

                if (pred.MinionsHit >= min)
                {
                    Q.Cast(pred.Position);
                }
            }
        }
        /// <summary>
        ///     Fired when the game is updated.
        /// </summary>
        public void Harass()
        {
            /// <summary>
            ///     The Q Harass Logic.
            /// </summary>
            if (SpellClass.Q.Ready &&
                UtilityClass.Player.ManaPercent()
                > ManaManager.GetNeededMana(SpellClass.Q.Slot, MenuClass.Spells["q"]["harass"]) &&
                MenuClass.Spells["q"]["harass"].As <MenuSliderBool>().Enabled)
            {
                var bestTarget = Extensions.GetBestEnemyHeroTargetInRange(SpellClass.Q.Range - 200f);
                if (bestTarget != null &&
                    !Invulnerable.Check(bestTarget) &&
                    MenuClass.Spells["q"]["whitelist"][bestTarget.ChampionName.ToLower()].As <MenuBool>().Enabled)
                {
                    SpellClass.Q.Cast(SpellClass.Q.GetPrediction(bestTarget).CastPosition.Extend(UtilityClass.Player.ServerPosition, -100f - bestTarget.BoundingRadius));
                }
            }

            /// <summary>
            ///     The E Harass Logic.
            /// </summary>
            if (SpellClass.E.Ready &&
                MenuClass.Spells["e"]["harass"].As <MenuSliderBool>().Enabled)
            {
                var bestTarget = Extensions.GetBestEnemyHeroTargetInRange(SpellClass.E.Range);
                if (bestTarget != null &&
                    !Invulnerable.Check(bestTarget) &&
                    MenuClass.Spells["e"]["whitelist"][bestTarget.ChampionName.ToLower()].As <MenuBool>().Enabled)
                {
                    if (UtilityClass.Player.HealthPercent() >=
                        MenuClass.Spells["e"]["harass"].As <MenuSliderBool>().Value ||
                        UtilityClass.Player.GetSpellDamage(bestTarget, SpellSlot.E) >= bestTarget.GetRealHealth())
                    {
                        UtilityClass.CastOnUnit(SpellClass.E, bestTarget);
                    }
                }
            }
        }
Exemple #12
0
        private void JungleClear()
        {
            if (ManaManager.HasEnoughMana(Menu.GetSlider("JungleClearMana")) && ManaManager.SpellFarm)
            {
                if (Menu.GetBool("JungleClearE") && E.IsReady())
                {
                    var mob =
                        MinionManager.GetMinions(Me.Position, E.Range, MinionTypes.All, MinionTeam.Neutral,
                                                 MinionOrderTypes.MaxHealth)
                        .FirstOrDefault(
                            x =>
                            !x.Name.ToLower().Contains("mini") && !x.Name.ToLower().Contains("baron") &&
                            !x.Name.ToLower().Contains("dragon") && !x.Name.ToLower().Contains("crab") &&
                            !x.Name.ToLower().Contains("herald"));

                    if (mob != null && mob.IsValidTarget(E.Range))
                    {
                        E.CastOnUnit(mob, true);
                    }
                }
            }
        }
Exemple #13
0
        /// <summary>
        ///     Called on post attack.
        /// </summary>

        /// <param name="args">The <see cref="OnPostAttackEventArgs" /> instance containing the event data.</param>
        public void Jungleclear(OnPostAttackEventArgs args)
        {
            var jungleTarget = args.Target as AIMinionClient;

            if (!jungleTarget.IsValidTarget() ||
                !Extensions.GetGenericJungleMinionsTargets().Contains(jungleTarget))
            {
                return;
            }

            /// <summary>
            ///     The Jungleclear Q Logics.
            /// </summary>
            if (SpellClass.Q.Ready &&
                !HasFourthShot() &&
                UtilityClass.Player.MPPercent()
                > ManaManager.GetNeededMana(SpellClass.Q.Slot, MenuClass.Q["jungleclear"]) &&
                MenuClass.Q["jungleclear"].As <MenuSliderBool>().Enabled)
            {
                SpellClass.Q.CastOnUnit(jungleTarget);
            }
        }
Exemple #14
0
 /// <summary>
 ///     Called on do-cast.
 /// </summary>
 /// <param name="args">The <see cref="OnPostAttackEventArgs" /> instance containing the event data.</param>
 public void Laneclear(OnPostAttackEventArgs args)
 {
     /// <summary>
     ///     The Q FarmHelper Logic.
     /// </summary>
     if (SpellClass.Q.Ready &&
         UtilityClass.Player.MPPercent()
         > ManaManager.GetNeededMana(SpellClass.Q.Slot, MenuClass.Q["farmhelper"]) &&
         MenuClass.Q["farmhelper"].Enabled)
     {
         var posAfterQ = UtilityClass.Player.Position.Extend(Hud.CursorPositionUnclipped, 300f);
         if (Extensions.GetEnemyLaneMinionsTargetsInRange(SpellClass.Q.Range)
             .Any(m =>
                  m.Distance(posAfterQ) < UtilityClass.Player.GetAutoAttackRange() &&
                  m != Orbwalker.GetOrbwalkingTarget() &&
                  posAfterQ.EnemyHeroesCount(UtilityClass.Player.GetAutoAttackRange(m)) <= 2 &&
                  m.HP <= UtilityClass.Player.GetAutoAttackDamage(m) + GetQBonusDamage(m)))
         {
             SpellClass.Q.Cast(Hud.CursorPositionUnclipped);
         }
     }
 }
        /// <summary>
        ///     Called on tick update.
        /// </summary>
        public void Jungleclear()
        {
            var jungleTarget = ObjectManager.Get <Obj_AI_Minion>().FirstOrDefault(m => Extensions.GetGenericJungleMinionsTargets().Contains(m));

            if (jungleTarget == null)
            {
                return;
            }

            /// <summary>
            ///     The Jungleclear Q Logics.
            /// </summary>
            if (SpellClass.Q.Ready &&
                jungleTarget.IsValidTarget(SpellClass.Q.Range) &&
                UtilityClass.Player.ManaPercent()
                > ManaManager.GetNeededMana(SpellClass.Q.Slot, MenuClass.Spells["q"]["jungleclear"]) &&
                MenuClass.Spells["q"]["jungleclear"].As <MenuSliderBool>().Enabled)
            {
                SpellClass.Q.CastOnUnit(jungleTarget);
            }

            if (jungleTarget.GetRealHealth() < UtilityClass.Player.GetAutoAttackDamage(jungleTarget) * 4)
            {
                return;
            }

            /// <summary>
            ///     The Jungleclear E Logics.
            /// </summary>
            if (SpellClass.E.Ready &&
                jungleTarget.IsValidTarget(SpellClass.E.Range) &&
                UtilityClass.Player.ManaPercent()
                > ManaManager.GetNeededMana(SpellClass.E.Slot, MenuClass.Spells["e"]["jungleclear"]) &&
                MenuClass.Spells["e"]["jungleclear"].As <MenuSliderBool>().Enabled)
            {
                SpellClass.E.Cast(jungleTarget);
            }
        }
Exemple #16
0
        /// <summary>
        ///     Fired when the game is updated.
        /// </summary>
        /// <param name="args">The <see cref="EventArgs" /> instance containing the event data.</param>
        public static void Clear(EventArgs args)
        {
            if (Bools.HasSheenBuff())
            {
                return;
            }

            /// <summary>
            ///     The Q Clear Logics.
            /// </summary>
            if (Vars.Q.IsReady() &&
                GameObjects.Player.HealthPercent >
                ManaManager.GetNeededHealth(Vars.Q.Slot, Vars.getSliderItem(Vars.QMenu, "clear")) &&
                Vars.getSliderItem(Vars.QMenu, "clear") != 101)
            {
                /// <summary>
                ///     The Q LaneClear Logic.
                /// </summary>
                if (Targets.Minions.Any())
                {
                    foreach (var minion in Targets.Minions.Where(m => Vars.GetRealHealth(m) < (float)GameObjects.Player.LSGetSpellDamage(m, SpellSlot.Q)))
                    {
                        if (!Vars.Q.GetPrediction(minion).CollisionObjects.Any(c => Targets.Minions.Contains(c)))
                        {
                            Vars.Q.Cast(Vars.Q.GetPrediction(minion).UnitPosition);
                        }
                    }
                }

                /// <summary>
                ///     The Q JungleClear Logic.
                /// </summary>
                else if (Targets.JungleMinions.Any())
                {
                    Vars.Q.Cast(Targets.JungleMinions[0].ServerPosition);
                }
            }
        }
Exemple #17
0
        private void JungleClear()
        {
            if (!ManaManager.HasMana("Jungle"))
            {
                return;
            }

            var JungleQ = MinionManager.GetMinions(Player.Position, 1100, MinionTypes.All, MinionTeam.Neutral,
                                                   MinionOrderTypes.MaxHealth);

            var useQ = Menu.Item("UseQJungle", true).GetValue <bool>();
            var useW = Menu.Item("UseWJungle", true).GetValue <bool>();

            if (JungleQ.Any())
            {
                var o = JungleQ.FirstOrDefault();

                if (o == null)
                {
                    return;
                }

                if (soldierCount() > 0)
                {
                    if (useQ && Q.IsReady())
                    {
                        Q.Cast(o.Position);
                    }
                }
                else
                {
                    if (useW && W.IsReady() && JungleQ.Count(x => x.Distance(Player) <= W.Range) > 0)
                    {
                        W.Cast(o.Position);
                    }
                }
            }
        }
        /// <summary>
        ///     Fired when the game is updated.
        /// </summary>
        public void JungleClear()
        {
            /// <summary>
            ///     The E Jungleclear Logic.
            /// </summary>
            if (SpellClass.E.Ready &&
                UtilityClass.Player.Level() >=
                MenuClass.E["junglesteal"].Value &&
                MenuClass.E["junglesteal"].Enabled)
            {
                if (Extensions.GetGenericJungleMinionsTargets()
                    .Any(m => IsPerfectRendTarget(m) && m.HP <= GetEDamage(m) && MenuClass.E["whitelist"][m.ModelName.ToLower()].Enabled))
                {
                    SpellClass.E.Cast();
                }
            }

            var jungleTarget = Extensions.GetGenericJungleMinionsTargets()
                               .MinBy(m => Hud.CursorPositionUnclipped.DistanceToPlayer());

            if (jungleTarget == null ||
                jungleTarget.HP < UtilityClass.Player.GetAutoAttackDamage(jungleTarget) * 3)
            {
                return;
            }

            /// <summary>
            ///     The Q Jungleclear Logic.
            /// </summary>
            if (SpellClass.Q.Ready &&
                jungleTarget.IsValidTarget(SpellClass.Q.Range) &&
                UtilityClass.Player.MPPercent()
                > ManaManager.GetNeededMana(SpellClass.Q.Slot, MenuClass.Q["jungleclear"]) &&
                MenuClass.Q["jungleclear"].Enabled)
            {
                SpellClass.Q.Cast(jungleTarget);
            }
        }
        /// <summary>
        ///     Called on post attack.
        /// </summary>
        /// <param name="sender">The sender.</param>
        /// <param name="args">The <see cref="PreAttackEventArgs" /> instance containing the event data.</param>
        public void Jungleclear(object sender, PreAttackEventArgs args)
        {
            var jungleTarget = args.Target as Obj_AI_Minion;

            if (!HasFourthShot() ||
                !jungleTarget.IsValidTarget() ||
                !Extensions.GetGenericJungleMinionsTargets().Contains(jungleTarget))
            {
                return;
            }

            /// <summary>
            ///     The Jungleclear Q Logics.
            /// </summary>
            if (SpellClass.Q.Ready &&
                UtilityClass.Player.ManaPercent()
                > ManaManager.GetNeededMana(SpellClass.Q.Slot, MenuClass.Spells["q"]["jungleclear"]) &&
                MenuClass.Spells["q"]["jungleclear"].As <MenuSliderBool>().Enabled)
            {
                SpellClass.Q.CastOnUnit(jungleTarget);
            }

            if (jungleTarget?.GetRealHealth() < UtilityClass.Player.GetAutoAttackDamage(jungleTarget) * 2)
            {
                return;
            }

            /// <summary>
            ///     The Jungleclear E Logics.
            /// </summary>
            if (SpellClass.E.Ready &&
                UtilityClass.Player.ManaPercent()
                > ManaManager.GetNeededMana(SpellClass.E.Slot, MenuClass.Spells["e"]["jungleclear"]) &&
                MenuClass.Spells["e"]["jungleclear"].As <MenuSliderBool>().Enabled)
            {
                SpellClass.E.Cast(jungleTarget);
            }
        }
Exemple #20
0
        public virtual void Update(Orbwalking.OrbwalkingMode mode, IMainContext context, ComboProvider combo, AIHeroClient target)
        {
            if (mode == Orbwalking.OrbwalkingMode.None)
            {
                return;
            }
            if (mode == Orbwalking.OrbwalkingMode.LaneClear && SwitchClearToHarassOnTarget && target != null && HarassEnabled)
            {
                mode = Orbwalking.OrbwalkingMode.Mixed;
            }
            if (UseManaManager && !ManaManager.CanUseMana(mode))
            {
                return;
            }
            switch (mode)
            {
            case Orbwalking.OrbwalkingMode.Combo:
                if (ComboEnabled)
                {
                    Combo(context, combo, target);
                }
                break;

            case Orbwalking.OrbwalkingMode.LaneClear:
                if (LaneclearEnabled)
                {
                    LaneClear(context, combo, target);
                }
                break;

            case Orbwalking.OrbwalkingMode.Mixed:
                if (HarassEnabled)
                {
                    Harass(context, combo, target);
                }
                break;
            }
        }
Exemple #21
0
        /// <summary>
        ///     Fired when the game is updated.
        /// </summary>
        /// <param name="args">The <see cref="EventArgs" /> instance containing the event data.</param>
        public static void Clear(EventArgs args)
        {
            if (Bools.HasSheenBuff())
            {
                return;
            }

            /// <summary>
            ///     The Q Clear Logics.
            /// </summary>
            if (Vars.Q.IsReady())
            {
                var farmLocation = Vars.Q.GetCircularFarmLocation(Targets.Minions, Vars.Q.Width);

                /// <summary>
                ///     The JungleClear Q Logic.
                /// </summary>
                if (Targets.JungleMinions.Any() &&
                    GameObjects.Player.ManaPercent
                    > ManaManager.GetNeededMana(Vars.Q.Slot, Vars.Menu["spells"]["q"]["jungleclear"]) &&
                    Vars.Menu["spells"]["q"]["jungleclear"].GetValue <MenuSliderButton>().BValue)
                {
                    Vars.Q.Cast(Targets.JungleMinions[0].ServerPosition);
                }

                /// <summary>
                ///     The LaneClear Q Logic.
                /// </summary>
                else if (Targets.Minions.Any() &&
                         GameObjects.Player.ManaPercent
                         > ManaManager.GetNeededMana(Vars.Q.Slot, Vars.Menu["spells"]["q"]["laneclear"]) &&
                         Vars.Menu["spells"]["q"]["laneclear"].GetValue <MenuSliderButton>().BValue &&
                         farmLocation.MinionsHit >= 1)
                {
                    Vars.Q.Cast(farmLocation.Position);
                }
            }
        }
Exemple #22
0
        /// <summary>
        ///     Fired when the game is updated.
        /// </summary>
        /// <param name="args">The <see cref="EventArgs" /> instance containing the event data.</param>
        public static void Clear(EventArgs args)
        {
            if (Bools.HasSheenBuff())
            {
                return;
            }

            /// <summary>
            ///     The E Clear Logics.
            /// </summary>
            if (Vars.E.IsReady())
            {
                /// <summary>
                ///     The E JungleClear Logic.
                /// </summary>
                if (Targets.JungleMinions.Any() &&
                    GameObjects.Player.ManaPercent
                    > ManaManager.GetNeededMana(Vars.E.Slot, Vars.Menu["spells"]["e"]["jungleclear"]) &&
                    Vars.Menu["spells"]["e"]["jungleclear"].GetValue <MenuSliderButton>().BValue)
                {
                    Vars.E.Cast();
                }

                /// <summary>
                ///     The E LaneClear Logic.
                /// </summary>
                else if (Targets.Minions.Any() &&
                         GameObjects.Player.ManaPercent
                         > ManaManager.GetNeededMana(Vars.E.Slot, Vars.Menu["spells"]["e"]["laneclear"]) &&
                         Vars.Menu["spells"]["e"]["laneclear"].GetValue <MenuSliderButton>().BValue)
                {
                    if (Targets.Minions.Count(m => m.IsValidTarget(Vars.E.Range)) >= 3)
                    {
                        Vars.E.Cast();
                    }
                }
            }
        }
Exemple #23
0
        /// <summary>
        ///     Fired when the game is updated.
        /// </summary>
        /// <param name="args">The <see cref="EventArgs" /> instance containing the event data.</param>
        public static void Clear(EventArgs args)
        {
            /// <summary>
            ///     The Clear E Logics.
            /// </summary>
            if (Vars.E.IsReady() &&
                GameObjects.Player.ManaPercent
                > ManaManager.GetNeededMana(Vars.Q.Slot, Vars.Menu["spells"]["q"]["clear"]) &&
                Vars.Menu["spells"]["e"]["clear"].GetValue <MenuSliderButton>().BValue)
            {
                /// <summary>
                ///     The LaneClear E Logic.
                /// </summary>
                if (Targets.Minions.Count >= 3 && GameObjects.Player.CountEnemyHeroesInRange(2000f) == 0)
                {
                    Vars.E.Cast();
                }

                /// <summary>
                ///     The JungleClear E Logic.
                /// </summary>
                else if (Targets.JungleMinions.Any(m => m.IsValidTarget(Vars.E.Range)))
                {
                    Vars.E.Cast();
                }
            }

            /// <summary>
            ///     The Q JungleGrab Logic.
            /// </summary>
            if (Vars.Q.IsReady() && Targets.JungleMinions.Any(m => !m.IsValidTarget(Vars.E.Range)) &&
                GameObjects.Player.ManaPercent
                > ManaManager.GetNeededMana(Vars.Q.Slot, Vars.Menu["spells"]["q"]["junglegrab"]) &&
                Vars.Menu["spells"]["q"]["junglegrab"].GetValue <MenuSliderButton>().BValue)
            {
                Vars.Q.CastOnUnit(Targets.JungleMinions.FirstOrDefault(m => !m.IsValidTarget(Vars.E.Range)));
            }
        }
Exemple #24
0
        /// <summary>
        ///     Fired when the game is updated.
        /// </summary>
        /// <param name="args">The <see cref="EventArgs" /> instance containing the event data.</param>
        public static void Clear(EventArgs args)
        {
            if (Bools.HasSheenBuff())
            {
                return;
            }

            /// <summary>
            ///     The Clear Q Logics.
            /// </summary>
            if (Vars.Q.IsReady() &&
                GameObjects.Player.ManaPercent >
                ManaManager.GetNeededMana(Vars.Q.Slot, Vars.getSliderItem(Vars.QMenu, "clear")) &&
                Vars.getSliderItem(Vars.QMenu, "clear") != 101)
            {
                /// <summary>
                ///     The JungleClear Q Logic.
                /// </summary>
                if (Targets.JungleMinions.Any())
                {
                    Vars.Q.Cast(Targets.JungleMinions[0].ServerPosition);
                }

                /// <summary>
                ///     The LaneClear Q Logic.
                /// </summary>
                else if (!GameObjects.EnemyHeroes.Any(
                             t =>
                             !Invulnerable.Check(t) &&
                             t.LSIsValidTarget(Vars.Q.Range + 100f)))
                {
                    if (Vars.Q.GetLineFarmLocation(Targets.Minions, Vars.Q.Width).MinionsHit >= 3)
                    {
                        Vars.Q.Cast(Vars.Q.GetLineFarmLocation(Targets.Minions, Vars.Q.Width).Position);
                    }
                }
            }
        }
Exemple #25
0
        private void UseSpells(bool useQ, bool useW, string source)
        {
            if (source == "Harass" && !ManaManager.HasMana("Harass"))
            {
                return;
            }

            //items
            if (source == "Combo")
            {
                var itemTarget = TargetSelector.GetTarget(750, TargetSelector.DamageType.Physical);
                if (itemTarget != null)
                {
                    var dmg = GetComboDamage(itemTarget);
                    ItemManager.Target = itemTarget;

                    //see if killable
                    if (dmg > itemTarget.Health - 50)
                    {
                        ItemManager.KillableTarget = true;
                    }

                    ItemManager.UseTargetted = true;
                }
            }

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

            if ((target != null && source == "Combo") && menu.Item("Always_Use", true).GetValue <bool>())
            {
                return;
            }

            if (useW && W.IsReady())
            {
                W.CastIfHitchanceEquals(target, HitChance.High);
            }
        }
Exemple #26
0
        /// <summary>
        ///     Called when the game updates itself.
        /// </summary>
        /// <param name="args">The <see cref="EventArgs" /> instance containing the event data.</param>
        public static void Harass(EventArgs args)
        {
            if (!Targets.Target.LSIsValidTarget() ||
                Invulnerable.Check(Targets.Target))
            {
                return;
            }

            /// <summary>
            ///     The W Harass Logic.
            /// </summary>
            if (Vars.W.IsReady() &&
                Targets.Target.LSIsValidTarget(Vars.W.Range) &&
                GameObjects.Player.ManaPercent >
                ManaManager.GetNeededMana(Vars.W.Slot, Vars.getSliderItem(Vars.WMenu, "harass")) &&
                Vars.getSliderItem(Vars.WMenu, "harass") != 101)
            {
                if (!Vars.W.GetPrediction(Targets.Target).CollisionObjects.Any())
                {
                    Vars.W.Cast(Vars.W.GetPrediction(Targets.Target).UnitPosition);
                }
            }
        }
Exemple #27
0
        /// <summary>
        ///     Called OnPostAttack.
        /// </summary>
        /// <param name="sender">The sender.</param>
        /// <param name="args">The <see cref="PostAttackEventArgs" /> instance containing the event data.</param>
        public void Harass(object sender, PostAttackEventArgs args)
        {
            var heroTarget = args.Target as Obj_AI_Hero;

            if (heroTarget == null || Invulnerable.Check(heroTarget))
            {
                return;
            }

            /// <summary>
            ///     The W Harass Weaving Logic.
            /// </summary>
            if (SpellClass.W.Ready &&
                UtilityClass.Player.ManaPercent()
                > ManaManager.GetNeededMana(SpellClass.W.Slot, MenuClass.Spells["w"]["harass"]) &&
                MenuClass.Spells["w"]["harass"].As <MenuSliderBool>().Enabled)
            {
                if (MenuClass.Spells["w"]["whitelist"][heroTarget.ChampionName.ToLower()].As <MenuBool>().Enabled)
                {
                    SpellClass.W.Cast();
                }
            }
        }
Exemple #28
0
        /// <summary>
        ///     Called before casting a spell.
        /// </summary>
        /// <param name="sender">The sender.</param>
        /// <param name="args">The <see cref="SpellbookCastSpellEventArgs" /> instance containing the event data.</param>
        public static void Automatic(Spellbook sender, SpellbookCastSpellEventArgs args)
        {
            /// <summary>
            ///     The Q Switching Logics.
            /// </summary>
            if (Vars.Q.IsReady() && Vars.Menu["miscellaneous"]["blockq"].GetValue <MenuBool>().Value)
            {
                if (GameObjects.Player.HasBuff("JinxQ"))
                {
                    return;
                }

                /// <summary>
                ///     Block if:
                ///     It doesn't respect the ManaManager Check, (Mana check),
                /// </summary>
                if (GameObjects.Player.ManaPercent
                    < ManaManager.GetNeededMana(Vars.W.Slot, Vars.Menu["spells"]["q"]["clear"]))
                {
                    args.Process = false;
                }
            }
        }
        private static void JungleClear(GameObjectProcessSpellCastEventArgs Args)
        {
            if (Args.SData == null || !Orbwalking.IsAutoAttack(Args.SData.Name) || Args.Target == null ||
                !Orbwalking.isLaneClear || Args.Target.Type != GameObjectType.obj_AI_Minion ||
                !ManaManager.HasEnoughMana(Menu.GetSlider("JungleClearMana")) || !ManaManager.SpellFarm)
            {
                return;
            }

            var mobs = MinionManager.GetMinions(Orbwalking.GetRealAutoAttackRange(Me), MinionTypes.All,
                                                MinionTeam.Neutral, MinionOrderTypes.MaxHealth);
            var mob = mobs.FirstOrDefault();

            if (mob != null)
            {
                SpellManager.CastItem();

                if (Menu.GetBool("JungleClearW") && W.IsReady() && Orbwalking.InAutoAttackRange(Me))
                {
                    W.Cast(true);
                }
            }
        }
Exemple #30
0
        private void Farm()
        {
            if (!ManaManager.HasMana("LaneClear"))
            {
                return;
            }

            List <Obj_AI_Base> allMinionsE = MinionManager.GetMinions(Player.ServerPosition, Player.AttackRange + Player.BoundingRadius,
                                                                      MinionTypes.All, MinionTeam.NotAlly);

            var useQ = menu.Item("UseQFarm", true).GetValue <bool>();
            var useE = menu.Item("UseEFarm", true).GetValue <bool>();

            if (useQ)
            {
                Cast_Q_Last_Hit();
            }

            if (useE && allMinionsE.Count > 0 && E.IsReady())
            {
                E.Cast();
            }
        }