question

starkgaminginc avatar image
starkgaminginc asked

UE4 Blueprint - Setting player statistics (Server side)

Using the UE4 Blueprint SDK I am trying to update the player's wins and score. I've been able to GET player / title data with no issues so far. However, within blueprints it is a bit confusing on how to set player data / statistics.

First, I am using server-side logic to detect when a player wins or requires their score to be updated at the end of a match. So the server is the only one changing this value and the noted "allow players to change statistics" or I believe even CloudScript should not be needed.

From the server I am using the UpdatePlayerStatistic node (server api), I have the PlayFabId required but I cannot seem to figure out how to create the 'Statistics JSON Request' array that should contain the appropriate fields.

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

starkgaminginc avatar image starkgaminginc commented ·

In addition, my closest guess so far is to set the field somehow before attempting to run "UpdatePlayerStatistic". However, this causes the UE4 engine to crash.

0 Likes 0 ·
playfabguess.png (83.6 KiB)
starkgaminginc avatar image starkgaminginc commented ·

This is all I really am trying to achieve, accept for player statistics. (not title data)

0 Likes 0 ·
goal.png (42.3 KiB)
brendan avatar image
brendan answered

It looks like you got the info you needed on this in the other thread where you posted on this, yes (https://community.playfab.com/questions/18028/unreal-blueprints-working-with-json.html)?

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

starkgaminginc avatar image starkgaminginc commented ·

Thanks to a response from eswitzer07 I was able to get exactly what I needed. post: https://community.playfab.com/questions/18028/unreal-blueprints-working-with-json.html

This is what needs to be done -

0 Likes 0 ·
resolved.png (137.3 KiB)
starkgaminginc avatar image starkgaminginc commented ·

Sure is - sorry if I posted on the wrong thread! =) Too many chrome tabs it seems...

0 Likes 0 ·
emin-taskiran avatar image
emin-taskiran answered

@Brendan thanks mate!

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.