# WoW attack speed calculation

Reading up on attack speed calculations for World of Warcraft I noticed that the formula for attack speed is:

Attack_speed = "current attack speed" / (("Percent increase or decrease" / 100) + 1 )

So with a weapon of speed 1.8 and activating a 40% attack speed buff for example we would have:

Attack_speed = 1.8 / ( (40 / 100) + 1 ) = 1.2857

So I am just wondering why is there a +1 in the formula. Logically I would assume that one would calculate the attack speed like this:

Attack_speed = 1.8 - (1.8 * (40 / 100)) = 1.08

Which is just subtracting the 40% of 1.8 from 1.8, which is how one would normally calculate a percentage in math. Is this just by design or is there some logic to this?

Let's look at your particular suggestion for a formula and what range of values it is able to handle:

attack_speed = 1.8 - (1.8 * (x / 100))


What if x is larger than 100? Now you have a negative attack speed. What is that even supposed to mean mechanics-wise?

Adding a 1 when calculating a divisor ensures that the division will always reduce the value and never increase it.

Without the +1, the divisor could in some cases be between 0.0 and 1.0. If you divide by a number in that range, the value increases. But the designer who came up with the attack speed modification mechanic likely intended it to only ever reduce attack speed and never increase it. So the +1 is added to avoid this edge-case.

Only under the premise, of course, that the rest of the term can not be negative. However, that edge-case is easy to rule out by introducing the general rule that "No stat can ever be negative". This is a constraint which is pretty easy to enforce, pretty easy to remember for anyone involved in the design and development process of the game and it also rules out a lot of other edge-cases which would otherwise require special handling.

The +1 is in there because Attack_speed is actually a cooldown stat, where half as much Attack_speed makes you attack twice as fast. If you have a "+100% increase" to your attack speed with the WoW formula, you get outputs like Attack_speed = 1.8 / ( (100 / 100) + 1 ) = 0.9. Similarly, if you have a "-99% decrease" to your attack speed with the WoW formula, you get outputs like Attack_speed = 1.8 / ( (-99 / 100) + 1 ) = 180, so you attack 100 times less often.

From a balance perspective, this means that stacking bonuses to attack speed linearly scales your total DPS: two +100% bonuses to attack speed only triple your DPS, whereas with your suggested formula one +50% bonus to attack speed would double your DPS, while adding another one would send it all the way to insanity.

I was not involved in the development of WoW, but reading the first formula, I'd say that they added 1 to prevent the case (that may happen a lot with very low level / unnequipped characters) of division by zero. If the "Percent increase or decrease" value is 0, you'll end up with "current attack speed" being divided by zero. In the "+1" version the only case that could give a division by zero would be to have a 100% decrease of speed (that would give (-100/100)+1 = -1+1 = 0).