Exemplo n.º 1
0
 public static void ComboAfterAa(Obj_AI_Base target)
 {
     try
     {
         if (Player.Instance.HasBuff("RivenFengShuiEngine") && R.IsReady() &&
             ComboMenu["R2Combo"].Cast <CheckBox>().CurrentValue)
         {
             if (Player.Instance.CalculateDamageOnUnit(target, DamageType.Physical, Damager.RDamage(target)) + Player.Instance.GetAutoAttackDamage(target, true) > target.Health)
             {
                 ssfl = true;
                 R.Cast(target);
                 return;
             }
         }
         if (ComboMenu["WCombo"].Cast <CheckBox>().CurrentValue&& W.IsReady() &&
             W.IsInRange(target))
         {
             Core.DelayAction(ForceItem, 50);
             Player.CastSpell(SpellSlot.W);
             return;
         }
         if (ComboMenu["QCombo"].Cast <CheckBox>().CurrentValue&& Q.IsReady())
         {
             Player.CastSpell(SpellSlot.Q, target.Position);
             return;
         }
         Core.DelayAction(ForceItem, 50);
     }
     catch (Exception ex)
     {
         Console.WriteLine(ex);
     }
 }
Exemplo n.º 2
0
        public static void LastHitAfterAa(Obj_AI_Base target)
        {
            var unitHp = target.Health - Player.Instance.GetAutoAttackDamage(target, true);

            if (unitHp > 0)
            {
                if (FarmingMenu["QLastHit"].Cast <CheckBox>().CurrentValue&& Q.IsReady() &&
                    Player.Instance.CalculateDamageOnUnit(target, DamageType.Physical, Damager.QDamage()) >
                    unitHp)
                {
                    Player.CastSpell(SpellSlot.Q, target.Position);
                    return;
                }
                if (FarmingMenu["WLastHit"].Cast <CheckBox>().CurrentValue&& W.IsReady() &&
                    W.IsInRange(target) &&
                    Player.Instance.CalculateDamageOnUnit(target, DamageType.Physical, Damager.WDamage()) >
                    unitHp)
                {
                    Player.CastSpell(SpellSlot.W);
                }
            }
        }
Exemplo n.º 3
0
        private static void Obj_AI_Base_OnSpellCast(Obj_AI_Base sender, GameObjectProcessSpellCastEventArgs args)
        {
            if (!sender.IsMe)
            {
                return;
            }
            var target = args.Target as Obj_AI_Base;

            // Hydra
            if (args.SData.Name.ToLower().Contains("itemtiamatcleave"))
            {
                Orbwalker.ResetAutoAttack();
                if (W.IsReady())
                {
                    var target2 = TargetSelector.GetTarget(W.Range, DamageType.Physical);
                    if (target2 != null || Orbwalker.ActiveModesFlags != Orbwalker.ActiveModes.None)
                    {
                        Player.CastSpell(SpellSlot.W);
                    }
                }
                return;
            }

            //W
            if (args.SData.Name.ToLower().Contains(W.Name.ToLower()))
            {
                if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo))
                {
                    if (Player.Instance.HasBuff("RivenFengShuiEngine") && R.IsReady() &&
                        ComboMenu["R2Combo"].Cast <CheckBox>().CurrentValue)
                    {
                        ssfl = true;
                        var target2 = TargetSelector.GetTarget(R.Range, DamageType.Physical);
                        if (target2 != null &&
                            (target2.Distance(Player.Instance) < W.Range &&
                             target2.Health >
                             Player.Instance.CalculateDamageOnUnit(target2, DamageType.Physical, Damager.WDamage()) ||
                             target2.Distance(Player.Instance) > W.Range) &&
                            Player.Instance.CalculateDamageOnUnit(target2, DamageType.Physical,
                                                                  Damager.RDamage(target2) + Damager.WDamage()) > target2.Health)
                        {
                            R.Cast(target2);
                        }
                    }
                }

                target = (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo) ||
                          Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Harass))
                    ? TargetSelector.GetTarget(E.Range + W.Range, DamageType.Physical)
                    : (Obj_AI_Base)Orbwalker.LastTarget;
                if (Q.IsReady() && Orbwalker.ActiveModesFlags != Orbwalker.ActiveModes.None || ComboMenu["FlashBurst"].Cast <KeyBind>().CurrentValue&& target != null)
                {
                    Player.CastSpell(SpellSlot.Q, target.Position);
                    return;
                }
                return;
            }

            //E
            if (args.SData.Name.ToLower().Contains(E.Name.ToLower()))
            {
                if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo))
                {
                    if (Player.Instance.HasBuff("RivenFengShuiEngine") && R.IsReady() &&
                        ComboMenu["R2Combo"].Cast <CheckBox>().CurrentValue)
                    {
                        ssfl = true;
                        var target2 = TargetSelector.GetTarget(R.Range, DamageType.Physical);
                        if (target2 != null &&
                            Player.Instance.CalculateDamageOnUnit(target2, DamageType.Physical,
                                                                  (Damager.RDamage(target2))) > target2.Health)
                        {
                            R.Cast(target2);
                            return;
                        }
                    }
                    if ((EnableR == true) && R.IsReady() &&
                        !Player.Instance.HasBuff("RivenFengShuiEngine") &&
                        ComboMenu["RCombo"].Cast <CheckBox>().CurrentValue)
                    {
                        ssfl = false;
                        Player.CastSpell(SpellSlot.R);
                    }
                    target = TargetSelector.GetTarget(W.Range, DamageType.Physical);
                    if (target != null && Player.Instance.Distance(target) < W.Range)
                    {
                        Player.CastSpell(SpellSlot.W);
                        return;
                    }
                }
            }

            //Q
            if (args.SData.Name.ToLower().Contains(Q.Name.ToLower()))
            {
                if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo))
                {
                    if (Player.Instance.HasBuff("RivenFengShuiEngine") && R.IsReady() &&
                        ComboMenu["R2Combo"].Cast <CheckBox>().CurrentValue)
                    {
                        var target2 = TargetSelector.GetTarget(R.Range, DamageType.Physical);
                        if (target2 != null &&
                            (target2.Distance(Player.Instance) < 300 &&
                             target2.Health >
                             Player.Instance.CalculateDamageOnUnit(target2, DamageType.Physical, Damager.QDamage()) ||
                             target2.Distance(Player.Instance) > 300) &&
                            Player.Instance.CalculateDamageOnUnit(target2, DamageType.Physical,
                                                                  Damager.RDamage(target2) + Damager.QDamage()) > target2.Health)
                        {
                            R.Cast(target2);
                        }
                    }
                }
                return;
            }

            if (args.SData.IsAutoAttack() && target != null)
            {
                if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Combo))
                {
                    ComboAfterAa(target);
                }

                if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.Harass))
                {
                    HarassAfterAa(target);
                }

                if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.JungleClear))
                {
                    JungleAfterAa(target);
                }

                if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.LastHit) && target.IsMinion())
                {
                    LastHitAfterAa(target);
                }

                if (Orbwalker.ActiveModesFlags.HasFlag(Orbwalker.ActiveModes.LaneClear) && target.IsMinion())
                {
                    LaneClearAfterAa(target);
                }
            }
        }
