Example #1
0
 private static float RivenDamageQ(SpellDataInst spell, Obj_AI_Hero src, Obj_AI_Hero dsc)
 {
     double dmg = 0;
     if (spell.IsReady())
     {
         dmg += src.CalcDamage(
             dsc, Damage.DamageType.Physical,
             (-10 + (spell.Level * 20) +
              (0.35 + (spell.Level * 0.05)) * (src.FlatPhysicalDamageMod + src.BaseAttackDamage)) * 3);
     }
     return (float) dmg;
 }
        public static int GetCustomDamage(string auraname, Obj_AI_Hero target, Obj_AI_Hero source)
        {
            switch (auraname)
            {
                case "itemsunfirecapeaura":
                    return
                        (int)
                            source.CalcDamage(target, Damage.DamageType.Magical,
                                25 + (1*source.Level));

                case "gangplankattackdotpassive":
                    return
                        (int)
                            source.CalcDamage(target, Damage.DamageType.True,
                                20 + (10*source.Level) + 1.2 * (source.BaseAttackDamage + source.FlatPhysicalDamageMod));

                case "bantamtraptarget":
                    return
                        (int)
                            source.CalcDamage(target, Damage.DamageType.Magical,
                                new[] {50, 81, 112}[source.Level/6] + 0.25 * (source.FlatMagicDamageMod));
            }

            return 10;
        }