Hi,
When my game starts, I authenticate Playfab with Photon as per below script. This works fine. Then not long after I log into facebook as per below script. No issues here either and everything seems to be working correctly. But then when I go to create a game, I get the error:
OnCreateRoomFailed (Failed to create game on https:xxxxxxxxx/RoomCreated?:Error response ResultCode=2 Message=User not found. Any suggestions on what may be causing this error?
Thanks in advance!
private void AuthenticateWithPhoton(GetPhotonAuthenticationTokenResult obj) { LogMessage("Photon token acquired: " + obj.PhotonCustomAuthenticationToken + " Authentication complete."); var customAuth = new AuthenticationValues { AuthType = CustomAuthenticationType. Custom }; customAuth.AddAuthParameter("username", _playFabPlayerIdCache); // expected by PlayFab custom auth service customAuth.AddAuthParameter("token", obj.PhotonCustomAuthenticationToken); PhotonNetwork.AuthValues = customAuth; } private void OnFacebookLoggedIn() { // AccessToken class will have session details string aToken = AccessToken.CurrentAccessToken.TokenString; if (facebookAccessToken.gameObject.activeSelf) { facebookAccessToken.text = AccessToken.CurrentAccessToken.TokenString; } string facebookId = AccessToken.CurrentAccessToken.UserId; PhotonNetwork.AuthValues = new AuthenticationValues(); PhotonNetwork.AuthValues.AuthType = CustomAuthenticationType.Facebook; PhotonNetwork.AuthValues.UserId = facebookId; // alternatively set by server PhotonNetwork.AuthValues.AddAuthParameter("token", aToken); PhotonNetwork.ConnectUsingSettings(); }