Ejemplo n.º 1
0
        private void LastHitQ()
        {
            if (!config.Item("useqLH", true).GetValue <bool>() || CanQ2)
            {
                return;
            }
            var targ =
                MinionManager.GetMinions(E.Range, MinionTypes.All, MinionTeam.NotAlly)
                .FirstOrDefault(
                    o =>
                    o.IsInAttackRange(50) && o.IsValidTarget() &&
                    HealthPrediction.GetHealthPrediction(o, 600) <
                    Q.GetDamage(o) + player.GetAutoAttackDamage(o, true));

            if (targ != null)
            {
                if (Q.IsReady() && orbwalker.ActiveMode != Orbwalking.OrbwalkingMode.LaneClear)
                {
                    Q.Cast();
                    Orbwalking.ResetAutoAttackTimer();
                }
                else if (targ.Health < Q.GetDamage(targ) + player.GetAutoAttackDamage(targ, true))
                {
                    orbwalker.ForceTarget(targ);
                }
            }
        }
Ejemplo n.º 2
0
 private static void AfterAttack(AttackableUnit unit, AttackableUnit target)
 {
     if (unit.IsMe && E.IsReady() && orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && config.Item("usee").GetValue <bool>() && target.IsEnemy && target.Team != player.Team)
     {
         E.Cast(config.Item("packets").GetValue <bool>());
         Orbwalking.ResetAutoAttackTimer();
     }
 }
Ejemplo n.º 3
0
 private void AfterAttack(AttackableUnit unit, AttackableUnit target)
 {
     if (unit.IsMe && orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && W.IsReady() &&
         config.Item("usew", true).GetValue <bool>())
     {
         W.Cast(config.Item("packets").GetValue <bool>());
         Orbwalking.ResetAutoAttackTimer();
     }
 }
Ejemplo n.º 4
0
 private static void AfterAttack(AttackableUnit unit, AttackableUnit target)
 {
     if (unit.IsMe && Q.IsReady() && ((orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && config.Item("useq").GetValue <bool>() && target is Obj_AI_Hero) || (config.Item("useqLC").GetValue <bool>() && Jungle.GetNearest(player.Position).Distance(player.Position) < player.AttackRange + 30)))
     {
         Q.Cast(config.Item("packets").GetValue <bool>());
         Orbwalking.ResetAutoAttackTimer();
         //player.IssueOrder(GameObjectOrder.MoveTo, Game.CursorPos);
     }
 }
Ejemplo n.º 5
0
        private void AfterAttack(AttackableUnit unit, AttackableUnit targetO)
        {
            Obj_AI_Hero    targ             = (Obj_AI_Hero)targetO;
            List <Vector3> passivePositions = GetPassivePositions(targetO);
            bool           rapid            = player.GetAutoAttackDamage(targ) * 3 + ComboDamage(targ) > targ.Health ||
                                              (player.Health < targ.Health && player.Health < player.MaxHealth / 2);

            if (unit.IsMe && E.IsReady() && orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo &&
                (config.Item("usee", true).GetValue <bool>() ||
                 (unit.IsMe && config.Item("RapidAttack", true).GetValue <KeyBind>().Active || rapid)) &&
                !Orbwalking.CanAttack())
            {
                E.Cast(config.Item("packets").GetValue <bool>());
                Orbwalking.ResetAutoAttackTimer();
            }
            if (unit.IsMe && orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo &&
                (config.Item("RapidAttack", true).GetValue <KeyBind>().Active || rapid) && !Orbwalking.CanAttack() &&
                passivePositions.Any())
            {
                var passive = GetClosestPassivePosition(targ);
                var pos     = GetQpoint(targ, passive);
                if (pos.IsValid())
                {
                    Q.Cast(pos, config.Item("packets").GetValue <bool>());
                    Orbwalking.ResetAutoAttackTimer();
                }
                else
                {
                    var pos2 = GetQpoint(targ, Prediction.GetPrediction(targ, 2).UnitPosition);
                    if (pos2.IsValid())
                    {
                        Q.Cast(pos2, config.Item("packets").GetValue <bool>());
                    }
                }
            }
            if (unit.IsMe)
            {
                var         pos    = GetClosestPassivePosition(targetO);
                Obj_AI_Hero target = TargetSelector.GetTarget(W.Range, TargetSelector.DamageType.Physical);
                if (orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && targetO.NetworkId == target.NetworkId &&
                    R.IsReady() && R.CanCast(target) &&
                    HealthPrediction.GetHealthPrediction(target, 1000) > player.GetAutoAttackDamage(target) &&
                    ComboDamage(target) + player.GetAutoAttackDamage(target) * 5 > target.Health &&
                    ((config.Item("userally", true).GetValue <Slider>().Value <=
                      HeroManager.Allies.Count(
                          a => a.IsValid && !a.IsDead && a.Distance(target) < 600 && a.HealthPercent < 90) &&
                      config.Item("usertf", true).GetValue <bool>()) ||
                     (player.HealthPercent < 75 && config.Item("user", true).GetValue <bool>())))
                {
                    R.CastOnUnit(target, config.Item("packets").GetValue <bool>());
                    Orbwalking.ResetAutoAttackTimer();
                }
            }
        }
