Search Unity

[SOLVED] PlayFab - Can't login

Discussion in 'Multiplayer' started by Deleted User, Feb 10, 2015.

  1. Deleted User

    Deleted User

    Guest

    I'm getting a "Could not resolve host" error everytime...

    Code (CSharp):
    1.                 void Awake ()
    2.                 {
    3.                         LoginWithAndroidDeviceIDRequest request = new LoginWithAndroidDeviceIDRequest ();
    4.                         PlayFabData.TitleId = "2332";
    5.                         request.TitleId = PlayFabData.TitleId;
    6.                         Debug.Log ("title id = " + request.TitleId);
    7.                         request.AndroidDeviceId = SystemInfo.deviceUniqueIdentifier;
    8.                         request.OS = SystemInfo.operatingSystem;
    9.                         request.AndroidDevice = SystemInfo.deviceModel;
    10.                         request.CreateAccount = true;
    11.                         PlayFabClientAPI.LoginWithAndroidDeviceID (request, OnRegistration, OnPlayFabError);
    12.                 }
    13.  
    14.                 void OnRegistration (LoginResult result)
    15.                 {
    16.                         Debug.Log ("logged in");
    17.                         PlayFabData.AuthKey = result.SessionTicket;}
     
  2. Meltdown

    Meltdown

    Joined:
    Oct 13, 2010
    Posts:
    5,822
    I think you'll get a better response if you contact their support directly. Or post on their forums.
     
  3. Deleted User

    Deleted User

    Guest

  4. Brendan-Vanous

    Brendan-Vanous

    Joined:
    Nov 7, 2014
    Posts:
    73
    For simplicity, I'll just bring the key info over here. :)

    The issue in this case was that the Title ID wasn't set in the configuration file (https://github.com/PlayFab/UnitySDK - "Configuring the Plugin"), in spite of the developer entering it there and clicking save. From his write-up of the solution:


    I'm not sure what fixed it but the steps I took before the problem was fixed were:
    - Closed the project and opened the PlayFab AngryBirds demo (which didn't work either)
    - Closed that one and re-opened my project
    - Loaded the scene
    - Clicked "save config" 10 times
    - Fixed