diff options
author | Keader <keader.android@gmail.com> | 2019-07-24 08:31:34 -0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-07-24 08:31:34 -0300 |
commit | 4c2f7df4f39cd98eae21bc64ebac59e3d2eea577 (patch) | |
tree | 7a3bd80bea6bb037ad4c9f4e5920321a9459d578 /src | |
parent | 8116c3cb663e880efb9ba80180c3f2b991661d94 (diff) |
Core/Spells: Added spellgroup support to HandleModCastingSpeed (#23592)
And fixed stack of Power Infusion, Bloodlust, Icy veins and Heroism.
Diffstat (limited to 'src')
-rw-r--r-- | src/server/game/Spells/Auras/SpellAuraEffects.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/server/game/Spells/Auras/SpellAuraEffects.cpp b/src/server/game/Spells/Auras/SpellAuraEffects.cpp index ccfc442725f..d643235ed26 100644 --- a/src/server/game/Spells/Auras/SpellAuraEffects.cpp +++ b/src/server/game/Spells/Auras/SpellAuraEffects.cpp @@ -3168,7 +3168,7 @@ void AuraEffect::HandleAuraModSchoolImmunity(AuraApplication const* aurApp, uint target->GetThreatManager().EvaluateSuppressed(); } else - { + { // do not remove unit flag if there are more than this auraEffect of that kind on unit if (target->HasAuraType(GetAuraType())) return; @@ -3901,6 +3901,13 @@ void AuraEffect::HandleModCastingSpeed(AuraApplication const* aurApp, uint8 mode return; } + int32 spellGroupVal = target->GetHighestExclusiveSameEffectSpellGroupValue(this, GetAuraType()); + if (abs(spellGroupVal) >= abs(GetAmount())) + return; + + if (spellGroupVal) + target->ApplyCastTimePercentMod(float(spellGroupVal), !apply); + target->ApplyCastTimePercentMod((float)GetAmount(), apply); } |