caster nullptr check

This commit is contained in:
Emagi 2024-03-12 20:10:31 -04:00
parent 11cd551808
commit 1a641f23ce

View file

@ -1734,7 +1734,7 @@ bool SpellProcess::CastProcessedSpell(LuaSpell* spell, bool passive, bool in_her
send_to_sender = false;
}
if(spell->caster->GetZone()) {
if(spell->caster && spell->caster->GetZone()) {
spell->caster->GetZone()->SimpleMessage(CHANNEL_SPELLS_OTHER, effect_message.c_str(), target, 50, send_to_sender);
}
}