Ejemplo n.º 1
0
 public void Link(PlayFabAuthService authService, AuthKeys authKeys)
 {
     PlayFabClientAPI.LinkFacebookInstantGamesId(new LinkFacebookInstantGamesIdRequest
     {
         FacebookInstantGamesSignature = authKeys.AuthTicket,
         AuthenticationContext         = authService.AuthenticationContext,
         ForceLink = authService.ForceLink
     }, resultCallback =>
     {
         authService.InvokeLink(AuthTypes.FacebookInstantGames);
     }, errorCallback =>
     {
         authService.InvokeLink(AuthTypes.FacebookInstantGames, errorCallback);
     });
 }
Ejemplo n.º 2
0
 public void Link(PlayFabAuthService authService, AuthKeys authKeys)
 {
     PlayFabClientAPI.LinkGameCenterAccount(new LinkGameCenterAccountRequest
     {
         GameCenterId          = authKeys.AuthTicket,
         AuthenticationContext = authService.AuthenticationContext,
         ForceLink             = authService.ForceLink
     }, resultCallback =>
     {
         authService.InvokeLink(AuthTypes.GameCenter);
     }, errorCallback =>
     {
         authService.InvokeLink(AuthTypes.GameCenter, errorCallback);
     });
 }
Ejemplo n.º 3
0
 public void Link(PlayFabAuthService authService, AuthKeys authKeys)
 {
     PlayFabClientAPI.LinkTwitch(new LinkTwitchAccountRequest
     {
         AccessToken           = authKeys.AuthTicket,
         AuthenticationContext = authService.AuthenticationContext,
         ForceLink             = authService.ForceLink
     }, resultCallback =>
     {
         authService.InvokeLink(AuthTypes.Twitch);
     }, errorCallback =>
     {
         authService.InvokeLink(AuthTypes.Twitch, errorCallback);
     });
 }
Ejemplo n.º 4
0
 public void Link(PlayFabAuthService authService, AuthKeys authKeys)
 {
     PlayFabClientAPI.LinkXboxAccount(new LinkXboxAccountRequest
     {
         XboxToken             = authKeys.AuthTicket,
         AuthenticationContext = authService.AuthenticationContext,
         ForceLink             = authService.ForceLink
     }, resultCallback =>
     {
         authService.InvokeLink(AuthTypes.XBoxLive);
     }, errorCallback =>
     {
         authService.InvokeLink(AuthTypes.XBoxLive, errorCallback);
     });
 }
 public void Link(PlayFabAuthService authService, AuthKeys authKeys)
 {
     PlayFabClientAPI.LinkGoogleAccount(new LinkGoogleAccountRequest
     {
         ServerAuthCode        = authKeys.AuthTicket,
         AuthenticationContext = authService.AuthenticationContext,
         ForceLink             = authService.ForceLink
     }, resultCallback =>
     {
         authService.InvokeLink(AuthTypes.GooglePlayGames);
     }, errorCallback =>
     {
         authService.InvokeLink(AuthTypes.GooglePlayGames, errorCallback);
     });
 }
 public void Link(PlayFabAuthService authService, AuthKeys authKeys)
 {
     PlayFabClientAPI.LinkKongregate(new LinkKongregateAccountRequest
     {
         KongregateId          = authKeys.AuthTicket,
         AuthenticationContext = authService.AuthenticationContext,
         ForceLink             = authService.ForceLink
     }, resultCallback =>
     {
         authService.InvokeLink(AuthTypes.Kongregate);
     }, errorCallback =>
     {
         authService.InvokeLink(AuthTypes.Kongregate, errorCallback);
     });
 }
 public void Link(PlayFabAuthService authService, AuthKeys authKeys)
 {
     PlayFabClientAPI.LinkNintendoSwitchDeviceId(new LinkNintendoSwitchDeviceIdRequest
     {
         NintendoSwitchDeviceId = PlayFabSettings.DeviceUniqueIdentifier,
         AuthenticationContext  = authService.AuthenticationContext,
         ForceLink = authService.ForceLink
     }, resultCallback =>
     {
         authService.InvokeLink(AuthTypes.NintendoSwitch);
     }, errorCallback =>
     {
         authService.InvokeLink(AuthTypes.NintendoSwitch, errorCallback);
     });
 }
