Does using GameKit / Game Center in your app increase its binary size?
I'm looking to implement Game C开发者_JAVA技巧enter features into my iOS app; however, I'm not sure how much it will increase my application's binary filesize. There seem to be a lot of features in GameKit which I won't be using because I only want to use achievements and leaderboards. Is there a way to leave out the unused features at compile time?
Thanks in advance!
The actual code for frameworks is not copied into your program. The linker builds symbolic links into your executable code that enables it to find the frameworks on the deployment platform (iPhone, iPad, etc) at runtime.
The only increase in your program size will come from code you actually write to use the GameKit (for example your leaderboard or P2P code).
Linking to iOS frameworks does not increase the size of your binary by any substantial amount. Those frameworks are all already on the device, as part of the operating system, so applications which link to them don't include the library in the app itself, they just load it from the shared location on the device.
精彩评论