public void OnUpdateGameSession(string rawUpdateGameSession, IAck ack) { log.DebugFormat("ServerState got the updateGameSession signal. rawGameSession : {0}", rawUpdateGameSession); if (!processReady) { log.Debug("Got an updated game session on inactive process. Sending false ack."); ack.Call(false); return; } log.Debug("Sending true ack."); ack.Call(true); Task.Run(() => { Com.Amazon.Whitewater.Auxproxy.Pbuffer.UpdateGameSession updateGameSession = JsonConvert.DeserializeObject <Com.Amazon.Whitewater.Auxproxy.Pbuffer.UpdateGameSession>(rawUpdateGameSession); GameSession gameSession = GameSession.ParseFromBufferedGameSession(updateGameSession.GameSession); gameSessionId = gameSession.GameSessionId; UpdateReason updateReason = UpdateReasonMapper.GetUpdateReasonForName(updateGameSession.UpdateReason); processParameters.OnUpdateGameSession( new UpdateGameSession(gameSession, updateReason, updateGameSession.BackfillTicketId)); }); }
public void OnUpdateGameSession(GameSession gameSession, UpdateReason updateReason, string backfillTicketId) { Log.DebugFormat("ServerState got the updateGameSession signal. GameSession : {0}", gameSession); if (!processReady) { Log.Warn("Got an updated game session on inactive process."); return; } Task.Run(() => { processParameters.OnUpdateGameSession(new UpdateGameSession(gameSession, updateReason, backfillTicketId)); }); }
public void OnUpdateGameSession(string rawUpdateGameSession, IAck ack) { log.DebugFormat("ServerState got the updateGameSession. rawGameSessionUpdate : {0}", rawUpdateGameSession); if (!processReady) { log.Debug("Got a update game session call on inactive process. Sending false ack."); ack.Call(false); return; } log.Debug("OnUpdateGameSession: Sending true ack."); ack.Call(true); Task.Run(() => { Protobuf.UpdateGameSession updateGameSession = JsonConvert.DeserializeObject <Protobuf.UpdateGameSession>(rawUpdateGameSession); GameSession gameSession = GameSession.ParseFromBufferedGameSession(updateGameSession.GameSession); UpdateReason updateReason = UpdateReasonMapper.GetUpdateReasonForName(updateGameSession.UpdateReason); processParameters.OnUpdateGameSession( new UpdateGameSession(gameSession, updateReason, updateGameSession.BackfillTicketId)); }); }