question

Kyle Meadows avatar image
Kyle Meadows asked

How do I get all matches a player is currently in?

I want the ability to reconnect a player to game if they reconnected or their client closed. After they log in, I would fetch all matches they're currently in. If they are in one, I would get the match and automatically connect them.

How exactly would I do this? "ListMatchmakingTicketsForPlayer" seems to require a specific queue, but I want all queues. And I'm not sure if an already created match would still have a ticket.

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

·
Citrus Yan avatar image
Citrus Yan answered

ListMatchmakingTicketsForPlayer won’t return tickets that were already matched, hence you cannot use this approach to get all matches for the players. And, even if you managed to get all Match Ids for a player, using GetMatch to retrieve connection info respectively would also be a hassle. Therefore, we suggest that you manage all match data (connection info, members, etc.) for the player through Player Data, or cache it on the client-side so that they can directly retrieve it and connect to servers.

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.