Exemplo n.º 4
0
        private static void JungleClear()
        {
            var minion =
                EntityManager.MinionsAndMonsters.Monsters.OrderByDescending(a => a.MaxHealth)
                .FirstOrDefault(a => a.Distance(Player.Instance) < Player.Instance.GetAutoAttackRange(a));

            {
                if (minion == null)
                {
                    return;
                }

                if (FarmingMenu["QJungleClear"].Cast <CheckBox>().CurrentValue&& Q.IsReady() &&
                    minion.Health <=
                    Player.Instance.CalculateDamageOnUnit(minion, DamageType.Physical, Damager.QDamage()))
                {
                    Player.CastSpell(SpellSlot.Q, minion.Position);
                    return;
                }

                if (FarmingMenu["EJungleClear"].Cast <CheckBox>().CurrentValue&& (!W.IsReady() && !Q.IsReady() || Player.Instance.HealthPercent < 20) && E.IsReady() &&
                    LastCastW + 750 < Environment.TickCount)
                {
                    Player.CastSpell(SpellSlot.E, minion.Position);
                }
            }
        }
Exemplo n.º 5
0
        private static void LastHit()
        {
            Orbwalker.ForcedTarget = null;
            {
                if (Orbwalker.IsAutoAttacking)
                {
                    return;
                }

                foreach (
                    var minion in EntityManager.MinionsAndMonsters.EnemyMinions.Where(a => a.IsValidTarget(W.Range)))
                {
                    if (FarmingMenu["QLastHit"].Cast <CheckBox>().CurrentValue&& Q.IsReady() &&
                        minion.Health <=
                        Player.Instance.CalculateDamageOnUnit(minion, DamageType.Physical, Damager.QDamage()))
                    {
                        Player.CastSpell(SpellSlot.Q, minion.Position);
                        return;
                    }
                    if (FarmingMenu["WLastHit"].Cast <CheckBox>().CurrentValue&& W.IsReady() &&
                        minion.Health <=
                        Player.Instance.CalculateDamageOnUnit(minion, DamageType.Physical, Damager.WDamage()))
                    {
                        Player.CastSpell(SpellSlot.W);
                        return;
                    }
                }
            }
        }
