Actually make a change in Blade Barrier to fix the crash.

--HG--
branch : trunk
This commit is contained in:
p0wer
2010-04-20 15:55:20 -05:00
parent f8cf934775
commit 232dc7b6f7
+3 -2
View File
@@ -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;
}