Core/Battlegrounds: Clean up some Team/TeamId parameters to use enums instead of raw integer types

Port From (https://github.com/TrinityCore/TrinityCore/commit/1ef0c045202a6af33fb991f2ff765fa183ce976f)
This commit is contained in:
hondacrx
2024-02-04 16:31:49 -05:00
parent 00de526f7d
commit 5972f3b8a1
32 changed files with 360 additions and 368 deletions
@@ -121,13 +121,13 @@ namespace Game.PvP.HellfirePeninsula
base.Update(diff);
if (m_AllianceTowersControlled == 3)
TeamApplyBuff(TeamId.Alliance, SpellIds.AllianceBuff, SpellIds.HordeBuff);
TeamApplyBuff(BatttleGroundTeamId.Alliance, SpellIds.AllianceBuff, SpellIds.HordeBuff);
else if (m_HordeTowersControlled == 3)
TeamApplyBuff(TeamId.Horde, SpellIds.HordeBuff, SpellIds.AllianceBuff);
TeamApplyBuff(BatttleGroundTeamId.Horde, SpellIds.HordeBuff, SpellIds.AllianceBuff);
else
{
TeamCastSpell(TeamId.Alliance, -(int)SpellIds.AllianceBuff);
TeamCastSpell(TeamId.Horde, -(int)SpellIds.HordeBuff);
TeamCastSpell(BatttleGroundTeamId.Alliance, -(int)SpellIds.AllianceBuff);
TeamCastSpell(BatttleGroundTeamId.Horde, -(int)SpellIds.HordeBuff);
}
SetWorldState(WorldStateIds.CountA, (int)m_AllianceTowersControlled);