Ejemplo n.º 6
0
 private static void Orbwalking_AfterAttack(AttackableUnit unit, AttackableUnit target)
 {
     if (useHydra && unit.IsMe && hydraTarget != null && target.NetworkId == hydraTarget.NetworkId)
     {
         if (Items.HasItem(titanic.Id) && Items.CanUseItem(titanic.Id))
         {
             titanic.Cast();
             Orbwalking.ResetAutoAttackTimer();
         }
     }
 }
Ejemplo n.º 7
0
        private void Orbwalking_AfterAttack(AttackableUnit unit, AttackableUnit target)
        {
            var tar = target as Obj_AI_Base;

            if (Q.IsReady() && unit.IsMe && tar is Obj_AI_Hero &&
                orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && tar.HasBuffOfType(BuffType.Slow) &&
                target.Health > Q.GetDamage(tar) + player.GetAutoAttackDamage(tar) + 50)
            {
                Q.Cast(config.Item("packets").GetValue <bool>());
                Orbwalking.ResetAutoAttackTimer();
            }
        }
Ejemplo n.º 8
0
 private void BeforeAttack(Orbwalking.BeforeAttackEventArgs args)
 {
     if (args.Unit.IsMe && Q.IsReady() && orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.LaneClear &&
         config.Item("useqLC", true).GetValue <bool>() &&
         Environment.Minion.countMinionsInrange(player.Position, 600f) >
         config.Item("qhitLC", true).GetValue <Slider>().Value)
     {
         Q.Cast();
         Orbwalking.ResetAutoAttackTimer();
         //player.IssueOrder(GameObjectOrder.MoveTo, Game.CursorPos);
     }
 }
Ejemplo n.º 9
0
        private static void AfterAttack(AttackableUnit unit, AttackableUnit target)
        {
            var junglemob = Jungle.GetNearest(player.Position);

            if (unit.IsMe && Q.IsReady() &&
                ((orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && config.Item("useq", true).GetValue <bool>() &&
                  target.IsEnemy && target.Team != player.Team) ||
                 (config.Item("useqLC", true).GetValue <bool>() && junglemob != null &&
                  junglemob.Distance(player.Position) < player.AttackRange + 30)))
            {
                Q.Cast();
                Orbwalking.ResetAutoAttackTimer();
                //player.IssueOrder(GameObjectOrder.MoveTo, Game.CursorPos);
            }
        }
Ejemplo n.º 10
0
 private static void AfterAttack(AttackableUnit unit, AttackableUnit target)
 {
     if (unit.IsMe && Q.IsReady() && ((orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && config.Item("useq").GetValue <bool>() && target.IsEnemy && target.Team != player.Team) || (config.Item("useqLC").GetValue <bool>() && Jungle.GetNearest(player.Position).Distance(player.Position) < player.AttackRange + 30)))
     {
         Q.Cast(config.Item("packets").GetValue <bool>());
         Orbwalking.ResetAutoAttackTimer();
         //player.IssueOrder(GameObjectOrder.MoveTo, Game.CursorPos);
         return;
     }
     if (unit.IsMe && Q.IsReady() && orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.LaneClear && config.Item("useqLC").GetValue <bool>() && Environment.Minion.countMinionsInrange(player.Position, 600f) > 1)
     {
         Q.Cast(config.Item("packets").GetValue <bool>());
         Orbwalking.ResetAutoAttackTimer();
         //player.IssueOrder(GameObjectOrder.MoveTo, Game.CursorPos);
     }
 }
