question

Brent Batas (Lisk) avatar image
Brent Batas (Lisk) asked

How to get session cookie from match id?

I'm looking to be able to store/retrieve some custom data that is tied to a MatchId. I need this to support existing functionality in my game with legacy multiplayer.

It looks like I can pass some custom information via a session cookie after calling RequestMultiplayerServer()

https://api.playfab.com/documentation/multiplayer/method/RequestMultiplayerServer

However, I am having trouble figuring out how to retrieve it. I currently retrieve match info from a MatchId by calling GetMatch()

https://api.playfab.com/documentation/multiplayer/method/GetMatch

I would expect to see some information about session cookies in GetMatch, but there isn't any on the documentation page.

MatchmakingCustom Game 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.

1 Answer

·
Sarah Zhang avatar image
Sarah Zhang answered

When we use PlayFab Matchmaking Service, we are unable to pass the session cookie to PlayFab allocation call. MatchId will be allocated to the session instead of sessionId. But when we CreateMatchmakingTicket we can pass MatchmakingPlayerAttributes to Match. And when we GetMatch, matchmaking attributes for each membercan be returned in the response for match requests. Maybe you can use MatchmakingPlayerAttributes instead of a session cookie. Please click those links to navigate to API references.

1 comment
10 |1200

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

Brent Batas (Lisk) avatar image Brent Batas (Lisk) commented ·

MatchmakingPlayerAttributes looks perfect, thank you!

0 Likes 0 ·

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.