Пример #1
0
        //-------------------------------------------SpellDamage()----------------------------------------------

        static float SpellDamage(Obj_AI_Base target, SpellSlot slot)
        {
            switch (slot)
            {
            case SpellSlot.Q:
                if (!Q.IsReady())
                {
                    return(0);
                }

                if (Item.HasItem(ItemId.Trinity_Force) && ((Trinity.IsReady() && !Player.HasBuff("sheen")) || Player.HasBuff("sheen")))
                {
                    return(Player.CalculateDamageOnUnit(target, DamageType.Physical, new float[] { 20, 50, 80, 110, 140 }[Q.Level - 1] +Player.TotalAttackDamage + 2 * Player.BaseAttackDamage, true, true));
                }
                if (Item.HasItem(ItemId.Sheen) && ((Sheen.IsReady() && !Player.HasBuff("sheen")) || Player.HasBuff("sheen")))
                {
                    return(Player.CalculateDamageOnUnit(target, DamageType.Physical, new float[] { 20, 50, 80, 110, 140 }[Q.Level - 1] +Player.TotalAttackDamage + Player.BaseAttackDamage, true, true));
                }
                return(Player.CalculateDamageOnUnit(target, DamageType.Physical, new float[] { 20, 50, 80, 110, 140 }[Q.Level - 1] +Player.TotalAttackDamage, true, true));

            case SpellSlot.W:
                return(Player.CalculateDamageOnUnit(target, DamageType.True, 15 * W.Level, true, true));

            case SpellSlot.E:
                return(Player.CalculateDamageOnUnit(target, DamageType.Magical, 40 * (E.Level + 1), true, true));

            case SpellSlot.R:
                return(Player.CalculateDamageOnUnit(target, DamageType.Physical, (40 * (R.Level + 1)) + Player.TotalMagicalDamage / 2 + Player.FlatPhysicalDamageMod * 0.6f));

            default:
                return(0);
            }
        }
Пример #2
0
        private static float TwistedFateDamage(AIHeroClient target)
        {
            var   Qdamage = (float)Player.GetSpellDamage(target, Q.Slot);
            var   Wdamage = (float)Player.GetSpellDamage(target, W.Slot);
            float x       = 0;

            if ((W.IsReady() || HasACard != "none") && Q.IsReady())
            {
                if ((Player.Mana >= Q.Instance.SData.Mana + W.Instance.SData.Mana) || (Player.Mana >= Q.Instance.SData.Mana && HasACard != "none"))
                {
                    x = x + Qdamage + Wdamage;
                }
                else if (Player.Mana >= Q.Instance.SData.Mana)
                {
                    x = x + Qdamage;
                }
                else if (Player.Mana >= W.Instance.SData.Mana || HasACard != "none")
                {
                    x = x + Wdamage;
                }
            }
            else if (Q.IsReady())
            {
                x = x + Qdamage;
            }
            else if (W.IsReady() || HasACard != "none")
            {
                x = x + Wdamage;
            }
            if (LichBane.IsReady())
            {
                x = x + (float)Player.CalcDamage(target, Damage.DamageType.Magical, 0.75 * Player.BaseAttackDamage + 0.5 * Player.FlatMagicDamageMod);
            }
            else if (TrinityForce.IsReady())
            {
                x = x + (float)Player.CalcDamage(target, Damage.DamageType.Magical, 2 * Player.BaseAttackDamage);
            }
            else if (IcebornGauntlet.IsReady())
            {
                x = x + (float)Player.CalcDamage(target, Damage.DamageType.Magical, 1.25 * Player.BaseAttackDamage);
            }
            else if (Sheen.IsReady())
            {
                x = x + (float)Player.CalcDamage(target, Damage.DamageType.Magical, 1 * Player.BaseAttackDamage);
            }
            if (LudensEcho.IsReady())
            {
                x = x + (float)Player.CalcDamage(target, Damage.DamageType.Magical, 100 + 0.1 * Player.FlatMagicDamageMod);
            }
            x = x + (float)Player.GetAutoAttackDamage(target, true);
            return(x);
        }
Пример #3
0
        private double GetBonusDmg(Obj_AI_Base Target)
        {
            double DmgItem = 0;

            if (Sheen.IsOwned() && ((Sheen.IsReady() && W.IsReady()) || Player.HasBuff("Sheen")) && Player.BaseAttackDamage > DmgItem)
            {
                DmgItem = Player.BaseAttackDamage;
            }
            if (Trinity.IsOwned() && ((Trinity.IsReady() && W.IsReady()) || Player.HasBuff("Sheen")) && Player.BaseAttackDamage * 2 > DmgItem)
            {
                DmgItem = Player.BaseAttackDamage * 2;
            }
            return(((W.IsReady() || Player.HasBuff("JaxEmpowerTwo")) ? W.GetDamage(Target) : 0) + (RCount == 2 ? R.GetDamage(Target) : 0) + Player.GetAutoAttackDamage(Target, true) + Player.CalcDamage(Target, Damage.DamageType.Physical, DmgItem));
        }
