Ejemplo n.º 1
0
        private static void Star()
        {
            var target = (IsQOne ? Q : Q2).GetTarget();

            Orbwalker.Orbwalk(target.InAutoAttackRange() ? target : null);
            if (target == null)
            {
                return;
            }
            if (Q.IsReady())
            {
                if (IsQOne)
                {
                    var pred = Q.VPrediction(target);
                    if (pred.Hitchance == HitChance.Collision)
                    {
                        if (MainMenu["Orbwalk"]["QCol"] && Smite.IsReady() &&
                            pred.CollisionObjects.All(i => i.NetworkId != Player.NetworkId))
                        {
                            var col = pred.CollisionObjects.Cast <Obj_AI_Minion>().ToList();
                            if (col.Count == 1 &&
                                col.Any(i => i.Health <= GetSmiteDmg && Player.Distance(i) < SmiteRange) &&
                                Player.Spellbook.CastSpell(Smite, col.First()))
                            {
                                Q.Cast(pred.CastPosition);
                                return;
                            }
                        }
                    }
                    else if (pred.Hitchance >= Q.MinHitChance && Q.Cast(pred.CastPosition))
                    {
                        return;
                    }
                }
                else if (HaveQ(target) &&
                         (target.Health + target.PhysicalShield
                          <= Player.GetSpellDamage(target, SpellSlot.Q, Damage.DamageStage.SecondCast)
                          + Player.GetAutoAttackDamage(target, true) || (!target.InAutoAttackRange() && CanR)) &&
                         Q.Cast())
                {
                    return;
                }
            }
            if (!R.IsReady() || !Q.IsReady() || IsQOne || !HaveQ(target))
            {
                return;
            }
            if (R.IsInRange(target))
            {
                R.CastOnUnit(target);
            }
            else if (Player.Distance(target) <= W.Range + R.Range - 100 && Player.Mana >= 60)
            {
                Flee(
                    Prediction.GetPrediction(target, W.Delay, 1, W.Speed)
                    .CastPosition.Extend(Player.Position, R.Range - 150),
                    true);
            }
        }
Ejemplo n.º 2
0
        private static void OnUpdate(EventArgs args)
        {
            if (Player.IsDead || MenuGUI.IsChatOpen || MenuGUI.IsShopOpen || Player.IsRecalling())
            {
                return;
            }
            KillSteal();
            switch (Orbwalker.ActiveMode)
            {
            case OrbwalkingMode.Combo:
                Combo();
                break;

            case OrbwalkingMode.LastHit:
                Farm();
                break;

            case OrbwalkingMode.None:
                if (MainMenu["FleeW"].GetValue <MenuKeyBind>().Active)
                {
                    Orbwalker.MoveOrder(Game.CursorPos);
                    Flee(Game.CursorPos);
                }
                else if (MainMenu["Orbwalk"]["Star"].GetValue <MenuKeyBind>().Active)
                {
                    Star();
                }
                else if (MainMenu["Insec"]["Normal"].GetValue <MenuKeyBind>().Active)
                {
                    Orbwalker.MoveOrder(Game.CursorPos);
                    if (Insec.NormalReady)
                    {
                        Insec.DoNormal();
                    }
                }
                else if (MainMenu["Insec"]["Advanced"].GetValue <MenuKeyBind>().Active)
                {
                    Orbwalker.MoveOrder(Game.CursorPos);
                    if (Insec.AdvancedReady)
                    {
                        Insec.DoAdvanced();
                    }
                }
                break;
            }
        }
Ejemplo n.º 3
0
        private static void OnUpdate(EventArgs args)
        {
            if (Player.IsDead || MenuGUI.IsChatOpen || MenuGUI.IsShopOpen || Player.IsRecalling())
            {
                return;
            }
            KillSteal();
            switch (Orbwalker.ActiveMode)
            {
            case OrbwalkingMode.Combo:
                Combo();
                break;

            case OrbwalkingMode.Hybrid:
                Hybrid();
                break;

            case OrbwalkingMode.LastHit:
                Farm();
                break;

            case OrbwalkingMode.None:
                if (MainMenu["FleeW"].GetValue <MenuKeyBind>().Active)
                {
                    Orbwalker.MoveOrder(Game.CursorPos);
                    if (W.IsReady())
                    {
                        W.Cast(Game.CursorPos);
                    }
                }
                break;
            }
            if (Orbwalker.ActiveMode != OrbwalkingMode.Combo && Orbwalker.ActiveMode != OrbwalkingMode.Hybrid)
            {
                AutoQ();
            }
        }
