mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-16 10:30:27 +00:00
fix(Scripts/Midsummer): correctly despawn gameobjects (#19387)
This commit is contained in:
@@ -243,6 +243,7 @@ struct npc_midsummer_bonfire : public ScriptedAI
|
||||
if (_spellFocus)
|
||||
{
|
||||
_spellFocus->DespawnOrUnsummon();
|
||||
_spellFocus->AddObjectToRemoveList();
|
||||
_spellFocus = nullptr;
|
||||
}
|
||||
|
||||
@@ -378,7 +379,10 @@ struct npc_midsummer_bonfire_despawner : public ScriptedAI
|
||||
{
|
||||
// spawnID is 0 for temp spawns
|
||||
if (0 == (*itr)->GetSpawnId())
|
||||
{
|
||||
(*itr)->DespawnOrUnsummon();
|
||||
(*itr)->AddObjectToRemoveList();
|
||||
}
|
||||
}
|
||||
|
||||
me->DespawnOrUnsummon();
|
||||
|
||||
Reference in New Issue
Block a user