Exemplo n.º 6
0
 private static void LaneClear()
 {
     try
     {
         Orbwalker.ForcedTarget = null;
         {
             if (Orbwalker.IsAutoAttacking || LastCastQ + 260 > Environment.TickCount)
             {
                 return;
             }
             foreach (
                 var minion in EntityManager.MinionsAndMonsters.EnemyMinions.Where(a => a.IsValidTarget(W.Range)))
             {
                 if (FarmingMenu["QLaneClear"].Cast <CheckBox>().CurrentValue&& Q.IsReady() &&
                     minion.Health <=
                     Player.Instance.CalculateDamageOnUnit(minion, DamageType.Physical, Damager.QDamage()))
                 {
                     Player.CastSpell(SpellSlot.Q, minion.Position);
                     return;
                 }
                 if (FarmingMenu["WLaneClear"].Cast <CheckBox>().CurrentValue&& W.IsReady() &&
                     minion.Health <=
                     Player.Instance.CalculateDamageOnUnit(minion, DamageType.Physical, Damager.WDamage()))
                 {
                     Player.CastSpell(SpellSlot.W);
                     return;
                 }
             }
         }
     }
     catch (Exception ex)
     {
         Console.Write(ex);
     }
 }
Exemplo n.º 7
0
        private static void Combo()
        {
            if (Orbwalker.IsAutoAttacking)
            {
                return;
            }
            var target = TargetSelector.GetTarget(E.Range + W.Range + 200, DamageType.Physical);

            if (target == null)
            {
                return;
            }
            var useQ    = ComboMenu["QCombo"].Cast <CheckBox>().CurrentValue;
            var useW    = ComboMenu["WCombo"].Cast <CheckBox>().CurrentValue;
            var useE    = ComboMenu["ECombo"].Cast <CheckBox>().CurrentValue;
            var useR    = ComboMenu["RCombo"].Cast <CheckBox>().CurrentValue;
            var useItem = ComboMenu["useTiamat"].Cast <CheckBox>().CurrentValue;

            EnableR = false;
            try
            {
                if (R.IsReady() && Player.Instance.HasBuff("RivenFengShuiEngine") &&
                    ComboMenu["R2Combo"].Cast <CheckBox>().CurrentValue)
                {
                    if (EntityManager.Heroes.Enemies.Where(
                            enemy =>
                            enemy.IsValidTarget(R.Range) &&
                            enemy.Health <
                            Player.Instance.CalculateDamageOnUnit(enemy, DamageType.Physical,
                                                                  Damager.RDamage(enemy))).Any(enemy => R.Cast(enemy)))
                    {
                        ssfl = true;
                        return;
                    }
                }

                if (ComboMenu["RCombo"].Cast <CheckBox>().CurrentValue&& R.IsReady() && !Player.Instance.HasBuff("RivenFengShuiEngine"))
                {
                    if ((ComboMenu["RCantKill"].Cast <CheckBox>().CurrentValue&&
                         target.Health > Damager.ComboDamage(target, true) &&
                         target.Health <Damager.ComboDamage(target) &&
                                        target.Health> Player.Instance.GetAutoAttackDamage(target, true) * 2) ||
                        (ComboMenu["REnemyCount"].Cast <Slider>().CurrentValue > 0 &&
                         Player.Instance.CountEnemiesInRange(600) >= ComboMenu["REnemyCount"].Cast <Slider>().CurrentValue) || IsRActive)
                    {
                        ssfl    = false;
                        EnableR = true;
                    }
                    if (ComboMenu["ForcedR"].Cast <KeyBind>().CurrentValue)
                    {
                        ssfl    = false;
                        EnableR = true;
                    }
                }

                if (ComboMenu["ECombo"].Cast <CheckBox>().CurrentValue&& target.Distance(Player.Instance) > W.Range && E.IsReady())
                {
                    if (Item.HasItem(3142) && Item.CanUseItem(3142))
                    {
                        Item.UseItem(3142);
                    }
                    Player.CastSpell(SpellSlot.E, target.Position);
                    return;
                }

                if (ComboMenu["ECombo"].Cast <CheckBox>().CurrentValue&& target.Distance(Player.Instance) < W.Range && E.IsReady())
                {
                    Player.CastSpell(SpellSlot.E, Game.CursorPos);
                    return;
                }

                if (ComboMenu["WCombo"].Cast <CheckBox>().CurrentValue&&
                    target.Distance(Player.Instance) <= W.Range && W.IsReady())
                {
                    Core.DelayAction(ForceItem, 50);
                    Player.CastSpell(SpellSlot.W);
                    return;
                }
            }
            catch (Exception ex)
            {
                Console.WriteLine(ex);
            }
        }