question

YoonTaeWhan avatar image
YoonTaeWhan asked

I want to Modify other PlayerData

I make ManagerSceen and using PlayFabClientAPI.GetUserData, Manager receive other playerdata

I want to make Manager modify other playerdata

how can i do this in unity and c# code

thank you

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

Firstly, what is "other Playerdata"? Does it mean one player’s other data or other Players’ Playerdata? According to your descriptions, it looks like you have received the Playdata you want via PlayFabClientAPI.GetUserData, then you want to modify it, is it right?

If you mean to update one player’s Playerdata via PlayFab API. Client API UpdateUserData can be used for such usages, you can click the link to check the API references. The “modify” feature essentially means to update the Playerdata in the background. From the Unity UI layer, you need to implement the corresponding features of entering text.

If you mean to update other player’s playerdata. We recommend that only when you use Unity to develop an Admin manager tool or custom servers, you can call Admin/Server API on Unity. If so, please follow these steps to enable Admin/Server API calls in Unity.

1. Open the Unity Editor, navigate to [Windows]->[PlayFab]->[Editor Extensions].

2. Navigate to [PlayFab EdEx] window, choose [SETTINGS]->[API] tab.

3. Check the [ENABLE ADMIN API]’s box and the [ENABLE SERVER API]’s box.

Then you can use Admin/Server API UpdateUserData to update every player’s playerdata. In addition, if you are developing an admin manager tool, please use Admin/Server API GetUserData instead of Client API GetUserData. Using Client API in the admin manager tool may exceed the limit of client API call’s rate.

1 comment
10 |1200

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

YoonTaeWhan avatar image YoonTaeWhan commented ·

Thank you so much

I solved problem by PlayFabAdminAPI.UpdateUserData

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.