public EnGameLiveInfo(GameLiveInfo gi) { GameState = gi.GameState.ToString(); Turn = gi.Turn; TurnStartTime = gi.TurnStartTime; DateTime now = DateTime.Now; PlayerStates = gi.PlayerStates.Select(p => new EnPlayerLiveInfo(p, Turn, TurnStartTime, now)).ToArray(); }
private void GetLiveInfoImpl(GetLiveInfoReq req, GetLiveInfoResp resp) { GameLiveInfo gi = Server.GameManager.GetLiveInfo(req.GameId, Server.TeamRegistry.GetTeam(req.Auth.TeamName)); resp.GameLiveInfo = new EnGameLiveInfo(gi); }