Core/SAI: Rename LeavingWorld to OnDespawn & use it in SAI (#28059)

(cherry picked from commit b9450bcdd0924ca69b5b2cc675f5c2b558ff9b47)
This commit is contained in:
offl
2022-09-05 19:43:09 +02:00
committed by Shauren
parent 496eba4e8d
commit b0164fb2b9
8 changed files with 18 additions and 5 deletions
+2 -2
View File
@@ -124,7 +124,7 @@ struct npc_pet_gen_soul_trader : public ScriptedAI
{
npc_pet_gen_soul_trader(Creature* creature) : ScriptedAI(creature) { }
void LeavingWorld() override
void OnDespawn() override
{
if (Unit* owner = me->GetOwner())
DoCast(owner, SPELL_ETHEREAL_PET_REMOVE_AURA);
@@ -150,7 +150,7 @@ struct npc_pet_lich : public ScriptedAI
{
npc_pet_lich(Creature* creature) : ScriptedAI(creature) { }
void LeavingWorld() override
void OnDespawn() override
{
if (Unit* owner = me->GetOwner())
DoCast(owner, SPELL_LICH_REMOVE_AURA);