question

alihcme avatar image
alihcme asked

Updating player language

I am trying to update player language following this guide. I am unable to access following request type and method call:

SetProfileLanguageRequest

PlayFabServerAPI.SetProfileLanguage


I am using Unity SDK v2.39

Please let me know if I am missing something.

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

To access SetProfileLanguage, the proper way is

PlayFabProfilesAPI.SetProfileLanguage

If you cannot access PlayFabProfilesAPI, please enable Entity API at PlayFab Unity Editor Extension. However, I am not sure if Unity SDK v2.39 supports it. Hence, if there is not, please consider updating your SDK to the latest version (v2.56).

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

brendan avatar image brendan commented ·

Can you also post the error message you're getting when you try making the call?

0 Likes 0 ·
alihcme avatar image alihcme brendan commented ·

Above posted guide is outdated as PlayFabServerAPI does not contain definition for

SetProfileLanguage.

Anyway as suggested by @SethDu I have implemented SetProfileLanguage which is defined in PlayFabProfilesAPI.

I am getting this error now with new call " No title_player_account profile found at MY_ENTITY_ID". I am getting my entity ID from login result and then getting updated profile version number as well. What am I missing here?

0 Likes 0 ·
Andy avatar image Andy ♦♦ alihcme commented ·

That error definitely implies that the entity id you're providing isn't a valid title_player_account. Can you validate it on the player's profile page? It's one of the top numbers in the field labeled "Player ID (title)".

If you're convinced the Id is correct, go ahead and share it along with your title id so that we can reproduce the error and troubleshoot.

0 Likes 0 ·
plourdegui avatar image plourdegui commented ·

Could we please get a code example of how to achieve this via the Unity SDK?

I could not figure out what the Entity and ExpectedVersion field require. Where may I find this data?

0 Likes 0 ·
hendawi avatar image hendawi plourdegui commented ·

Sure, Here is sample file I made for you: https://textuploader.com/1a2ad


1 Like 1 ·

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.