Beispiel #1
0
        private void CastE(Obj_AI_Base target)
        {
            if (target.Distance(player) > eRanges[E.Level - 1])
            {
                return;
            }
            var eFlyPred  = E.GetPrediction(target);
            var enemyPred = Prediction.GetPrediction(
                target, eChannelTimes[E.Level - 1] + target.Distance(player) / E.Speed / 1000);

            if (E.IsCharging)
            {
                if (!eFlyPred.CastPosition.IsValid() || eFlyPred.CastPosition.IsWall())
                {
                    return;
                }
                if (eFlyPred.CastPosition.Distance(player.Position) < E.Range)
                {
                    E.CastIfHitchanceEquals(target, HitChance.High, config.Item("packets").GetValue <bool>());
                }
                else if (eFlyPred.UnitPosition.Distance(player.Position) < E.Range && target.Distance(player) < 500f)
                {
                    E.CastIfHitchanceEquals(target, HitChance.Medium, config.Item("packets").GetValue <bool>());
                }
                else if ((eFlyPred.CastPosition.Distance(player.Position) < E.Range &&
                          eRanges[E.Level - 1] - eFlyPred.CastPosition.Distance(player.Position) < 200) ||
                         (CombatHelper.GetAngle(player, eFlyPred.CastPosition) > 35))
                {
                    E.CastIfHitchanceEquals(target, HitChance.Medium, config.Item("packets").GetValue <bool>());
                }
                else if (eFlyPred.CastPosition.Distance(player.Position) < E.Range && zacETime != 0 &&
                         System.Environment.TickCount - zacETime > 2500)
                {
                    E.CastIfHitchanceEquals(target, HitChance.Medium, config.Item("packets").GetValue <bool>());
                }
            }
            else if (enemyPred.UnitPosition.Distance(player.Position) < eRanges[E.Level - 1] &&
                     config.Item("Emin", true).GetValue <Slider>().Value < target.Distance(player.Position))
            {
                E.SetCharged("ZacE", "ZacE", 300, eRanges[E.Level - 1], eChannelTimes[E.Level - 1]);
                E.StartCharging(eFlyPred.UnitPosition);
            }
        }
Beispiel #2
0
        private void CastE(Obj_AI_Base target)
        {
            if (target.LSDistance(player) > eRanges[E.Level - 1])
            {
                return;
            }
            var eFlyPred  = E.GetPrediction(target);
            var enemyPred = Prediction.GetPrediction(
                target, eChannelTimes[E.Level - 1] + target.LSDistance(player) / E.Speed / 1000);

            if (E.IsCharging)
            {
                if (!eFlyPred.CastPosition.IsValid() || eFlyPred.CastPosition.IsWall())
                {
                    return;
                }
                if (eFlyPred.CastPosition.LSDistance(player.Position) < E.Range)
                {
                    E.CastIfHitchanceEquals(target, EloBuddy.SDK.Enumerations.HitChance.High, getCheckBoxItem(config, "packets"));
                }
                else if (eFlyPred.UnitPosition.LSDistance(player.Position) < E.Range && target.LSDistance(player) < 500f)
                {
                    E.CastIfHitchanceEquals(target, EloBuddy.SDK.Enumerations.HitChance.Medium, getCheckBoxItem(config, "packets"));
                }
                else if ((eFlyPred.CastPosition.LSDistance(player.Position) < E.Range &&
                          eRanges[E.Level - 1] - eFlyPred.CastPosition.LSDistance(player.Position) < 200) ||
                         (CombatHelper.GetAngle(player, eFlyPred.CastPosition) > 35))
                {
                    E.CastIfHitchanceEquals(target, EloBuddy.SDK.Enumerations.HitChance.Medium, getCheckBoxItem(config, "packets"));
                }
                else if (eFlyPred.CastPosition.LSDistance(player.Position) < E.Range && zacETime != 0 &&
                         Environment.TickCount - zacETime > 2500)
                {
                    E.CastIfHitchanceEquals(target, EloBuddy.SDK.Enumerations.HitChance.Medium, getCheckBoxItem(config, "packets"));
                }
            }
            else if (enemyPred.UnitPosition.LSDistance(player.Position) < eRanges[E.Level - 1] &&
                     getSliderItem(menuC, "Emin") < target.LSDistance(player.Position))
            {
                E.SetCharged(300, eRanges[E.Level - 1], eChannelTimes[E.Level - 1], 0.75f, 1500, 230);
                E.StartCharging();
            }
        }
