Core/Misc: Move WorldState enum to SharedDefines

Port From (https://github.com/TrinityCore/TrinityCore/commit/ca62d93481f60807679c8632e09fa6f48f29de68)
This commit is contained in:
hondacrx
2022-02-23 17:01:51 -05:00
parent 3c6e9e7795
commit 628a24923c
8 changed files with 95 additions and 78 deletions
+2 -2
View File
@@ -729,9 +729,9 @@ namespace Game.Entities
BattleField wg = Global.BattleFieldMgr.GetBattlefieldByBattleId(1);//Wintergrasp battle
if (wg != null)
{
SendUpdateWorldState(3801, (uint)(wg.IsWarTime() ? 0 : 1));
SendUpdateWorldState(WorldStates.BattlefieldWgActive, (uint)(wg.IsWarTime() ? 0 : 1));
uint timer = wg.IsWarTime() ? 0 : (wg.GetTimer() / 1000); // 0 - Time to next battle
SendUpdateWorldState(4354, (uint)(GameTime.GetGameTime() + timer));
SendUpdateWorldState(WorldStates.BattlefieldWgTimeNextBattle, (uint)(GameTime.GetGameTime() + timer));
}
}
}