Ejemplo n.º 4
0
        private static void Combo()
        {
            if (MainMenu["Orbwalk"]["R"] && R.IsReady())
            {
                foreach (var hero in
                         GameObjects.EnemyHeroes.Where(
                             i =>
                             i.IsValidTarget(R.Range) && i.Health + i.PhysicalShield > Player.GetSpellDamage(i, SpellSlot.R))
                         .OrderBy(i => i.Distance(Player)))
                {
                    var rect = new Rectangle(
                        hero.ServerPosition,
                        hero.ServerPosition.Extend(Player.ServerPosition, -RKickRange),
                        hero.BoundingRadius * 2);
                    var heroBehind =
                        (from behind in
                         GameObjects.EnemyHeroes.Where(
                             i =>
                             i.IsValidTarget(RKickRange, true, hero.ServerPosition) && i.NetworkId != hero.NetworkId)
                         let predPos = Prediction.GetPrediction(behind, R.Delay, 1, R.Speed).UnitPosition
                                       where rect.IsInside(predPos)
                                       select behind).ToList();
                    if (heroBehind.Count == 0)
                    {
                        break;
                    }
                    if (MainMenu["Orbwalk"]["RKill"] &&
                        heroBehind.Any(i => i.Health + i.PhysicalShield <= Player.GetSpellDamage(i, SpellSlot.R)) &&
                        R.CastOnUnit(hero))
                    {
                        return;
                    }
                    if (heroBehind.Count >= MainMenu["Orbwalk"]["RCountA"] && R.CastOnUnit(hero))
                    {
                        return;
                    }
                }
            }
            if (MainMenu["Orbwalk"]["Q"] && Q.IsReady() && CanCastInOrbwalk)
            {
                if (IsQOne)
                {
                    var target = Q.GetTarget();
                    if (target != null)
                    {
                        var pred = Q.VPrediction(target);
                        if (pred.Hitchance == HitChance.Collision)
                        {
                            if (MainMenu["Orbwalk"]["QCol"] && Smite.IsReady() &&
                                pred.CollisionObjects.All(i => i.NetworkId != Player.NetworkId))
                            {
                                var col = pred.CollisionObjects.Cast <Obj_AI_Minion>().ToList();
                                if (col.Count == 1 &&
                                    col.Any(i => i.Health <= GetSmiteDmg && Player.Distance(i) < SmiteRange) &&
                                    Player.Spellbook.CastSpell(Smite, col.First()))
                                {
                                    Q.Cast(pred.CastPosition);
                                    return;
                                }
                            }
                        }
                        else if (pred.Hitchance >= Q.MinHitChance && Q.Cast(pred.CastPosition))
                        {
                            return;
                        }
                    }
                }
                else if (MainMenu["Orbwalk"]["Q2"])
                {
                    var target = GameObjects.EnemyHeroes.FirstOrDefault(i => i.IsValidTarget(Q2.Range) && HaveQ(i));
                    if (target != null)
                    {
                        if ((CanQ2(target) || (!target.InAutoAttackRange() && CanR) ||
                             target.Health + target.PhysicalShield
                             <= Player.GetSpellDamage(target, SpellSlot.Q, Damage.DamageStage.SecondCast)
                             + Player.GetAutoAttackDamage(target, true) ||
                             Player.Distance(target) > target.GetRealAutoAttackRange() + 100 || Passive == -1) &&
                            Q.Cast())
                        {
                            return;
                        }
                    }
                    else if (GetQObj != null)
                    {
                        var q2Target = Q2.GetTarget();
                        if (q2Target != null && GetQObj.Distance(q2Target) < Player.Distance(q2Target) &&
                            !q2Target.InAutoAttackRange() && Q.Cast())
                        {
                            return;
                        }
                    }
                }
            }
            if (MainMenu["Orbwalk"]["E"] && E.IsReady() && CanCastInOrbwalk)
            {
                if (IsEOne)
                {
                    if (E.GetTarget() != null && Player.Mana >= 70 && E.Cast())
                    {
                        return;
                    }
                }
                else
                {
                    var e2Target = GameObjects.EnemyHeroes.Where(i => i.IsValidTarget(E2.Range) && HaveE(i)).ToList();
                    if ((e2Target.Any(i => CanE2(i) || Player.Distance(i) > i.GetRealAutoAttackRange() + 50) ||
                         e2Target.Count > 2 || Passive == -1) && E.Cast())
                    {
                        return;
                    }
                }
            }
            if (MainMenu["Orbwalk"]["W"] && W.IsReady() && CanCastInOrbwalk &&
                Variables.TickCount - W.LastCastAttemptT >= 300 && !E.IsReady() && Passive == -1 &&
                Orbwalker.GetTarget(OrbwalkingMode.Combo) != null && W.Cast())
            {
                return;
            }
            var subTarget = W.GetTarget();

            if (MainMenu["Orbwalk"]["Item"])
            {
                UseItem(subTarget);
            }
            if (subTarget == null)
            {
                return;
            }
            if (MainMenu["Orbwalk"]["Ignite"] && Ignite.IsReady() && subTarget.HealthPercent < 30 &&
                Player.Distance(subTarget) <= IgniteRange)
            {
                Player.Spellbook.CastSpell(Ignite, subTarget);
            }
        }