예제 #1
0
        // orbs attack once per second without ups. It scales with attack speed upgrades, but not attack speed stats.
        //
        // orbs can hit all units in a radius of 6, but it requires you to have vision of the target.
        // Because we likely won't have vision of all enemies in radius 6 from the orb,
        // this has been scaled to a radius of 4 to attempt to mimic that
        protected override double GetAttackCount(VLoadout loadout)
        {
            var orbAtkSpeed = 1.0 * Math.Pow(0.96, loadout.Upgrades.AttackSpeedUpgrade);
            var zapsPerOrb  = OrbTravelDuration / orbAtkSpeed;

            return(zapsPerOrb * OrbsPerAttack * WeaponHelper.GetEnemiesInRadius(RadiusOfOrbAttacks));
        }
        protected override double GetAttackCount(VLoadout loadout)
        {
            var stormCoolDown = BaseStorm.GetActualWeaponPeriod(loadout);
            var stormUptime   = Math.Min(4 / stormCoolDown, 1);           // all Storms have an uptime of 4 seconds

            var enemiesHitWithStormDown = WeaponHelper.GetEnemiesAttackedInDuration(duration: 3.0, loadout, weapon: BaseWeapon);
            var enemiesHitWithStormUp   = enemiesHitWithStormDown + BaseStorm.AttackCount;

            var averageEnemiesHit = enemiesHitWithStormUp * stormUptime + enemiesHitWithStormDown * (1 - stormUptime);

            return(averageEnemiesHit * BaseAOEWeapon.AttackCount / 4);            // arbituarily quarting the result because this thinks an XYZ WA hit's 8000 units, which is impossibly unrealistic
        }
        protected override double GetAttackCount(VLoadout loadout)
        {
            var orbsAffectedByAbility = 0.0;

            foreach (var weapon in OrbAttacksAndAbilities)
            {
                orbsAffectedByAbility += DurationAbilityEffectAppliesFor == 0
                                        ? (weapon.OrbTravelDuration * BasicOrbWeapon.OrbsPerAttack) / weapon.GetActualWeaponPeriod(loadout)
                                        : DurationAbilityEffectAppliesFor * weapon.OrbsPerAttack / weapon.GetActualWeaponPeriod(loadout);
            }

            var orbAttackSpeed = Math.Pow(0.96, loadout.Upgrades.AttackSpeedUpgrade);
            var attacksPerOrb  = OrbFreezeDuration / orbAttackSpeed;

            return(orbsAffectedByAbility * attacksPerOrb * WeaponHelper.GetEnemiesInRadius(RadiusOfOrbAttacks));
        }