Ejemplo n.º 8
0
 public void Link(PlayFabAuthService authService, AuthKeys authKeys)
 {
     PlayFabClientAPI.LinkOpenIdConnect(new LinkOpenIdConnectRequest
     {
         IdToken               = authKeys.AuthTicket,
         ConnectionId          = authKeys.OpenIdConnectionId,
         AuthenticationContext = authService.AuthenticationContext,
         ForceLink             = authService.ForceLink
     }, resultCallback =>
     {
         authService.InvokeLink(AuthTypes.OpenId);
     }, errorCallback =>
     {
         authService.InvokeLink(AuthTypes.OpenId, errorCallback);
     });
 }
 public void Link(PlayFabAuthService authService, AuthKeys authKeys)
 {
     PlayFabClientAPI.LinkWindowsHello(new LinkWindowsHelloAccountRequest
     {
         PublicKey             = authKeys.AuthTicket,
         AuthenticationContext = authService.AuthenticationContext,
         ForceLink             = authService.ForceLink,
         UserName = authService.Username
     }, resultCallback =>
     {
         authService.InvokeLink(AuthTypes.WindowsHello);
     }, errorCallback =>
     {
         authService.InvokeLink(AuthTypes.WindowsHello, errorCallback);
     });
 }
Ejemplo n.º 10
0
        public void Link(PlayFabAuthService authService, AuthKeys authKeys)
        {
            Authenticate(authService, resultCallback =>
            {
#if UNITY_ANDROID && !UNITY_EDITOR
                PlayFabClientAPI.LinkAndroidDeviceID(new LinkAndroidDeviceIDRequest
                {
                    AndroidDeviceId       = PlayFabSettings.DeviceUniqueIdentifier,
                    AuthenticationContext = authService.AuthenticationContext,
                    AndroidDevice         = SystemInfo.deviceModel,
                    OS        = SystemInfo.operatingSystem,
                    ForceLink = authService.ForceLink
                }, linkCallback =>
                {
                    authService.InvokeLink(AuthTypes.Silent);
                }, errorCallback =>
                {
                    authService.InvokeLink(AuthTypes.Silent, errorCallback);
                });
#elif UNITY_IPHONE || UNITY_IOS && !UNITY_EDITOR
                PlayFabClientAPI.LinkIOSDeviceID(new LinkIOSDeviceIDRequest
                {
                    DeviceId = PlayFabSettings.DeviceUniqueIdentifier,
                    AuthenticationContext = authService.AuthenticationContext,
                    DeviceModel           = SystemInfo.deviceModel,
                    OS        = SystemInfo.operatingSystem,
                    ForceLink = authService.ForceLink
                }, linkCallback =>
                {
                    authService.InvokeLink(AuthTypes.Silent);
                }, errorCallback =>
                {
                    authService.InvokeLink(AuthTypes.Silent, errorCallback);
                });
#else
                PlayFabClientAPI.LinkCustomID(new LinkCustomIDRequest
                {
                    CustomId = authService.GetOrCreateRememberMeId(),
                    AuthenticationContext = authService.AuthenticationContext,
                    ForceLink             = authService.ForceLink
                }, linkCallback =>
                {
                    authService.InvokeLink(AuthTypes.Silent);
                }, errorCallback =>
                {
                    authService.InvokeLink(AuthTypes.Silent, errorCallback);
                });
#endif
            }, errorCallback =>
            {
                authService.InvokeLink(AuthTypes.Silent, errorCallback);
            }, authKeys);
        }