Пример #4
0
        private double GetBonusDmg(Obj_AI_Base Target)
        {
            double DmgItem = 0;

            if (Sheen.IsOwned() && ((Sheen.IsReady() && Q.IsReady()) || Player.HasBuff("Sheen")) && Player.BaseAttackDamage > DmgItem)
            {
                DmgItem = Player.BaseAttackDamage;
            }
            if (Iceborn.IsOwned() && ((Iceborn.IsReady() && Q.IsReady()) || Player.HasBuff("ItemFrozenFist")) && Player.BaseAttackDamage * 1.25 > DmgItem)
            {
                DmgItem = Player.BaseAttackDamage * 1.25;
            }
            if (Trinity.IsOwned() && ((Trinity.IsReady() && Q.IsReady()) || Player.HasBuff("Sheen")) && Player.BaseAttackDamage * 2 > DmgItem)
            {
                DmgItem = Player.BaseAttackDamage * 2;
            }
            return((Q.IsReady() ? Q.GetDamage(Target) : 0) + Player.GetAutoAttackDamage(Target, Q.IsReady() ? false : true) + Player.CalcDamage(Target, Damage.DamageType.Physical, DmgItem));
        }
Пример #5
0
        private static double GetBonusDmg(Obj_AI_Base target)
        {
            var dmgItem = 0d;

            if (Sheen.IsOwned() && (Sheen.IsReady() || Player.HasBuff("Sheen")))
            {
                dmgItem = Player.BaseAttackDamage;
            }
            if (Iceborn.IsOwned() && (Iceborn.IsReady() || Player.HasBuff("ItemFrozenFist")))
            {
                dmgItem = Player.BaseAttackDamage * 1.25;
            }
            if (Trinity.IsOwned() && (Trinity.IsReady() || Player.HasBuff("Sheen")))
            {
                dmgItem = Player.BaseAttackDamage * 2;
            }
            return((Q.IsReady() ? Q.GetDamage(target) : 0) + Player.GetAutoAttackDamage(target, true) +
                   (dmgItem > 0 ? Player.CalcDamage(target, Damage.DamageType.Physical, dmgItem) : 0));
        }
Пример #6
0
        private static double GetBonusDmg(Obj_AI_Base target)
        {
            var dmgItem = 0d;

            if (Sheen.IsOwned() && (Sheen.IsReady() || Player.HasBuff("Sheen")))
            {
                dmgItem = Player.BaseAttackDamage;
            }
            if (Trinity.IsOwned() && (Trinity.IsReady() || Player.HasBuff("Sheen")))
            {
                dmgItem = Player.BaseAttackDamage * 2;
            }
            var dmgR  = 0d;
            var pBuff = Player.GetBuffCount("JaxRelentlessAssaultAS");

            if (R.Level > 0 && !(target is Obj_AI_Turret) && (pBuff == 2 || pBuff >= 5))
            {
                dmgR = R.GetDamage(target);
            }
            return(dmgR + (W.IsReady() || HaveW ? W.GetDamage(target) : 0) + Player.GetAutoAttackDamage(target, true) +
                   (dmgItem > 0 ? Player.CalcDamage(target, Damage.DamageType.Physical, dmgItem) : 0));
        }
Пример #7
0
        private double GetBonusDmg(Obj_AI_Base target)
        {
            double dmgItem = 0;

            if (Sheen.IsOwned() && (Sheen.IsReady() || Player.HasBuff("Sheen")) && Player.BaseAttackDamage > dmgItem)
            {
                dmgItem = Player.BaseAttackDamage;
            }
            if (Trinity.IsOwned() && (Trinity.IsReady() || Player.HasBuff("Sheen")) &&
                Player.BaseAttackDamage * 2 > dmgItem)
            {
                dmgItem = Player.BaseAttackDamage * 2;
            }
            double dmgR  = 0;
            var    pBuff = Player.Buffs.FirstOrDefault(i => i.DisplayName == "JaxRelentlessAssaultAS");

            if (R.Level > 0 && !(target is Obj_AI_Turret) && pBuff != null && (pBuff.Count == 2 || pBuff.Count >= 5))
            {
                dmgR = R.GetDamage(target);
            }
            return(dmgR + (W.IsReady() || HaveW ? W.GetDamage(target) : 0) + Player.GetAutoAttackDamage(target, true) +
                   (dmgItem > 0 ? Player.CalcDamage(target, Damage.DamageType.Physical, dmgItem) : 0));
        }