question

Jan Vacek avatar image
Jan Vacek asked

Getting rewards after player confirms the message

Hello, If some action runs on playfab, for example player statistics reset, is it possible to first send a message to a player, where he can read what happened and what items is he gonna claim and then claim it and have these items collected right after he confirms that message? Because its really weird if you are playing, then reset time comes, nothing happens and you have new items in your inventory

any tips please? I dont want to write long cloudscripts with hardcoded itemIds, I want to select them in dashboard and have a control over these rewards

Player Inventory
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

·
Seth Du avatar image
Seth Du answered

No it is not supported since the receive status of a push notification cannot be monitored by PlayFab.

However, this feature can be easily done via workarounds, and for many customized feature, you will need to implement Cloud Script functions. For example:

  • Adding different ranks in Prize Table and Set Execute Cloud Script/Azure Function as the actions
  • In the function, the rank position will be read from “context” and based on that information, the prize information will be selected and stored somewhere temporarily, for example, Player Read-Only Data.
  • The Push Notification will be the other action of the Prize Table, and the onReceived function of it is to refresh the Player Read-Only Data and inform that “you have a reward to be claimed.”
  • Implement a claiming Cloud Script/Azure Function, and when Player actively click the UI to claim the rewards, the function will read the specific value in Read-Only Data to grant the items, then clean that Key’s values.
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.