コード例 #1
0
ファイル: Kindred.cs プロジェクト: cybarus/Nevachan-Stuff
        public void combo()
        {
            var target = TargetSelector.GetTarget(ObjectManager.Player.AttackRange + KindredSpells.privQ.Range + 70, DamageType.Physical);

            if (target == null)
            {
                return;
            }
            gTarget = target;
            if (KindredSpells.privR.IsReady() && ObjectManager.Player.CountEnemiesInRange(ObjectManager.Player.AttackRange) >= KindredMenu.minRcombo() && KindredMenu.useR())
            {
                KindredSpells.privR.Cast(Player.Instance);
            }
            if ((ObjectManager.Player.CountEnemiesInRange(ObjectManager.Player.AttackRange) >= KindredMenu.itemsYOUMUSSenemys() || Player.Instance.HealthPercent >= KindredMenu.itemsYOUMUSShp()) && KindredSpells.youmus.IsReady())
            {
                KindredSpells.youmus.Cast();
            }
            if (Player.Instance.HealthPercent <= KindredMenu.itemsBOTRKhp() && KindredSpells.botrk.IsReady())
            {
                KindredSpells.botrk.Cast(target);
            }
            if (KindredSpells.privE.IsReady() && KindredMenu.useE())
            {
                KindredSpells.privE.Cast(target);
            }
            if (KindredSpells.privW.IsReady() && KindredMenu.useW())
            {
                KindredSpells.privW.Cast(target);
            }
            if (KindredSpells.privQ.IsReady() && KindredMenu.useQ())
            {
                if (KindredMenu.smartQCombo())
                {
                    if (ObjectManager.Player.Distance(target.Position) <= ObjectManager.Player.GetAutoAttackRange() && Player.Instance.HealthPercent <= KindredMenu.minQcombo() || ObjectManager.Player.CountEnemiesInRange(ObjectManager.Player.AttackRange) >= KindredMenu.minQaggresive())
                    {
                        Player.CastSpell(SpellSlot.Q, -1 * (target.Position));
                    }
                    else if (ObjectManager.Player.Distance(target.Position) >= (ObjectManager.Player.GetAutoAttackRange() + KindredSpells.privQ.Range))
                    {
                        Player.CastSpell(SpellSlot.Q, target.Position);
                    }
                    else
                    {
                        Player.CastSpell(SpellSlot.Q, Game.CursorPos);
                    }
                }
                else
                {
                    Player.CastSpell(SpellSlot.Q, Game.CursorPos);
                }
            }
            if (KindredSpells.smite.IsReady() && KindredMenu.useSmiteCombo())
            {
                KindredSpells.smite.Cast(target);
            }
        }