question

Ritik Agarwal avatar image
Ritik Agarwal asked

Is this possible to sync a player account info with two different player titles?

I want to use two-player titles for two games. For that I just want one player account which need to be synced with both.
For example, if there is two games game 1 and game 2.

suppose I am having 100 coins in my PLayfab account.


by logging in game 1, I spent 30 coins.

it should show 70 coins in game 2 when I log In.

If there is a way to do that please let me know.

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

Yes, it’s possible. Your requirements can be implemented using publisher data. Publisher data is data that spans one studio’s multiple titles, you can use the publisher data when you have multiple games that need to share common information. You can check this documentation -- How to use player publisher data to grant a reward for playing multiple titles to learn about how to reward players participating in more than one of your games.

For your situation, every time the player’s VC is changed, you need to reports the current VC to the publisher read-only/Internal data. Then you can use the publisher read-only/Internal data to update another title’s this player’s VC. In this progress, you may need to use the following API methods on CloudScript. GetUserInventory, UpdateUserPublisherInternalData, GetUserPublisherInternalData, AddUserVirtualCurrency and SubtractUserVirtualCurrency.

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.