question

Siddharth avatar image
Siddharth asked

How to Subtract certain amount of virtual currency from all the players by using segment and automation of schedule task,How to Subtract certain amount of virtual currency from all the players ?

How to Subtract certain amount of virtual currency from all the players by using segment and automation of schedule task. it is allowed only grant the virtual currency to all the players, How do i subtract certain amount of virtual currency from all the players. please help me to resolve this problem.

Player DataCloudScriptscheduled tasks
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

What is the feature you're trying to implement, exactly? If this is something you want to occur on a regular basis, we should discuss the details so that we can work out the best approach. If you want to do a blanket, one-time reduction in VC from all players, you could potentially use a Cloud Script, but there are likely better approaches. The more details we have about the design-level vision of what you're going for, the better we can advise you on this.

4 comments
10 |1200

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

Siddharth avatar image Siddharth commented ·

yes, i want to subtract 50 virtual currency from all the users for one time only.

0 Likes 0 ·
brendan avatar image brendan Siddharth commented ·

Then I would recommend using a Cloud Script call as the action, and in that call, use SubtractUserVirtualCurrency.

0 Likes 0 ·
Siddharth avatar image Siddharth commented ·

I never used any cloud script before.

0 Likes 0 ·
brendan avatar image brendan Siddharth commented ·

There's an example Cloud Script in all newly created titles, as revision 1 in Automation->Cloud Script. It shows how to perform a range of tasks, including calling Server API methods.

There are also tutorials on using Cloud Scirpt here: https://api.playfab.com/docs/tutorials#landing-automation

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.