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)
パラメーター
Get User Info
現在のプレイヤーの情報を返します (アカウント作成日時やリンクされた外部 ID など)。
宣言
UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")void GetUserInfo(FAuthenticationGetUserDelegate ResponseDelegate) const
パラメーター
Delete User
現在サインインしているユーザーを完全に削除します。
宣言
UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")static void DeleteUser(FAuthenticationDeleteUserDelegate ResponseDelegate)
パラメーター
Register State Changed Callback
認証状態が変更された際に実行されるデリゲートにフックします。
宣言
UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")static void RegisterStateChangedCallback(FAuthenticationStateChangedResponseDelegate ResponseDelegate)
パラメーター
Sign Out
指定されたプロファイル名で現在のユーザーをサインアウトします。
宣言
UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")static bool SignOut(bool bClearCredentials = false)
パラメーター
名前 | 型 | 説明 |
|---|
| Clear Credentials | Boolean | 同じアカウントへのログインを可能にするセッショントークンを消去するオプション。 |
Switch Profile
現在のプロファイルを新しいプロファイル名に切り替えます。その名前のプロファイルが見つからなかった場合は、新しいプロファイルが作成されます。
宣言
UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")void SwitchProfile(FString ProfileName)
パラメーター
名前 | 型 | 説明 |
|---|
| Profile Name | String | 切り替えるプロファイルの名前 (まだ存在しない場合は追加するプロファイルの名前)。 |
Profile Exists
プロファイルが存在するかどうかを確認します。
宣言
UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")bool ProfileExists(FString ProfileName) const
パラメーター
名前 | 型 | 説明 |
|---|
| Profile Name | String | 確認するプロファイルの名前。 |
Get Current Profile Name
現在のプロファイルの名前を返します。
宣言
UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")FString GetCurrentProfileName() const
戻り値
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)
パラメーター
Register Profile Deleted Callback
プレイヤープロファイルが削除された際に実行されるハンドラーにフックします。
宣言
UFUNCTION(BlueprintCallable, Category = "Unity Gaming Services | Authentication")void RegisterProfileDeletedCallback(FAuthenticationPlayerProfileDeletedResponseDelegate ResponseDelegate)
パラメーター
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
戻り値
GetUnityEnvironmentName
Unity 環境名を返します。
宣言
UFUNCTION(BlueprintPure, Category = "Unity Gaming Services | Authentication")FString GetUnityEnvironmentName() const
戻り値
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
戻り値
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)
パラメーター