涉及步骤
步骤 1 − 在 iTunes 连接中,确保您有一个 unique App ID 当我们创建应用程序更新时 bundle ID 并使用相应的配置文件在 Xcode 中进行代码签名。
步骤 2− 创建新应用程序并更新应用程序信息。您可以在 apple-add new apps 文档中了解更多相关信息。
步骤 3 − 设置排行榜 Manage Game Center 在您的应用程序页面中添加一个排行榜并给出 leaderboard ID和分数类型。这里我们将排行榜 ID 作为 tutorialsPoint。
步骤 4 - 接下来的步骤与处理代码和为我们的应用程序创建 UI 相关。
步骤 5 − 创建一个 single view application 并输入 bundle identifier 是指定的标识符 iTunes connect.
步骤 6 - 更新 ViewController.xib 如下所示 -
步骤 7 − 选择您的项目文件,然后选择 targets 然后添加 GameKit.framework.
步骤 8 − 创建 IBActions 对于我们添加的按钮。
步骤 9 − 更新 ViewController.h 文件如下 -
步骤 10 − 更新 ViewController.m 如下 -