mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-30 09:03:47 +00:00
fix(Core/BattlegroundAV) Irondeep/Coldtooth Supplies never despawning (#8612)
This commit is contained in:
@@ -1610,7 +1610,7 @@ Creature* Battleground::GetBGCreature(uint32 type)
|
||||
return creature;
|
||||
}
|
||||
|
||||
void Battleground::SpawnBGObject(uint32 type, uint32 respawntime)
|
||||
void Battleground::SpawnBGObject(uint32 type, uint32 respawntime, uint32 forceRespawnDelay)
|
||||
{
|
||||
if (Map* map = FindBgMap())
|
||||
if (GameObject* obj = map->GetGameObject(BgObjects[type]))
|
||||
@@ -1622,6 +1622,11 @@ void Battleground::SpawnBGObject(uint32 type, uint32 respawntime)
|
||||
obj->SetLootState(GO_READY);
|
||||
obj->SetRespawnTime(respawntime);
|
||||
map->AddToMap(obj);
|
||||
|
||||
if (forceRespawnDelay)
|
||||
{
|
||||
obj->SetRespawnDelay(forceRespawnDelay);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user