More work on new worldstate system

Port From (https://github.com/TrinityCore/TrinityCore/commit/a161b6cd328bbcf56950664f677fba716659f0d5)
This commit is contained in:
hondacrx
2022-06-30 00:30:55 -04:00
parent 57d3221a93
commit 0e910e01c4
6 changed files with 0 additions and 78 deletions
-17
View File
@@ -737,23 +737,6 @@ namespace Game.Entities
//SendPacket(packet);
}
//Battlefields
void SendBattlefieldWorldStates()
{
// Send misc stuff that needs to be sent on every login, like the battle timers.
if (WorldConfig.GetBoolValue(WorldCfg.TolbaradEnable))
{
BattleField tb = Global.BattleFieldMgr.GetBattlefieldByBattleId(BattlefieldIds.TB);
if (tb != null)
{
SendUpdateWorldState(WorldStates.BattlefieldTbFactionControlling, (uint)(tb.GetDefenderTeam() + 1));
uint timer = tb.GetTimer() / 1000;
SendUpdateWorldState(WorldStates.BattlefieldTbTimeBattleEnd, (uint)(tb.IsWarTime() ? (uint)(GameTime.GetGameTime() + timer) : 0));
SendUpdateWorldState(WorldStates.BattlefieldTbTimeNextBattle, (uint)(!tb.IsWarTime() ? (uint)(GameTime.GetGameTime() + timer) : 0));
}
}
}
//Arenas
public void SetArenaTeamInfoField(byte slot, ArenaTeamInfoType type, uint value)
{