question

Niklas Gawell avatar image
Niklas Gawell asked

Action from two players to make decision server side

We need to add a feature where two players sends a message, and when both players have done so, the server determines the resulting change to player statistics. Not totally unsimilar to https://community.playfab.com/questions/10657/auction-system-possible.html

The answer then (2017) was that a custom game server could be used for this. Is that still the answer, or is there now a featuer in for instance CloudScript that could achieve the same thing?

CloudScriptCustom 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.

Sarah Zhang avatar image
Sarah Zhang answered

As this thread said, if your game is an asynchronous multiplayer game, you can use Shared Group Dataand Cloud Script function to achieve the server-side feature you said. You can follow this example to let players take turns modifying the data via CloudScript. The difference from the example is, in your case, you can use a specific Player Internal Data K/V pair to store a flag to mark whether the play has completed the game. After the second player updated the K/V pair, you can invoke a CloudScript function to do the validation and update the statistics.

If your game is using the synchronous multiplayer model, using custom servers would be the more suitable answer.

10 |1200

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

Niklas Gawell avatar image
Niklas Gawell answered

Thank you, I'll investigate the options and see where I end up.

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.