ドキュメント

サポート

Authentication for Unreal Engine

Authentication for Unreal Engine

UAuthenticationBlueprintApi クラス

Reference the Blueprint Application Programming Interface for authentication operations.
読み終わるまでの所要時間 5 分最終更新 14日前

宣言
UCLASS()class UAuthenticationBlueprintApi : public UBlueprintFunctionLibrary

デリゲート

FAuthenticationResponseDelegate

宣言

DECLARE_DYNAMIC_DELEGATE_OneParam(FAuthenticationResponseDelegate, FAuthenticationResponse, Response)

戻り値の型

FAuthenticationResponse

FAuthenticationStateChangedResponseDelegate

宣言

DECLARE_DYNAMIC_DELEGATE_OneParam(FAuthenticationStateChangedResponseDelegate, FAuthenticationStateChangedResponse, Response)

戻り値の型

FAuthenticationStateChangedResponse

FAuthenticationGetUserDelegate

宣言

DECLARE_DYNAMIC_DELEGATE_OneParam(FAuthenticationGetUserDelegate, FAuthenticationUserResponse, Response)

戻り値の型

FAuthenticationUserResponse

FAuthenticationDeleteUserDelegate

宣言

DECLARE_DYNAMIC_DELEGATE_OneParam(FAuthenticationDeleteUserDelegate, bool, bResponse)

戻り値の型

Boolean

FAuthenticationPlayerProfileChangedResponseDelegate

宣言

DECLARE_DYNAMIC_DELEGATE_OneParam(FAuthenticationPlayerProfileChangedResponseDelegate, FAuthenticationPlayerProfileChangedResponse, Response)

戻り値の型

FAuthenticationPlayerProfileChangedResponse

FAuthenticationPlayerProfileDeletedResponseDelegate

宣言

DECLARE_DYNAMIC_DELEGATE_OneParam(FAuthenticationPlayerProfileDeletedResponseDelegate, FAuthenticationPlayerProfileDeletedResponse, Response)

戻り値の型

FAuthenticationPlayerProfileDeletedResponse

メソッド

Sign In Anonymously

現在のユーザーを匿名でサインインします。認証情報は必要なく、セッションは現在のデバイスに限定されます。

宣言

UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")static void SignInAnonymously(FAuthenticationSignInOptions Options, FAuthenticationResponseDelegate ResponseDelegate)

パラメーター

名前

説明

オプションFAuthenticationSignInOptionsサインインのオプション。
Response DelegateFAuthenticationResponseDelegateAPI が応答を返したときに実行されるデリゲート。

Get User Info

現在のプレイヤーの情報を返します (アカウント作成日時やリンクされた外部 ID など)。

宣言

UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")void GetUserInfo(FAuthenticationGetUserDelegate ResponseDelegate) const

パラメーター

名前

説明

Response DelegateFAuthenticationGetUserDelegateAPI が応答を返したときに実行されるデリゲート。

Delete User

現在サインインしているユーザーを完全に削除します。

宣言

UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")static void DeleteUser(FAuthenticationDeleteUserDelegate ResponseDelegate)

パラメーター

名前

説明

Response DelegateFAuthenticationDeleteUserDelegateAPI が応答を返したときに実行されるデリゲート。

Register State Changed Callback

認証状態が変更された際に実行されるデリゲートにフックします。

宣言

UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")static void RegisterStateChangedCallback(FAuthenticationStateChangedResponseDelegate ResponseDelegate)

パラメーター

名前

説明

Response DelegateFAuthenticationStateChangedResponseDelegate認証状態が変更された際に実行されるデリゲート。

Sign Out

指定されたプロファイル名で現在のユーザーをサインアウトします。

宣言

UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")static bool SignOut(bool bClearCredentials = false)

パラメーター

名前

説明

Clear CredentialsBoolean同じアカウントへのログインを可能にするセッショントークンを消去するオプション。

Switch Profile

現在のプロファイルを新しいプロファイル名に切り替えます。その名前のプロファイルが見つからなかった場合は、新しいプロファイルが作成されます。

宣言

UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")void SwitchProfile(FString ProfileName)

パラメーター

名前

説明

Profile NameString切り替えるプロファイルの名前 (まだ存在しない場合は追加するプロファイルの名前)。

Profile Exists

