Beispiel #1
0
        public static void WtfSec()
        {
            var target = EnemyTarget;

            Orbwalker.OrbwalkTo(target.Position);

            if (target == null || !target.IsValidTarget())
            {
                return;
            }
            var allyPos = Game.CursorPos;

            if (InsecPos == new Vector3())
            {
                var insecPos = allyPos.Extend(target.Position, target.Distance(allyPos) + InsecMenu["insecDistance"].Cast <Slider>().CurrentValue);
                InsecPos   = insecPos.To3D();
                LastUpdate = Environment.TickCount;
            }
            var jumpPos = InsecTarget.Position.Extend(_Player.Position, 130).To3D();

            if (InsecTarget.HasBuffOfType(BuffType.Knockback) && InsecTarget.HasQBuff() && Program.Q.IsReady() &&
                Program.Q.Instance().Name == Program.Spells["Q2"])
            {
                Core.DelayAction(delegate
                {
                    Program.Q2.Cast();
                }
                                 , 600);
            }
            if (!Program.R.IsReady())
            {
                return;
            }
            if (_Player.Distance(InsecTarget) < Program.R.Range && _Player.Distance(InsecPos) < 400)
            {
                Program.R.Cast(InsecTarget);
                Core.DelayAction(delegate
                {
                    var spell = _Player.Spellbook.Spells.FirstOrDefault(a => a.Name.ToLower().Contains("summonerflash"));
                    if (spell == null || !spell.IsReady)
                    {
                        return;
                    }
                    _Player.Spellbook.CastSpell(spell.Slot, InsecPos);
                }, 200);
            }
            else if (Program.Q.Instance().Name == Program.Spells["Q1"] && Program.Q.IsReady())
            {
                SpellClass.SmiteQCast(InsecTarget);
                Program.LastSpellTime = Environment.TickCount;
            }
            else if (jumpPos.Distance(_Player.Position) < 600)
            {
                WardJumper.WardJump(jumpPos, false, true);
            }
        }
Beispiel #2
0
        public static void Insec()
        {
            var target = EnemyTarget;

            Orbwalker.OrbwalkTo(InsecMenu["insecPositionMode"].Cast <Slider>().CurrentValue == 1 && target != null || GetBestInsecPos() == Game.CursorPos && target != null ? target.Position : Game.CursorPos);


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

            if (InsecPos == new Vector3())
            {
                var insecPos = allyPos.Extend(target.Position, target.Distance(allyPos) + InsecMenu["insecDistance"].Cast <Slider>().CurrentValue).To3D();
                InsecPos   = insecPos;
                LastUpdate = Environment.TickCount;
            }
            if (!Program.R.IsReady())
            {
                StateManager.Combo();
                return;
            }

            if (_Player.Distance(InsecPos) < 200)
            {
                Program.R.Cast(target);
                return;
            }
            if (_Player.Distance(InsecPos) < 600)
            {
                if (WardJumper.GetWardSlot() == null && InsecPos.Distance(_Player.Position) < 400 &&
                    WardJumper.LastWard + 1000 < Environment.TickCount)
                {
                    var spell =
                        _Player.Spellbook.Spells.FirstOrDefault(a => a.Name.ToLower().Contains("summonerflash"));
                    if (InsecMenu["useFlash"].Cast <CheckBox>().CurrentValue&& spell != null && spell.IsReady)
                    {
                        _Player.Spellbook.CastSpell(spell.Slot, InsecPos);
                        return;
                    }
                }
                WardJumper.WardJump(InsecPos, false, true);
            }
            if (Program.Q.Instance().Name == Program.Spells["Q2"] && Extended.BuffedEnemy != null &&
                (Extended.BuffedEnemy.Distance(_Player) < 1400 && Program.Q.IsReady() &&
                 (target.HasQBuff() || Extended.BuffedEnemy.Distance(InsecPos) < 600)))
            {
                Program.Q2.Cast();
            }
            if (Program.Q.Instance().Name == Program.Spells["Q1"] && Program.Q.IsReady() && target.Distance(_Player) < Program.Q.Range)
            {
                if (!SpellClass.SmiteQCast(target) && InsecMenu["checkAllUnits"].Cast <CheckBox>().CurrentValue)
                {
                    foreach (
                        var unit in
                        EntityManager.MinionsAndMonsters.EnemyMinions.Where(
                            a => a.Distance(_Player) < Program.Q.Range && a.Distance(InsecPos) < 550)
                        )
                    {
                        var pred = Program.Q.GetPrediction(unit);
                        if (pred.HitChance > HitChance.Medium)
                        {
                            continue;
                        }
                        Program.Q.Cast(pred.CastPosition);
                        break;
                    }
                }
            }
        }