From 64ad49e2ab00640febdc6760fb20511e5a1bc6ec Mon Sep 17 00:00:00 2001 From: Andrew Tomaka Date: Thu, 29 Nov 2012 12:38:20 -0500 Subject: [PATCH] Fix Elemental Damage on Weapon Bug --- libs/dpclass.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libs/dpclass.php b/libs/dpclass.php index fe09057..0c89943 100644 --- a/libs/dpclass.php +++ b/libs/dpclass.php @@ -125,7 +125,7 @@ class DPClass { } function elementalDamage() { - $totalElemental = 1; + $totalElemental = 0; foreach($this->stats as $stat => $value) { if(preg_match('/\+DPS \(.*\)/', $stat) > 0) { $totalElemental += $value; @@ -161,7 +161,7 @@ class DPClass { function modifyDPSUnbuffed() { $this->stats['DPS Unbuffed'] = $this->getStat('DPS Unbuffed') * - $this->getStat('All Elemental Damage') * + (1 + $this->getStat('All Elemental Damage')) * max(1, 1 + ($this->getStat('+DPS Against Elites') / 2)); }