プロファイルが存在するかどうかを確認します。

宣言

UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")bool ProfileExists(FString ProfileName) const

パラメーター

名前

説明

Profile NameString確認するプロファイルの名前。

Get Current Profile Name

現在のプロファイルの名前を返します。

宣言

UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")FString GetCurrentProfileName() const

戻り値

説明

String現在のプロファイルの名前。

Get Profile Names

すべてのアクティブなプレイヤープロファイルの名前を返します。

宣言

UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")TArray<FString> GetProfileNames() const

戻り値

説明

String の配列すべてのアクティブなプレイヤープロファイルの名前。

Register Profile Changed Callback

プレイヤープロファイルが変更された際に実行されるハンドラーにフックします。

宣言

UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")void RegisterProfileChangedCallback(FAuthenticationPlayerProfileChangedResponseDelegate ResponseDelegate)

パラメーター

名前

説明

Response DelegateFAuthenticationPlayerProfileChangedResponseDelegateプレイヤープロファイルが変更された際に実行されるハンドラー。

Register Profile Deleted Callback

プレイヤープロファイルが削除された際に実行されるハンドラーにフックします。

宣言

UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")void RegisterProfileDeletedCallback(FAuthenticationPlayerProfileDeletedResponseDelegate ResponseDelegate)

パラメーター

名前

説明

Response DelegateFAuthenticationPlayerProfileDeletedResponseDelegateプレイヤープロファイルが削除された際に実行されるハンドラー。

IsSignedIn

ユーザーがサインインしているかどうかを確認します。

宣言

UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")bool IsSignedIn() const

戻り値

説明

boolユーザーがサインインしている場合は true、それ以外の場合は false。

IsAnonymous

ユーザーが匿名でサインインしているかどうかを確認します。

宣言

UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")bool IsAnonymous() const

戻り値

説明

boolユーザーが匿名でサインインしている場合は true、それ以外の場合は false。

IsAuthorized

ユーザーがまだ認証されているかどうかを確認します。

宣言

UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")bool IsAuthorized() const

戻り値

説明

boolユーザーが認証されている場合は true、それ以外の場合は false。

IsExpired

ユーザーセッションが期限切れかどうかを確認します。

宣言

UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")bool IsExpired() const

戻り値

説明

boolユーザーのセッションが期限切れである場合は true、それ以外の場合は false。

SessionTokenExists

現在のプロファイル用に保存されているセッショントークンがあるかどうかを確認します。

宣言

UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")bool SessionTokenExists() const

戻り値

説明

bool現在のプロファイル用に保存されているセッショントークンがある場合は true。

GetUnityProjectId

Unity プロジェクト ID を返します。

宣言

UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")FGuid GetUnityProjectId() const

戻り値

説明

GuidUnity プロジェクト ID。

GetUnityEnvironmentName

Unity 環境名を返します。

宣言

UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")FString GetUnityEnvironmentName() const

戻り値

説明

StringUnity 環境名。

GetAccessToken

現在のユーザーのアクセストークンを返します。

宣言

UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")FString GetAccessToken() const

戻り値

説明

String現在のユーザーがサインインしている場合はそのアクセストークンの文字列。それ以外の場合は空の文字列。

GetSessionToken

現在のユーザーのセッショントークンを返します。

宣言

UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")FString GetSessionToken() const

戻り値

説明

String現在のユーザーがサインインしている場合はそのセッショントークンの文字列。それ以外の場合は空の文字列。

GetUserId

現在のユーザーがサインインしている場合は、そのユーザーの ID。

宣言

UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")FString GetUserId() const

戻り値

説明

String現在のユーザーがサインインしている場合はそのユーザーの ID。それ以外の場合は空の文字列。

GetState

認証サブシステムの現在の状態。

宣言

UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")EAuthenticationStates GetState() const

戻り値

説明

Authentication States認証サブシステムの現在の状態。

GetState

Unity プロジェクト ID を設定します。

宣言

UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")static void SetUnityProjectId(FGuid Value)

パラメーター

名前

説明

Guid新しい Unity プロジェクト ID。

SetUnityEnvironmentName

Unity 環境名を設定します。

宣言

UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")static void SetUnityEnvironmentName(FString Value)

パラメーター

名前

説明

String新しい Unity 環境 ID。