question

Nicholas Sweetland avatar image
Nicholas Sweetland asked

Shared Group Data, Matchmaking

1. I need to implement an online, turn-based multiplayer for a game where each player chooses a move, then the turn is calculated, much like an RPG. I read that using Shared Group Data is a way to implement this, but there are concerns about its scalability when many players read that shared data at the same time. My game would only need two players, and perhaps a limited number of spectators, to have access to this group data. Is this still still a valid method to implement this type of multiplayer?

2. If so, how would I handle matchmaking using a Player Statistic (player rank)? I read that Playfab's matchmaking service is not compatible with Shared Group Data.

MatchmakingmultiplayerShared Group Data
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
Gosen Gao avatar image
Gosen Gao answered
  • 1. How often does Shared Group Data change? If the frequency is not high, and it will not be modified by two players at the same time. Then it should be possible. Shared Group Data does not have a "lock" mechanism, If multiple write requests appear together, concurrent writes will result in data conflict. You should also consider the client request limit(100 calls per 2 minutes).
  • 2. You can follow this document to create your Matchmaking queue based on the player’s rank. When it gets matched, let one player create a Shared Group and store the SharedGroupId in both player’s Player Data. Then you can start your game.

For your case, I would suggest you to use PlayFab Multiplayer Server with Unity Mirror to implement your game. Mirror has integrated location synchronization which will save you a lot of time.

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Error rendering WebPanel (widgets/consolidation-widget.ftl): org.hibernate.hql.internal.ast.QuerySyntaxException: AvailableConsolidation is not mapped [from AvailableConsolidation up where up.node = :node]