Skip to content

Commit 43e16de

Browse files
Nyeriahxfurryclaude
authored
fix(Core/Wintergrasp): disband raid groups on battle end (azerothcore#26014)
Co-authored-by: Xfurry <xfurry.cmangos@outlook.com> Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 419af57 commit 43e16de

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

src/server/game/Battlefield/Battlefield.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -407,6 +407,14 @@ void Battlefield::EndBattle(bool endByTimer)
407407
OnBattleEnd(endByTimer);
408408
sScriptMgr->OnBattlefieldWarEnd(this, endByTimer);
409409

410+
for (uint8 team = 0; team < PVP_TEAMS_COUNT; ++team)
411+
{
412+
for (ObjectGuid const& guid : Groups[team])
413+
if (Group* group = sGroupMgr->GetGroupByGUID(guid.GetCounter()))
414+
group->Disband();
415+
Groups[team].clear();
416+
}
417+
410418
// Reset battlefield timer
411419
Timer = NoWarBattleTime;
412420
SendInitWorldStatesToAll();

0 commit comments

Comments
 (0)