mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-13 17:19:07 +00:00
fix(Core/Spells): possible crashes within class spells (#9168)
This commit is contained in:
@@ -743,11 +743,16 @@ class spell_gen_proc_once_per_cast : public AuraScript
|
||||
|
||||
bool CheckProc(ProcEventInfo& eventInfo)
|
||||
{
|
||||
if (Player* player = eventInfo.GetActor()->ToPlayer())
|
||||
if (eventInfo.GetActor())
|
||||
{
|
||||
if (player->m_spellModTakingSpell == _spellPointer)
|
||||
return false;
|
||||
_spellPointer = player->m_spellModTakingSpell;
|
||||
if (Player* player = eventInfo.GetActor()->ToPlayer())
|
||||
{
|
||||
if (player->m_spellModTakingSpell == _spellPointer)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
_spellPointer = player->m_spellModTakingSpell;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user