Пример #1
0
        private static void CastQCannon(Obj_AI_Hero target, bool useE)
        {
            var qePred = QE.GetPrediction(target);

            if (qePred.HitChance >= HitChance.High && qCd == 0 && eCd == 0 && useE)
            {
                var gateVector = Me.Position +
                                 Vector3.Normalize(target.ServerPosition - Me.Position) * MiscOption.GetSlider("E", "gatePlace").Value;

                if (Me.Distance(qePred.CastPosition) < QE.Range + 100)
                {
                    if (E.Ready && QE.Ready)
                    {
                        E.Cast(gateVector);
                        QE.Cast(qePred.CastPosition);
                        return;
                    }
                }
            }

            var qPred = Q.GetPrediction(target);

            if ((!useE || !E.Ready) && qCd == 0 && qPred.HitChance >= HitChance.High &&
                Me.Distance(target.ServerPosition) <= Q.Range && Q.Ready && eCd != 0)
            {
                Q.Cast(target);
            }
        }
Пример #2
0
        /// <summary>
        ///     The cast Q range.
        /// </summary>
        private static void CastQERange()
        {
            var Minions = GameObjects.EnemyMinions.Where(x => x.IsValidTarget(QE.Range)).ToList();
            var FarmPos = QE.GetCircularFarmLocation(Minions, QE.Width);
            var MinHit  = FarmPos.MinionsHit;

            if (QE.IsReady() && (ObjectManager.Player.Mana > Q.Instance.ManaCost + E.Instance.ManaCost))
            {
                if (MinHit >= LaneCannonQHit.Value)
                {
                    QE.Cast(FarmPos.Position);
                }
            }
        }
Пример #3
0
        /// <summary>
        ///     The cast QE range.
        /// </summary>
        private static void CastQERange()
        {
            var target = Variables.TargetSelector.GetTarget(QE.Range, DamageType.Physical);

            if (target != null)
            {
                if (QE.IsReady() && E.IsReady() && target.IsValidTarget(QE.Range) &&
                    (ObjectManager.Player.Mana > Q.Instance.SData.Mana + E.Instance.SData.Mana))
                {
                    var Prediction = QE.GetPrediction(target);
                    if (Prediction.Hitchance >= HitChance.VeryHigh)
                    {
                        QE.Cast(Prediction.CastPosition);
                    }
                }
            }
        }
Пример #4
0
        private static void CastQCannonMouse()
        {
            Me.IssueOrder(OrderType.MoveTo, Game.CursorPos);

            if (isMelee && !R.Ready)
            {
                return;
            }

            if (isMelee && R.Ready)
            {
                R.Cast();
                return;
            }

            if (eCd == 0 && qCd == 0 && !isMelee)
            {
                if (MiscOption.GetList("QE", "SemiQEMode").Value == 1)
                {
                    var gateDis    = MiscOption.GetSlider("E", "gatePlace").Value;
                    var gateVector = Me.ServerPosition + Vector3.Normalize(Game.CursorPos - Me.ServerPosition) * gateDis;

                    if (E.Ready && QE.Ready)
                    {
                        E.Cast(gateVector);
                        QE.Cast(Game.CursorPos);
                    }
                }
                else
                {
                    var qTarget = MyTargetSelector.GetTarget(QE.Range);

                    if (qTarget != null && qTarget.IsValidTarget(QE.Range) && qCd == 0)
                    {
                        CastQCannon(qTarget, true);
                    }
                }
            }
        }