I created an item upgrade feature with cloudscript.
I want to record every user upgrade. It could be a problem.
I tried to log, but nothing was recorded except when I ran it.
How do I use a saveable log?
I created an item upgrade feature with cloudscript.
I want to record every user upgrade. It could be a problem.
I tried to log, but nothing was recorded except when I ran it.
How do I use a saveable log?
Do you mean the log function that pre-defined in the CloudScript, as this documentation, especially this section Intermediate Overview: Globals and advanced arguments says, this function is designed for printing the info, not for persistent-recording. Could you tell us why do you want to store the all players’ upgrading item’s records? If your target is analytics, please check our documentations of Playfab Analytics firstly. Then you can use this server API WritePlayerEvent to write a PlayStreamEvent for every item upgrading operation. Then you can query them in the [Event History] page and [Explorer] page. If you have other targets, please clarify it, thanks.
Sometimes the user protests.
The reason is that the upgrade is wrong.
Then I must prove it.
I thought if I did <log.debug> on CloudScript, I would remain in Event Histroy - player_executed_cloudscript, but there was nothing.
What command should I use to leave a record there?
If so, the above solution could work. You can use this server API WritePlayerEvent to write a PlayStreamEvent for every item upgrading operation. Then you can query them in the [Event History] page and [Explorer] page.
<log.debug> isn't designed for recording an event in the event history. If you want to write this event -- "player_executed_cloudscript", when you call this API ExecuteCloudScript, please make sure the field GeneratePlayStreamEvent is true.
3 People are following this question.