Game Center not authenticating using Swift

后端 未结 3 532
轻奢々
轻奢々 2020-12-06 03:09

I\'m trying to authenticate the local player using swift, but every time I get a false value for the .authenticated property. Here is the code I\'m using, it is called by th

3条回答
  •  挽巷
    挽巷 (楼主)
    2020-12-06 04:00

    Even with Xcode 6 Beta 6, on a device using iOS 8 beta 5, making GKLocalPlayer.localPlayer() available, I was still getting the error:

    "NSLocalizedDescription=The requested operation could not be completed because this application is not recognized by Game Centre"

    The solution (discovered through Apple's Dev forum) was to go to "Settings" on the device, and then into "Game Centre" and enable "Sandbox" under the developer section.

提交回复
热议问题