question

Daniel Madera avatar image
Daniel Madera asked

Matchmaking with MPS

The project is a game consisting of 2 teams of 2 players each. I believe I have the ticket creation part sorted out because I managed to configure the queue with two teams and successfully match two tickets, where each ticket has its creator and a member. Once I get the match, I obtain the IP and port of the server and see from the portal that the instance transitions from Standby to Active. So far, so good.

Now, what I need is to be able to tell the game server which map to load, but I'm not sure where I can do that from.

In the ticket, I need to pass a list of possible maps that the players want to play on, and for the matchmaking to somehow enable the server instance to retrieve that information and modify the map accordingly.

Matchmaking
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

·
Neils Shi avatar image
Neils Shi answered

If you use API RequestMultiplayerServer to request a multiplayer server session, then there is a “SessionCookie” parameter which will be passed to the game server when requested. It can be used to communicate information such as game mode or map through the request flow. If you are using “enable the server allocation” feature, you can store map info in player attributes when creating the matchmaking ticket, then once matchmaking allocates a server for the match, server can call API GetMatch (set “ReturnMemberAttributes” to true) to access matched member attributes. In addition, we have recently launched a preview feature that allows you to get the matchmaking queue name after a server allocation. For more details, please refer to https://github.com/PlayFab/MpsSamples/blob/main/MatchmakeSample/matchMakingAndMps.md .

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.