fix(Core/Crashfix): Add nullptr checks for Blood Draining enchant (#8778)
This commit is contained in:
parent
a6cbe8aa57
commit
7c363c9040
@ -1310,8 +1310,10 @@ public:
|
||||
void HandleProc(AuraEffect const* /*aurEff*/, ProcEventInfo& eventInfo)
|
||||
{
|
||||
PreventDefaultAction();
|
||||
if ((eventInfo.GetActionTarget()->GetHealth() - eventInfo.GetDamageInfo()->GetDamage()) >= eventInfo.GetActionTarget()->CountPctFromMaxHealth(35))
|
||||
if (!eventInfo.GetActionTarget() || !eventInfo.GetDamageInfo() || (eventInfo.GetActionTarget()->GetHealth() - eventInfo.GetDamageInfo()->GetDamage()) >= eventInfo.GetActionTarget()->CountPctFromMaxHealth(35))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
const SpellInfo* spellInfo = sSpellMgr->GetSpellInfo(64569 /*SPELL_BLOOD_RESERVE*/);
|
||||
int32 basepoints = spellInfo->Effects[EFFECT_0].CalcValue() * this->GetStackAmount();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user