跳转到主要内容
PFAuthenticationServerLoginWithAndroidDeviceIDRequest 数据模型。在 Android 设备上,建议使用 Settings.Secure.ANDROID_ID 作为 AndroidDeviceId,如此博客文章 (http://android-developers.blogspot.com/2011/03/identifying-app-installations.html) 中所述。有关此标识符的更多信息,请参阅 Android 文档 (http://developer.android.com/reference/android/provider/Settings.Secure.html)。如果这是用户首次使用该 Android 设备登录且 CreateAccount 设为 true,将创建一个新的 PlayFab 帐户并链接到该 Android 设备 ID。在这种情况下,该 PlayFab 帐户将没有关联的电子邮件或用户名。否则,如果没有 PlayFab 帐户链接到该 Android 设备,将返回相应的错误,以便游戏引导用户创建 PlayFab 帐户。请注意,虽然可以将多个此类设备链接到单个用户帐户,但用户的帐户信息中只会反映最近用于登录(或最近链接)的设备。我们将在未来的版本中进行更新,以显示所有已链接的设备。

语法

成员

androidDevice   const char*
is null-terminated
(可选)用户设备的具体型号。 androidDeviceId   const char*
is null-terminated
用户设备的 Android 设备标识符。 createAccount   bool 如果当前没有 PlayFab 帐户链接到此 ID,则自动创建一个。 customTags   PFStringDictionaryEntry const*
may be nullptr
(可选)与请求关联的可选自定义标记(例如生成号、外部跟踪标识符等)。 customTagsCount   uint32_t customTags 的数量 infoRequestParameters   PFGetPlayerCombinedInfoRequestParams const*
may be nullptr
(可选)用于指定要为用户返回哪些信息的标志。 OS   const char*
is null-terminated
(可选)用户设备的具体操作系统版本。

要求

头文件: PFAuthenticationTypes.h

另请参阅

PFAuthenticationTypes 成员
最后修改于 2026年10月6日