mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-23 05:36:23 +00:00
fix(Core/BattlegroundAV) Irondeep/Coldtooth Supplies never despawning (#8612)
This commit is contained in:
@@ -1194,13 +1194,18 @@ bool GameObject::IsInvisibleDueToDespawn() const
|
||||
void GameObject::SetRespawnTime(int32 respawn)
|
||||
{
|
||||
m_respawnTime = respawn > 0 ? time(nullptr) + respawn : 0;
|
||||
m_respawnDelayTime = respawn > 0 ? respawn : 0;
|
||||
SetRespawnDelay(respawn);
|
||||
if (respawn && !m_spawnedByDefault)
|
||||
{
|
||||
UpdateObjectVisibility(true);
|
||||
}
|
||||
}
|
||||
|
||||
void GameObject::SetRespawnDelay(int32 respawn)
|
||||
{
|
||||
m_respawnDelayTime = respawn > 0 ? respawn : 0;
|
||||
}
|
||||
|
||||
void GameObject::Respawn()
|
||||
{
|
||||
if (m_spawnedByDefault && m_respawnTime > 0)
|
||||
|
||||
@@ -811,6 +811,7 @@ public:
|
||||
}
|
||||
|
||||
void SetRespawnTime(int32 respawn);
|
||||
void SetRespawnDelay(int32 respawn);
|
||||
void Respawn();
|
||||
[[nodiscard]] bool isSpawned() const
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user