Talk:Damage Calculator/@comment-15871805-20130901111534/@comment-11753608-20130901132257

You don't need the IF(Shields=0 or Crit>0 clauses.  You can just do this:

(((Health / (Health + Shields)) * ((TotalDmg * (1 - CritChance)) + (TotalCritDmg * CritChance) + (4 * DOTTick))) + ((Shields / (Health + Shields)) * ((ShieldDmg * (1 - CritChance)) + (ShieldCritDmg * CritChance) + (4 * DOTShieldTick)))))

Because if either of them are 0, the modifiers become 0 and 1. So, if shield is 0 then ((Shields / (Health + Shields)) = 0 and (((Health / (Health + Shields)) = 1 and it still returns the correct amount.

Likewise, if crit chance is 0 then  (TotalCritDmg * CritChance) = 0 and ((TotalDmg * (1 - CritChance)) = total damage * 1 and it also still returns the correct amount.

Try the two side by side to make sure but I am pretty positive you onlt need to do that part of it.

As for the shield formula, it might be round.