question

brendan avatar image
brendan asked

Asynchroneous multiplayer pvp

deldam
started a topic on Wed, 25 February 2015 at 1:39 AM

I am not sure if i should open a feature request but I try to find how i could do that:

players have a ranking "player vs player" think like a leaderboards this value increase or decrease as they lose or win match

so they can select other players in their ranking range, player have kind of base, we save it and serialize it, then other player can attack and destroy their base, so they will load the opponent player base setup

if fail call a lose function and do logic, if success do win logic on attacking and defending player, this nis not real time, so photon is not required.

i think this is a little like the games Clash of clan, is it possible to do this with playfab? what api i can use?

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

·
brendan avatar image
brendan answered

Best Answer
Brendan Vanous said on Wed, 25 February 2015 at 2:56 PM

Indeed, User Data would be the way to go. And since the game is asynchronous, it is also the case that Cloud Script could be used to drive the decision-making on key factors (to prevent cheating).

One key question was about having a score which is modified by wins and losses, which is used for matchmaking. This is similar to an ELO-type system, variations of which are used by a number of games for matchmaking. It's also possible to manage this using Cloud Script by having a Shared Group Data object tracking the "open" sessions, and negotiating creation of a session (represented with Player Data on both players - the recommendation being to use Player Internal Data, so that again, the client is blocked from cheating it directly) with a player whose session is listed in Shared Group Data with a ranking close to that of the current user. You would also want to use Title Data to hold the factors used for this matchmaking (like the acceptable delta between the ranks, how much to adjust rank on a win/loss, etc.).

We'll have an example of managing asynchronous games via Cloud Script post-GDC (we're working on it now, but we'll be very heads-down until after the conference). It won't show rank-based matchmaking, but that would be a straightforward addition, as described above.


3 Comments
deadstarcgs said on Wed, 25 February 2015 at 6:10 AM

At a guess, I'd say you would use the Player Data functionality which can be read using the GetUserData request and changed using the UpdateUserData request.


Brendan Vanous said on Wed, 25 February 2015 at 2:56 PM

Indeed, User Data would be the way to go. And since the game is asynchronous, it is also the case that Cloud Script could be used to drive the decision-making on key factors (to prevent cheating).

One key question was about having a score which is modified by wins and losses, which is used for matchmaking. This is similar to an ELO-type system, variations of which are used by a number of games for matchmaking. It's also possible to manage this using Cloud Script by having a Shared Group Data object tracking the "open" sessions, and negotiating creation of a session (represented with Player Data on both players - the recommendation being to use Player Internal Data, so that again, the client is blocked from cheating it directly) with a player whose session is listed in Shared Group Data with a ranking close to that of the current user. You would also want to use Title Data to hold the factors used for this matchmaking (like the acceptable delta between the ranks, how much to adjust rank on a win/loss, etc.).

We'll have an example of managing asynchronous games via Cloud Script post-GDC (we're working on it now, but we'll be very heads-down until after the conference). It won't show rank-based matchmaking, but that would be a straightforward addition, as described above.


Brendan Vanous said on Tue, 31 March 2015 at 11:50 AM

Quick follow-up: Our asynchronous game example has been posted. Here's a link to the forum post that walks through this, and provides links to the resources:

https://playfab.com/blog/2015/03/24/creating-turn-based-asynchronous-matchmaker-without-dedicated-server

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.

Gogoasdfg avatar image Gogoasdfg commented ·

Page not found. Is there still async. game example? Please share :)

1 Like 1 ·

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.