mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-16 07:30:42 +01:00
Core/GameObject: Remove summoned game objects from the map after calling SetSpawnedByDefault(false) (#23120)
Closes #23115
This commit is contained in:
@@ -793,11 +793,10 @@ void GameObject::Update(uint32 diff)
|
||||
if (!m_respawnDelayTime)
|
||||
return;
|
||||
|
||||
// ToDo: Decide if we should properly despawn these. Maybe they expect to be able to manually respawn from script?
|
||||
if (!m_spawnedByDefault)
|
||||
{
|
||||
m_respawnTime = 0;
|
||||
DestroyForNearbyPlayers(); // old UpdateObjectVisibility()
|
||||
Delete();
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user