From 94df67b1c27c06017d2ff309d90ee589a60e24f0 Mon Sep 17 00:00:00 2001 From: sudlud Date: Thu, 4 Apr 2024 23:29:34 +0200 Subject: [PATCH] fix(Core/Battleground): correctly limit Eye of the Storm max points to 1600 (#18669) - before the max points could exceed 1600 on winning which e.g. resulted in the achievement 'The Perfect Storm' not beeing triggered correctly --- src/server/game/Battlegrounds/Zones/BattlegroundEY.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundEY.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundEY.cpp index 1b3fe32c8..226bcf709 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundEY.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundEY.cpp @@ -113,6 +113,8 @@ void BattlegroundEY::AddPoints(TeamId teamId, uint32 points) { uint8 honorRewards = uint8(m_TeamScores[teamId] / _honorTics); m_TeamScores[teamId] += points; + if (m_TeamScores[teamId] > BG_EY_MAX_TEAM_SCORE) + m_TeamScores[teamId] = BG_EY_MAX_TEAM_SCORE; for (; honorRewards < uint8(m_TeamScores[teamId] / _honorTics); ++honorRewards) RewardHonorToTeam(GetBonusHonorFromKill(1), teamId);