Ejemplo n.º 11
0
 private static void AfterAttack(AttackableUnit unit, AttackableUnit target)
 {
     if (unit.IsMe && Q.IsReady() &&
         (((orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo ||
            config.Item("useeflashforced").GetValue <KeyBind>().Active) && config.Item("useq").GetValue <bool>() &&
           target.IsEnemy && target is Obj_AI_Hero &&
           target.Health - player.GetAutoAttackDamage(target as Obj_AI_Hero) > 0) ||
          (orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.LaneClear &&
           player.ManaPercent > config.Item("minmana").GetValue <Slider>().Value&&
           config.Item("useqLC").GetValue <bool>() && target is Obj_AI_Minion &&
           target.Health > Q.GetDamage((Obj_AI_Base)target) * 2)))
     {
         Q.Cast(config.Item("packets").GetValue <bool>());
         Orbwalking.ResetAutoAttackTimer();
     }
 }
Ejemplo n.º 12
0
 private static void AfterAttack(AttackableUnit unit, AttackableUnit target)
 {
     if (unit.IsMe && Q.IsReady() &&
         ((orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && config.Item("useq", true).GetValue <bool>() &&
           target.IsEnemy && target.Team != player.Team) ||
          (config.Item("useqLC", true).GetValue <bool>() &&
           Jungle.GetNearest(player.Position).Distance(player.Position) < player.AttackRange + 30)))
     {
         var starget = TargetSelector.GetSelectedTarget();
         if (config.Item("selected", true).GetValue <bool>() && starget != null && target.Name != starget.Name)
         {
             return;
         }
         Q.Cast(config.Item("packets").GetValue <bool>());
         Orbwalking.ResetAutoAttackTimer();
         //player.IssueOrder(GameObjectOrder.MoveTo, Game.CursorPos);
     }
 }
Ejemplo n.º 13
0
 private void afterAttack(AttackableUnit unit, AttackableUnit target)
 {
     if (unit.IsMe && target is Obj_AI_Hero &&
         ((orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo &&
           checkFuryMode(SpellSlot.W, (Obj_AI_Base)target)) ||
          orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Mixed))
     {
         var time = Game.Time - W.Instance.CooldownExpires;
         if (config.Item("hyd").GetValue <bool>() &&
             (W.Instance.Cooldown - Math.Abs(time) < 1 || time < -6 || player.HealthPercent < 50))
         {
             ItemHandler.castHydra((Obj_AI_Hero)target);
         }
     }
     if (unit.IsMe && target is Obj_AI_Hero && orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo &&
         config.Item("usew", true).GetValue <bool>() && checkFuryMode(SpellSlot.W, (Obj_AI_Base)target))
     {
         W.Cast();
         Orbwalking.ResetAutoAttackTimer();
         return;
     }
     if (unit.IsMe && target is Obj_AI_Hero && orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Mixed &&
         config.Item("useCH", true).GetValue <StringList>().SelectedIndex == 0)
     {
         if (W.IsReady())
         {
             W.Cast();
             Orbwalking.ResetAutoAttackTimer();
             return;
         }
         if (Q.IsReady())
         {
             Q.Cast();
             return;
         }
         if (E.CanCast((Obj_AI_Base)target))
         {
             E.Cast(target.Position);
             return;
         }
     }
 }
Ejemplo n.º 14
0
        private void AfterAttack(AttackableUnit unit, AttackableUnit target)
        {
            Obj_AI_Hero targetO = TargetSelector.GetTarget(E.Range, TargetSelector.DamageType.Physical, true);

            if (unit != null && unit.IsMe && Q.IsReady() && target != null)
            {
                if (orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.LaneClear &&
                    config.Item("useqLC", true).GetValue <bool>())
                {
                    var minis = MinionManager.GetMinions(
                        ObjectManager.Player.ServerPosition, 600, MinionTypes.All, MinionTeam.NotAlly);

                    float perc = config.Item("minmana", true).GetValue <Slider>().Value / 100f;
                    if (player.Mana > player.MaxMana * perc &&
                        (minis.Count() > 1 || player.GetAutoAttackDamage((Obj_AI_Base)target, true) < target.Health))
                    {
                        Q.Cast();
                        Orbwalking.ResetAutoAttackTimer();
                    }
                }
                if (targetO != null && targetO.NetworkId != target.NetworkId)
                {
                    return;
                }
                if (orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Mixed &&
                    config.Item("useqH", true).GetValue <bool>() && target is Obj_AI_Hero)
                {
                    float perc = config.Item("minmanaH", true).GetValue <Slider>().Value / 100f;
                    if (player.Mana > player.MaxMana * perc)
                    {
                        Q.Cast();
                        Orbwalking.ResetAutoAttackTimer();
                    }
                }
                if (orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo &&
                    config.Item("useq", true).GetValue <bool>())
                {
                    Q.Cast();
                    Orbwalking.ResetAutoAttackTimer();
                }
            }
        }
