Weird GKGamePlatform error

I have a Mac OSX app that I am doing an update to - part of which is to add a new leaderboard & a few new achievements. The app already has a leaderboard & achievements in the current release that is on the Mac App Store. I've been having issues getting the app to see the new leaderboard & achievements & can't see them at all when I open the Game Center dialog. All I see are the existing leaderboard & acheivements. This has been ongoing for about 4 days now.


Today I noticed an error message:


[Error] No platform string for specified GKGamePlatform value (0), defaulting to iOS.


every time my code tries to unlock an achievement (either an existing one or a new one). I searched Google, the GameKit documentation & this forum but couldn't find anything that mentions GKGamePlatform - so I'm at a bit of a loss to know what this is about & I'm not sure if it's related to my issue or not. I'm using Xcode 11.2.


Has anyone else ever seen this error?


UPDATE: I have searched through the GameKit framework headers & not found any reference to GKGamePlatform there either.


- Colin.

Have you searched where you use GKGamePlatform ? Or do you use third party library that would use it.

Effectively, I could not find it in the doc.


You'd better move this thread to the Game / Game Controller section.


Good luck.

Thanks for your reply. There is no reference to GKGamePlatform in my project & I'm not using any 3rd party libraries, so I can only assume that it's buried somewhere in GameKit - but as you say, there is no documentation anywhere that I can find.


- Colin.

Running any code like this?

func devicePlatformString() -> String {
  let platform: String = devicePlatform()
  if (platform == "xyz") {
  return "Abc"
  }
Colin,

Were you able to find a solution for this issue?

Thank you.
  • Josh

Hi Colin,

I am seeing this as well when reporting achievements. Appears that the call is working because my achievements still go through and appear as expected, but anytime I see an error I feel the need to resolve it or at least understand why it's happening. Any update here?
  • Luca

Weird GKGamePlatform error
 
 
Q