Can you describe your use case for updating the game session properties while the game session is active?
Another user had a requirement to adjust game properties to avoid players joining once the session left the lobby: https://forums.awsgametech.com/t/how-to-go-about-creating-updating-game-session-properties-for-a-lobby-system/6746
AFAIK these are immutable during the session (as you can see UpdateGameSession doesn't allow them to be changed).
Why not start a new match search/new game session with your new properties? Or are you managing some state here?
I'll ping the GameLift service team to see if they have any updates/advice for you as I see you also posted on https://forums.awsgametech.com/t/can-gamesessionproperties-be-updated-with-a-call-to-updategamesession/4586/4
Hi, It's for a lobby system. The plan was to store the map id, the game rules, etc. And I would like them to be in the Game Properties so that we can know these properties without having to join. The admin of a game can change these properties.
Hello Eloujah! As Pip mentioned and you have figured out, game session properties are immutable and can only be set on CreateGameSession right now. I've asked the team to reconsider prioritization for this request since it has come up a few times over the years.
Looking at other alternatives that you could take advantage of today:
As Pip suggested, if your create a new GameSession at the start of every match, then you can update the mapId, rules, and other GameSession properties in CreateGameSession. The only limitation with this approach is that you can't change the map/rules in the middle of a match. Any changes made by an admin of your game would take place at the start of the next match.
If the above idea doesn't work with your game model, you could also look at utilizing the Name field of the GameSession to store/parse out information that can be updated. As an example, "lobby-MyGameName_mapId-dedust_rule1-abc123_rule2-def456" could be easily assembled and parsed by your game client. The main limitation here is a 1024 character limit, which would result in an Exception from GameLift if you tried to use more characters than that.
Hope those ideas help and I'll let you know if I hear anything on prioritizing updating GameSession properties!
I think I'll go for the Name for the moment. I was thinking about that but I wasn't sure if it is a good way to store data. I'll try with JSON and custom parsing and see which one is the best. With the custom parsing, I'll need to add some security so that the players can't inject properties.
GameProperty in the UpdateGameSession()?asked 2 years ago
Can gameSessionProperties be updated with a call to UpdateGameSession?asked 5 years ago
Error on DeleteEndpoint operation: Cannot update in-progress endpointasked 5 months ago
we lost phone with MFA code that can be verified 3 company accounts .asked 2 months ago
RDS malfunctioning after upgrading 9.6 to 12.7 (accidentally in the same day that we had AWS outage)asked 10 months ago
Can we export the mongodb using the data pipeline?Accepted Answerasked 7 years ago
Is there any limit to the number or age of events logged in CloudFormation event history?Accepted Answerasked a year ago
Can you edit the data in an Amazon QuickSight dashboard after it's published?Accepted Answerasked 2 years ago
Can we create a Table in Aurora during the infra setup using terraform IaaC code ?Accepted Answerasked 5 months ago
S3 Inventory : Is there a limit to the number of objects in a bucket that will show up in the inventory?Accepted Answerasked 4 years ago