diff options
author | p0wer <none@none> | 2010-04-20 15:55:20 -0500 |
---|---|---|
committer | p0wer <none@none> | 2010-04-20 15:55:20 -0500 |
commit | 232dc7b6f77316c9e2f39066e30a56eb2c9ea17a (patch) | |
tree | 7b74b03da5731c745ea77b6fa91451592d8c4632 /src/game/Unit.cpp | |
parent | f8cf934775dd71d9e67bc0ab86f5001158528bb3 (diff) |
Actually make a change in Blade Barrier to fix the crash.
--HG--
branch : trunk
Diffstat (limited to 'src/game/Unit.cpp')
-rw-r--r-- | src/game/Unit.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index fcfdd7fb026..901d67b0276 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -8210,10 +8210,11 @@ bool Unit::HandleProcTriggerSpell(Unit *pVictim, uint32 damage, AuraEffect* trig // Blade Barrier if (auraSpellInfo->SpellFamilyName == SPELLFAMILY_DEATHKNIGHT && auraSpellInfo->SpellIconID == 85) { - if (this->GetTypeId() != TYPEID_PLAYER) + Player * plr = this->ToPlayer(); + if (this->GetTypeId() != TYPEID_PLAYER || !plr || plr->getClass() != CLASS_DEATH_KNIGHT) return false; - if(!this->ToPlayer()->IsBaseRuneSlotsOnCooldown(RUNE_BLOOD)) + if(!plr->IsBaseRuneSlotsOnCooldown(RUNE_BLOOD)) return false; } |