aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorclick <none@none>2010-12-17 04:52:17 +0100
committerclick <none@none>2010-12-17 04:52:17 +0100
commita6df53bbe2ef1d9c444de6b43adb7c5da125f682 (patch)
treedde6d39fc56150a9ba70d54ad768acfc6e07cb53
parenta3de6e7c6f235ce79fdcb06cd6322bed37c4c498 (diff)
Core/Spells: Fix erraneous behaviour on hunter spell Lock and Load (disable charge-drop) - thanks to Dr. Tenma
Closes issue 3307 --HG-- branch : trunk
-rwxr-xr-xsrc/server/game/Entities/Unit/Unit.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp
index 3245b707129..a92da8470b5 100755
--- a/src/server/game/Entities/Unit/Unit.cpp
+++ b/src/server/game/Entities/Unit/Unit.cpp
@@ -6680,6 +6680,11 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger
if (!procSpell)
return false;
+ Spell * spell = ToPlayer()->m_spellModTakingSpell;
+
+ // Disable charge drop because of Lock and Load
+ ToPlayer()->SetSpellModTakingSpell(spell, false);
+
// Explosive Shot
if (procSpell->SpellFamilyFlags[2] & 0x200)
{
@@ -6688,10 +6693,12 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger
}
else
basepoints0 = CalculatePowerCost(procSpell, this, SpellSchoolMask(procSpell->SchoolMask)) * 4/10;
+
+ ToPlayer()->SetSpellModTakingSpell(spell, true);
+
if (basepoints0 <= 0)
return false;
- basepoints0 += 1; // standard basepoint increase for CastCustomSpell
target = this;
triggered_spell_id = 34720;
break;