Beispiel #3
0
        private void Combo()
        {
            Obj_AI_Hero target = null;

            if (E.IsCharging)
            {
                target = TargetSelector.GetTarget(
                    GetTargetRange(), TargetSelector.DamageType.Magical, true,
                    HeroManager.Enemies.Where(
                        h => h.IsInvulnerable && CombatHelper.GetAngle(player, target.Position) > 50));
            }
            else
            {
                target = TargetSelector.GetTarget(
                    GetTargetRange(), TargetSelector.DamageType.Magical, true,
                    HeroManager.Enemies.Where(h => h.IsInvulnerable));
            }
            if (target == null)
            {
                return;
            }
            if (config.Item("useItems").GetValue <bool>())
            {
                ItemHandler.UseItems(target, config);
            }
            if (config.Item("usew", true).GetValue <bool>() && W.CanCast(target) && !E.IsCharging)
            {
                W.Cast(config.Item("packets").GetValue <bool>());
            }
            var  ignitedmg = (float)player.GetSummonerSpellDamage(target, Damage.SummonerSpell.Ignite);
            bool hasIgnite = player.Spellbook.CanUseSpell(player.GetSpellSlot("SummonerDot")) == SpellState.Ready;

            if (config.Item("useIgnite", true).GetValue <bool>() && ignitedmg > target.Health && hasIgnite &&
                !CombatHelper.CheckCriticalBuffs(target) && !Q.CanCast(target))
            {
                player.Spellbook.CastSpell(player.GetSpellSlot("SummonerDot"), target);
            }

            if (rActive)
            {
                return;
            }

            if (config.Item("usee", true).GetValue <bool>() && E.IsReady() && player.CanMove)
            {
                CastE(target);
            }
            if (config.Item("useq", true).GetValue <bool>() && Q.CanCast(target) && target.IsValidTarget() &&
                !E.IsCharging)
            {
                Q.CastIfHitchanceEquals(target, HitChance.Medium, config.Item("packets").GetValue <bool>());
            }

            if (R.IsReady() && config.Item("user", true).GetValue <bool>() &&
                config.Item("Rmin", true).GetValue <Slider>().Value <= player.CountEnemiesInRange(R.Range) &&
                !target.HasBuffOfType(BuffType.Knockback) && !target.HasBuffOfType(BuffType.Knockup) &&
                !target.HasBuffOfType(BuffType.Stun))
            {
                R.Cast(config.Item("packets").GetValue <bool>());
            }
        }
Beispiel #4
0
        private void Combo()
        {
            Obj_AI_Hero target = null;

            if (E.IsCharging)
            {
                target = DrawHelper.GetBetterTarget(
                    GetTargetRange(), TargetSelector.DamageType.Magical, true,
                    HeroManager.Enemies.Where(
                        h => h.IsInvulnerable && CombatHelper.GetAngle(player, target.Position) > 50));
            }
            else
            {
                target = DrawHelper.GetBetterTarget(
                    GetTargetRange(), TargetSelector.DamageType.Magical, true,
                    HeroManager.Enemies.Where(h => h.IsInvulnerable));
            }
            if (target == null)
            {
                return;
            }
            if (config.Item("useItems").GetValue <bool>())
            {
                ItemHandler.UseItems(target, config);
            }
            if (config.Item("usew", true).GetValue <bool>() && W.CanCast(target) && !E.IsCharging)
            {
                W.Cast();
            }
            var  ignitedmg = (float)player.GetSummonerSpellDamage(target, Damage.SummonerSpell.Ignite);
            bool hasIgnite = player.Spellbook.CanUseSpell(player.GetSpellSlot("SummonerDot")) == SpellState.Ready;

            if (config.Item("useIgnite", true).GetValue <bool>() && ignitedmg > target.Health && hasIgnite &&
                !CombatHelper.CheckCriticalBuffs(target) && !Q.CanCast(target))
            {
                player.Spellbook.CastSpell(player.GetSpellSlot("SummonerDot"), target);
            }

            if (rActive)
            {
                orbwalker.SetAttack(false);
                Orbwalking.Attack = false;
                return;
            }

            if (config.Item("usee", true).GetValue <bool>() && E.IsReady() && player.CanMove)
            {
                CastE(target);
            }
            if (config.Item("useq", true).GetValue <bool>() && Q.CanCast(target) && target.IsValidTarget() &&
                !E.IsCharging)
            {
                Q.CastIfHitchanceEquals(target, HitChance.Medium);
            }

            if (R.IsReady() && config.Item("user", true).GetValue <bool>() &&
                config.Item("Rmin", true).GetValue <Slider>().Value <= player.CountEnemiesInRange(R.Range) &&
                !target.HasBuffOfType(BuffType.Knockback) && !target.HasBuffOfType(BuffType.Knockup) &&
                !target.HasBuffOfType(BuffType.Stun))
            {
                R.Cast();
            }
            if (config.Item("collectBlobsC", true).GetValue <bool>() && !E.IsCharging)
            {
                var blob =
                    ObjectManager.Get <Obj_AI_Base>()
                    .Where(
                        o =>
                        !o.IsDead && o.IsValid && o.Name == "BlobDrop" && o.Team == player.Team &&
                        o.Distance(player) < Orbwalking.GetRealAutoAttackRange(player))
                    .OrderBy(o => o.Distance(player))
                    .FirstOrDefault();
                if (blob != null && Orbwalking.CanMove(300) && !Orbwalking.CanAttack() && !player.IsWindingUp)
                {
                    orbwalker.SetMovement(false);
                    Orbwalking.Move = false;
                    player.IssueOrder(GameObjectOrder.MoveTo, blob.Position);
                }
            }
        }