Exemplo n.º 1
0
 public static async Task <JsonElement> SetGamestateProperties(JsonElement element, EDGameState gameState, string commander, StarSystemChecker starSystemChecker)
 {
     return(await GameStateHandler.SetGamestateProperties(element, gameState, commander, starSystemChecker, (newState) =>
     {
         return new
         {
             systemName = gameState.SystemName,
             systemAddress = gameState.SystemAddress,
             systemCoordinates = gameState.SystemCoordinates,
             bodyName = gameState.BodyName,
             bodyId = gameState.BodyId,
             clientVersion = "Journal Limpet: " + SharedSettings.VersionNumber,
             odyssey = gameState.Odyssey,
             isBeta = false
         };
     }));
 }
Exemplo n.º 2
0
 public static async Task <JsonElement> SetGamestateProperties(JsonElement element, EDGameState gameState, string commander, StarSystemChecker starSystemChecker)
 {
     return(await GameStateHandler.SetGamestateProperties(element, gameState, commander, starSystemChecker,
                                                          (newState) => new
     {
         _systemAddress = gameState.SystemAddress,
         _systemName = gameState.SystemName,
         _systemCoordinates = gameState.SystemCoordinates,
         _marketId = gameState.MarketId,
         _stationName = gameState.StationName,
         _shipId = gameState.ShipId,
         _odyssey = gameState.Odyssey
     },
                                                          (transientState, elementAsDictionary) =>
     {
         elementAsDictionary["_systemAddress"] = transientState.GetProperty("_systemAddress");
         elementAsDictionary["_systemName"] = transientState.GetProperty("_systemName");
         elementAsDictionary["_systemCoordinates"] = transientState.GetProperty("_systemCoordinates");
         elementAsDictionary["_marketId"] = transientState.GetProperty("_marketId");
         elementAsDictionary["_stationName"] = transientState.GetProperty("_stationName");
         elementAsDictionary["_shipId"] = transientState.GetProperty("_shipId");
     }
                                                          ));
 }