Hi. I am getting 409 conflict and there are just 2 API calls. This is my current code:
public void Login() { string customId = ""; if (PlayerPrefs.HasKey("unique_identifier")) { customId = PlayerPrefs.GetString("unique_identifier"); } else { customId = System.Guid.NewGuid().ToString(); PlayerPrefs.SetString("unique_identifier", customId); } Debug.Log("UNIQUE IDENTIFIER: " + customId); LoginWithCustomIDRequest request = new LoginWithCustomIDRequest() { TitleId = PlayFabSettings.TitleId, CreateAccount = true, CustomId = customId //SystemInfo.deviceUniqueIdentifier }; PlayFabClientAPI.LoginWithCustomID(request, (result) => { PlayFabId = result.PlayFabId; Debug.Log("Got PlayFabID: " + PlayFabId); Dictionary<string, string> data = new Dictionary<string, string>(); if (result.NewlyCreated) { Debug.Log("(new account)"); setInitNewAccountData(false); string name = result.PlayFabId; name = "Guest"; for (int i = 0; i < 6; i++) { name += UnityEngine.Random.Range(0, 9); } data.Add("PlayerName", name); //addCoinsRequest(StaticStrings.initCoinsCount); } else { CheckIfFirstTitleLogin(PlayFabId, false); Debug.Log("(existing account)"); } data.Add("LoggedType", "Guest"); GameManager.Instance.myPlayerData.UpdateUserData(data); GameManager.Instance.nameMy = name; PlayerPrefs.SetString("LoggedType", "Guest"); PlayerPrefs.Save(); fbManager.showLoadingCanvas(); GetPhotonToken(); }, (error) => { Debug.Log("Error logging in player with custom ID:"); Debug.Log(error.ErrorMessage); GameManager.Instance.connectionLost.showDialog(); }); }
setInitNewAccountData(false) and GameManager.Instance.myPlayerData.UpdateUserData(data) call UpdateUserData and they are only 2 API calls being but still getting 409 conflict error. I have exactly same code on another project of mine and it works perfectly on that project. Any solution?