diff options
author | Astellar <none@none> | 2010-01-07 00:24:58 +0300 |
---|---|---|
committer | Astellar <none@none> | 2010-01-07 00:24:58 +0300 |
commit | b0e7dc95a4a05f3e78c833c0de29749e4df044af (patch) | |
tree | 39a01d18b698f8cbf7152ae7fd8f9624ff05226a /src/game/Unit.cpp | |
parent | 3c3197ae71efffe723fa4b252f98d6f500d73ce4 (diff) |
Fixes issue 152. Now Improved Water Shield works as intended.
1. Removed hardcoded proc chance for Lesser Healing Wave (all ranks had equal proc chance).
2. Added proc chance for Chain Heal (patch 3.2).
3. Fixed bug with Lesser Healing Wave and Chain Heal rolled default spell proc chance at first and then correct chance in dummy proc. So they have never ever proced for low ranks of the talent.
4. Removed consumption of charges (patch 3.2).
--HG--
branch : trunk
Diffstat (limited to 'src/game/Unit.cpp')
-rw-r--r-- | src/game/Unit.cpp | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index 93694a21f2d..51fdd22253c 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -6918,15 +6918,24 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger // Improved Water Shield if (dummySpell->SpellIconID == 2287) { - // Lesser Healing Wave need aditional 60% roll - if (procSpell->SpellFamilyFlags[0] & 0x80 && !roll_chance_i(60)) + // Default chance for Healing Wave and Riptide + float chance = triggeredByAura->GetAmount(); + + if (procSpell->SpellFamilyFlags[0] & 0x80) + // Lesser Healing Wave - 0.6 of default + chance *= 0.6f; + else if (procSpell->SpellFamilyFlags[0] & 0x100) + // Chain heal - 0.3 of default + chance *= 0.3f; + + if (!roll_chance_f(chance)) return false; + // Water Shield if (AuraEffect const * aurEff = GetAura(SPELL_AURA_PROC_TRIGGER_SPELL, SPELLFAMILY_SHAMAN, 0, 0x00000020)) { uint32 spell = aurEff->GetSpellProto()->EffectTriggerSpell[aurEff->GetEffIndex()]; CastSpell(this, spell, true, castItem, triggeredByAura); - aurEff->GetParentAura()->DropAuraCharge(); return true; } return false; |