Ejemplo n.º 15
0
        private static void AfterAttack(AttackableUnit unit, AttackableUnit target)
        {
            if (CanQ2)
            {
                return;
            }
            var nearestMob = Jungle.GetNearest(player.Position);

            if (unit.IsMe && Q.IsReady() &&
                (((orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && config.Item("useq", true).GetValue <bool>()) ||
                  (orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Mixed &&
                   config.Item("useqH", true).GetValue <bool>())) && target is Obj_AI_Hero) ||
                (config.Item("useqLC", true).GetValue <bool>() && nearestMob != null &&
                 nearestMob.Distance(player.Position) < player.AttackRange + 30))
            {
                Q.Cast();
                Orbwalking.ResetAutoAttackTimer();
                //player.IssueOrder(GameObjectOrder.MoveTo, Game.CursorPos);
            }
        }
Ejemplo n.º 16
0
        private void Orbwalking_AfterAttack(AttackableUnit unit, AttackableUnit target)
        {
            switch (orbwalker.ActiveMode)
            {
            case Orbwalking.OrbwalkingMode.Combo:
                if (config.Item("useq", true).GetValue <bool>() && Q.IsReady() && target is Obj_AI_Hero)
                {
                    Q.Cast();
                    Orbwalking.ResetAutoAttackTimer();
                    player.IssueOrder(GameObjectOrder.AutoAttack, target);
                }
                break;

            case Orbwalking.OrbwalkingMode.Mixed:
                if (config.Item("useqH", true).GetValue <bool>() && Q.IsReady() && target is Obj_AI_Hero &&
                    config.Item("minmanaH", true).GetValue <Slider>().Value < player.ManaPercent)
                {
                    Q.Cast();
                    Orbwalking.ResetAutoAttackTimer();
                    player.IssueOrder(GameObjectOrder.AutoAttack, target);
                }
                break;

            case Orbwalking.OrbwalkingMode.LaneClear:
                if (config.Item("useqLC", true).GetValue <bool>() && Q.IsReady() &&
                    config.Item("minmana", true).GetValue <Slider>().Value < player.ManaPercent &&
                    (target.Health <
                     player.GetAutoAttackDamage((Obj_AI_Base)target) + Q.GetDamage((Obj_AI_Base)target) ||
                     target.Health > player.GetAutoAttackDamage((Obj_AI_Base)target, true) * 4))
                {
                    Q.Cast();
                    Orbwalking.ResetAutoAttackTimer();
                    player.IssueOrder(GameObjectOrder.AutoAttack, target);
                }
                break;

            default:
                break;
            }
        }
Ejemplo n.º 17
0
        public static void Game_ProcessSpell(Obj_AI_Base hero, GameObjectProcessSpellCastEventArgs args)
        {
            if (args == null || hero == null)
            {
                return;
            }
            Obj_AI_Hero targetW   = TargetSelector.GetTarget(W.Range, TargetSelector.DamageType.Physical);
            var         spellName = args.SData.Name;
            Obj_AI_Hero target    = args.Target as Obj_AI_Hero;

            if (targetW != null)
            {
                hero = targetW;
            }
            if (hero.IsMe)
            {
                if (args.SData.Name == "FioraE")
                {
                    Orbwalking.ResetAutoAttackTimer();
                }
            }
        }
Ejemplo n.º 18
0
        private void beforeAttack(Orbwalking.BeforeAttackEventArgs args)
        {
            if (CanQ2)
            {
                return;
            }
            var target = args.Target as Obj_AI_Base;

            if (args.Unit.IsMe && Q.IsReady() && orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.LaneClear &&
                config.Item("useqLC", true).GetValue <bool>() && !(target is Obj_AI_Hero) && (args.Target.Health > 700))
            {
                Q.Cast();
                Orbwalking.ResetAutoAttackTimer();
                player.IssueOrder(GameObjectOrder.AutoAttack, target);
            }

            if (Q.IsReady() && target != null && config.Item("useqLH", true).GetValue <bool>() &&
                target.Health < Q.GetDamage(target) + player.GetAutoAttackDamage(target, true))
            {
                Q.Cast();
                Orbwalking.ResetAutoAttackTimer();
            }
        }
