Hello,
I'm trying to create a group on Playfab from my Unity project. First, I logged in as Playfab user and in Awake method getting my playerID (title) with code below:
PlayFabClientAPI.GetPlayerCombinedInfo(new PlayFab.ClientModels.GetPlayerCombinedInfoRequest { InfoRequestParameters = new PlayFab.ClientModels.GetPlayerCombinedInfoRequestParams { GetUserAccountInfo = true } }, result => { playerPlayfabID = result.InfoResultPayload.AccountInfo.TitleInfo.TitlePlayerAccount.Id; Debug.Log("playfabId " + playerPlayfabID); }, fail => { Debug.Log(fail.GenerateErrorReport()); });
Next, I created input field for group name and attached some method to button on scene with that code (I added EntityType parameter to EntityKeyMaker method because otherwise I got error (unkown Type or TypeString):
CreateGroup(createGroupInput.text, EntityKeyMaker(playerPlayfabID, "title_player_account"));
After executing the above code, I get a message in the console:
/Group/CreateGroup: The requesting entity is not allowed to complete this operation because the target entity is not a child of the requesting entity. UnityEngine.Debug:LogError (object) TestGuildController.GuildTestController:OnSharedError (PlayFab.PlayFabError) (at Assets/Scripts/_Test_Kamil/GuildTestController.cs:51) PlayFab.Internal.PlayFabUnityHttp:OnResponse (string,PlayFab.Internal.CallRequestContainer) (at Assets/PlayFabSDK/Shared/Internal/PlayFabHttp/PlayFabUnityHttp.cs:214) PlayFab.Internal.PlayFabUnityHttp/<Post>d__12:MoveNext () (at Assets/PlayFabSDK/Shared/Internal/PlayFabHttp/PlayFabUnityHttp.cs:153) UnityEngine.SetupCoroutine:InvokeMoveNext (System.Collections.IEnumerator,intptr)
How I can solve my problem? May I forgot about something?