Ejemplo n.º 19
0
        private void Orbwalking_AfterAttack(AttackableUnit unit, AttackableUnit target)
        {
            Obj_AI_Hero t = TargetSelector.GetTarget(1100, TargetSelector.DamageType.Physical, true);

            if (!unit.IsMe || !W.IsReady() || !target.IsValidTarget() || !target.IsEnemy)
            {
                return;
            }
            if (orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.Combo && target is Obj_AI_Hero &&
                config.Item("usew", true).GetValue <bool>() && t != null && target.NetworkId == t.NetworkId)
            {
                W.Cast();
                Orbwalking.ResetAutoAttackTimer();
            }
            if (orbwalker.ActiveMode == Orbwalking.OrbwalkingMode.LaneClear && !(target is Obj_AI_Hero) &&
                config.Item("usewLC", true).GetValue <bool>() &&
                MinionManager.GetMinions(Orbwalking.GetRealAutoAttackRange(target), MinionTypes.All, MinionTeam.NotAlly)
                .Count(m => m.Health > player.GetAutoAttackDamage((Obj_AI_Base)target, true)) > 0)
            {
                W.Cast();
                Orbwalking.ResetAutoAttackTimer();
            }
        }
Ejemplo n.º 20
0
        public static void Game_ProcessSpell(Obj_AI_Base hero, GameObjectProcessSpellCastEventArgs args)
        {
            if (args == null || hero == null)
            {
                return;
            }
            Obj_AI_Hero targetW   = TargetSelector.GetTarget(W.Range, TargetSelector.DamageType.Physical);
            var         spellName = args.SData.Name;
            Obj_AI_Hero target    = args.Target as Obj_AI_Hero;

            if (targetW != null)
            {
                hero = targetW;
            }
            if (hero.IsMe)
            {
                if (args.SData.Name == "FioraE")
                {
                    Orbwalking.ResetAutoAttackTimer();
                }
            }
            if (config.Item("usewCC", true).GetValue <bool>())
            {
                if (spellName == "CurseofTheSadMummy")
                {
                    if (player.Distance(hero.Position) <= 600f)
                    {
                        W.Cast(TargetSelector.GetTarget(W.Range, TargetSelector.DamageType.Physical));
                    }
                }
                if (CombatHelper.IsFacing(target, player.Position) &&
                    (spellName == "EnchantedCrystalArrow" || spellName == "rivenizunablade" ||
                     spellName == "EzrealTrueshotBarrage" || spellName == "JinxR" || spellName == "sejuaniglacialprison"))
                {
                    if (player.Distance(hero.Position) <= W.Range - 60)
                    {
                        W.Cast(TargetSelector.GetTarget(W.Range, TargetSelector.DamageType.Physical));
                    }
                }
                if (spellName == "InfernalGuardian" || spellName == "UFSlash" ||
                    (spellName == "RivenW" && player.HealthPercent < 25))
                {
                    if (player.Distance(args.End) <= 270f)
                    {
                        W.Cast(TargetSelector.GetTarget(W.Range, TargetSelector.DamageType.Physical));
                    }
                }
                if (spellName == "BlindMonkRKick" || spellName == "SyndraR" || spellName == "VeigarPrimordialBurst" ||
                    spellName == "AlZaharNetherGrasp" || spellName == "LissandraR")
                {
                    if (args.Target.IsMe)
                    {
                        W.Cast(TargetSelector.GetTarget(W.Range, TargetSelector.DamageType.Physical));
                    }
                }
                if (spellName == "TristanaR" || spellName == "ViR")
                {
                    if (args.Target.IsMe || player.Distance(args.Target.Position) <= 100f)
                    {
                        W.Cast(TargetSelector.GetTarget(W.Range, TargetSelector.DamageType.Physical));
                    }
                }
                if (spellName == "GalioIdolOfDurand")
                {
                    if (player.Distance(hero.Position) <= 600f)
                    {
                        W.Cast(TargetSelector.GetTarget(W.Range, TargetSelector.DamageType.Physical));
                    }
                }
                if (target != null && target.IsMe)
                {
                    if (CombatHelper.isTargetedCC(spellName) && spellName != "NasusW" && spellName != "ZedUlt")
                    {
                        W.Cast(TargetSelector.GetTarget(W.Range, TargetSelector.DamageType.Physical));
                    }
                }
            }
        }