{"id":668,"date":"2017-09-10T13:35:50","date_gmt":"2017-09-10T12:35:50","guid":{"rendered":"http:\/\/www.pixnbgames.com\/blog\/?p=668"},"modified":"2017-11-27T19:42:08","modified_gmt":"2017-11-27T18:42:08","slug":"how-to-solve-issues-in-libgdx-at-ios-version-uploading-to-itunes-connect","status":"publish","type":"post","link":"https:\/\/www.pixnbgames.com\/blog\/libgdx\/how-to-solve-issues-in-libgdx-at-ios-version-uploading-to-itunes-connect\/","title":{"rendered":"How to solve issues in libGDX at iOS version uploading to iTunes Connect"},"content":{"rendered":"<p>I have recently published my new game for iOS, made with libGDX: <a href=\"http:\/\/www.pixnbgames.com\/rainbowd.html\" target=\"_blank\" rel=\"noopener\">Rainbow Diamonds<\/a>.<\/p>\n<p>Once the app is packaged to distribute for iOS devices, I found some errors when I tried to upload the app to iTunes Connect. This issues are showed because the file <em>Info.plist.xml<\/em> generated at project creation with libGDX does not contain all necessary information to distribute the game on the App Store. Furthermore, there are some resources we must include to full support iPhone and iPad devices.<\/p>\n<p><i>My game runs on iPhone and iPad using landscape orientation. In other cases, the configuration and needed resources can be slightly different.<\/i><\/p>\n<h3>Info.plist.xml<\/h3>\n<p>Next I show the original <i>Info.plist.xml<\/i> file and the modified version in order you can see the differences.<\/p>\n<h4>Original file (it fails)<\/h4>\n<p>The original file that don&#8217;t allow me to upload the app is like this one:<\/p>\n<pre lang=\"Xml\"><?xml version=\"1.0\" encoding=\"UTF-8\"?>\r\n<!DOCTYPE plist PUBLIC \"-\/\/Apple\/\/DTD PLIST 1.0\/\/EN\" \"http:\/\/www.apple.com\/DTDs\/PropertyList-1.0.dtd\">\r\n<plist version=\"1.0\">\r\n<dict>\r\n    <key>CFBundleDevelopmentRegion<\/key>\r\n    <string>en<\/string>\r\n    <key>CFBundleDisplayName<\/key>\r\n    <string>${app.name}<\/string>\r\n    <key>CFBundleExecutable<\/key>\r\n    <string>${app.executable}<\/string>\r\n    <key>CFBundleIdentifier<\/key>\r\n    <string>${app.id}<\/string>\r\n    <key>CFBundleInfoDictionaryVersion<\/key>\r\n    <string>6.0<\/string>\r\n    <key>CFBundleName<\/key>\r\n    <string>${app.name}<\/string>\r\n    <key>CFBundlePackageType<\/key>\r\n    <string>APPL<\/string>\r\n    <key>CFBundleShortVersionString<\/key>\r\n    <string>${app.version}<\/string>\r\n    <key>CFBundleSignature<\/key>\r\n    <string>????<\/string>\r\n    <key>CFBundleVersion<\/key>\r\n    <string>${app.build}<\/string>\r\n    <key>LSRequiresIPhoneOS<\/key>\r\n    <true\/>\r\n    <key>UIViewControllerBasedStatusBarAppearance<\/key>\r\n    <false\/>\r\n    <key>UIStatusBarHidden<\/key>\r\n    <true\/>\r\n    <key>UIDeviceFamily<\/key>\r\n    <array>\r\n        <integer>1<\/integer>\r\n        <integer>2<\/integer>\r\n    <\/array>\r\n    <key>UIRequiredDeviceCapabilities<\/key>\r\n    <array>\r\n        <string>armv7<\/string>\r\n        <string>opengles-2<\/string>\r\n    <\/array>\r\n    <key>UISupportedInterfaceOrientations<\/key>\r\n    <array>\r\n        <string>UIInterfaceOrientationPortrait<\/string>\r\n        <string>UIInterfaceOrientationLandscapeLeft<\/string>\r\n        <string>UIInterfaceOrientationLandscapeRight<\/string>\r\n    <\/array>\r\n    <key>CFBundleIcons<\/key>\r\n    <dict>\r\n        <key>CFBundlePrimaryIcon<\/key>\r\n        <dict>\r\n            <key>CFBundleIconFiles<\/key>\r\n            <array>\r\n                <string>Icon<\/string>\r\n                <string>Icon-72<\/string>\r\n            <\/array>\r\n        <\/dict>\r\n    <\/dict>\r\n<\/dict>\r\n<\/plist>\r\n\r\n<\/pre>\n<h4>Modified file<\/h4>\n<p>This version of the file allows us to upload and distribute the app for iPhone and iPad.<\/p>\n<pre lang=\"Xml\"><?xml version=\"1.0\" encoding=\"UTF-8\"?>\r\n<!DOCTYPE plist PUBLIC \"-\/\/Apple\/\/DTD PLIST 1.0\/\/EN\" \"http:\/\/www.apple.com\/DTDs\/PropertyList-1.0.dtd\">\r\n<plist version=\"1.0\">\r\n<dict>\r\n    <key>CFBundleDevelopmentRegion<\/key>\r\n    <string>en<\/string>\r\n    <key>CFBundleDisplayName<\/key>\r\n    <string>${app.name}<\/string>\r\n    <key>CFBundleExecutable<\/key>\r\n    <string>${app.executable}<\/string>\r\n    <key>CFBundleIconFile<\/key>\r\n    <string>Icon-57.png<\/string>\r\n    <key>CFBundleIconFiles<\/key>\r\n    <array>\r\n        <string>Icon-29<\/string>\r\n        <string>Icon-40<\/string>\r\n        <string>Icon-50<\/string>\r\n        <string>Icon-57<\/string>\r\n        <string>Icon-58<\/string>\r\n        <string>Icon-72<\/string>\r\n        <string>Icon-76<\/string>\r\n        <string>Icon-80<\/string>\r\n        <string>Icon-87<\/string>\r\n        <string>Icon-100<\/string>\r\n        <string>Icon-114<\/string>\r\n        <string>Icon-120<\/string>\r\n        <string>Icon-144<\/string>\r\n        <string>Icon-152<\/string>\r\n        <string>Icon-180<\/string>\r\n    <\/array>\r\n    <key>CFBundleIconFiles~ipad<\/key>\r\n    <array>\r\n        <string>Icon-29<\/string>\r\n        <string>Icon-40<\/string>\r\n        <string>Icon-50<\/string>\r\n        <string>Icon-57<\/string>\r\n        <string>Icon-58<\/string>\r\n        <string>Icon-72<\/string>\r\n        <string>Icon-76<\/string>\r\n        <string>Icon-80<\/string>\r\n        <string>Icon-87<\/string>\r\n        <string>Icon-100<\/string>\r\n        <string>Icon-114<\/string>\r\n        <string>Icon-120<\/string>\r\n        <string>Icon-144<\/string>\r\n        <string>Icon-152<\/string>\r\n        <string>Icon-180<\/string>\r\n    <\/array>\r\n    <key>CFBundleIdentifier<\/key>\r\n    <string>${app.id}<\/string>\r\n    <key>CFBundleInfoDictionaryVersion<\/key>\r\n    <string>6.0<\/string>\r\n    <key>CFBundleName<\/key>\r\n    <string>${app.name}<\/string>\r\n    <key>CFBundlePackageType<\/key>\r\n    <string>APPL<\/string>\r\n    <key>CFBundleShortVersionString<\/key>\r\n    <string>${app.version}<\/string>\r\n    <key>CFBundleSignature<\/key>\r\n    <string>????<\/string>\r\n    <key>CFBundleVersion<\/key>\r\n    <string>${app.build}<\/string>\r\n    <key>LSRequiresIPhoneOS<\/key>\r\n    <true\/>\r\n    <key>UIViewControllerBasedStatusBarAppearance<\/key>\r\n    <false\/>\r\n    <key>UIStatusBarHidden<\/key>\r\n    <true\/>\r\n    <key>UIDeviceFamily<\/key>\r\n    <array>\r\n        <integer>1<\/integer>\r\n        <integer>2<\/integer>\r\n    <\/array>\r\n    <key>UIRequiredDeviceCapabilities<\/key>\r\n    <array>\r\n        <string>armv7<\/string>\r\n        <string>opengles-2<\/string>\r\n    <\/array>\r\n    <key>UIRequiresFullScreen<\/key>\r\n    <true\/>\r\n    <key>UISupportedInterfaceOrientations<\/key>\r\n    <array>\r\n        <string>UIInterfaceOrientationLandscapeLeft<\/string>\r\n        <string>UIInterfaceOrientationLandscapeRight<\/string>\r\n    <\/array>\r\n    <key>MinimumOSVersion<\/key>\r\n    <string>7.1.2<\/string>\r\n<\/dict>\r\n<\/plist>\r\n<\/pre>\n<h3>New resources<\/h3>\n<p>It&#8217;s necessary to include new icons and launch images for all supported devices.<\/p>\n<h4>Icons<\/h4>\n<p>Now are declared new icons with different dimensions, so it&#8217;s necessary to add them to the <em>data\/<\/em> directory of the <em>ios<\/em> project module.<\/p>\n<table>\n<thead>\n<tr>\n<th>File name<\/th>\n<th>Dimensions<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>Icon-29.png<\/td>\n<td>29&#215;29 pixels<\/td>\n<\/tr>\n<tr>\n<td>Icon-40.png<\/td>\n<td>40&#215;40 pixels<\/td>\n<\/tr>\n<tr>\n<td>Icon-50.png<\/td>\n<td>50&#215;50 pixels<\/td>\n<\/tr>\n<tr>\n<td>Icon-57.png<\/td>\n<td>57&#215;57 pixels<\/td>\n<\/tr>\n<tr>\n<td>Icon-58.png<\/td>\n<td>58&#215;58 pixels<\/td>\n<\/tr>\n<tr>\n<td>Icon-72.png<\/td>\n<td>72&#215;72 pixels<\/td>\n<\/tr>\n<tr>\n<td>Icon-76.png<\/td>\n<td>76&#215;76 pixels<\/td>\n<\/tr>\n<tr>\n<td>Icon-80.png<\/td>\n<td>80&#215;80 pixels<\/td>\n<\/tr>\n<tr>\n<td>Icon-87.png<\/td>\n<td>87&#215;87 pixels<\/td>\n<\/tr>\n<tr>\n<td>Icon-100.png<\/td>\n<td>100&#215;100 pixels<\/td>\n<\/tr>\n<tr>\n<td>Icon-114.png<\/td>\n<td>114&#215;114 pixels<\/td>\n<\/tr>\n<tr>\n<td>Icon-120.png<\/td>\n<td>120&#215;120 pixels<\/td>\n<\/tr>\n<tr>\n<td>Icon-144.png<\/td>\n<td>144&#215;144 pixels<\/td>\n<\/tr>\n<tr>\n<td>Icon-152.png<\/td>\n<td>152&#215;152 pixels<\/td>\n<\/tr>\n<tr>\n<td>Icon-180.png<\/td>\n<td>180&#215;180 pixels<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Launch screens<\/h4>\n<p>The launch screens are the first image which is shown to the user on iOS while the app is loading. According to the supported devices and orientations, our app must include launch screens of different sizes. In my case, the app contains the following ones:<\/p>\n<table>\n<thead>\n<tr>\n<th>File name<\/th>\n<th>Dimensions<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td>Default.png<\/td>\n<td>320&#215;480 pixels<\/td>\n<\/tr>\n<tr>\n<td>Default@2x.png<\/td>\n<td>640&#215;960 pixels<\/td>\n<\/tr>\n<tr>\n<td>Default~ipad.png<\/td>\n<td>768&#215;1004 pixels<\/td>\n<\/tr>\n<tr>\n<td>Default@2x~ipad.png<\/td>\n<td>1536&#215;2008 pixels<\/td>\n<\/tr>\n<tr>\n<td>Default-Landscape~ipad.png<\/td>\n<td>1024&#215;768 pixels<\/td>\n<\/tr>\n<tr>\n<td>Default-1024w-1366h@2x~ipad.png<\/td>\n<td>2048&#215;2732 pixels<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>&nbsp;<\/p>\n<h3>To know more<\/h3>\n<p>You can check all information about the <em>Info.plist<\/em> file on the <a href=\"https:\/\/developer.apple.com\/library\/content\/documentation\/General\/Reference\/InfoPlistKeyReference\/Introduction\/Introduction.html\" target=\"_blank\" rel=\"noopener\">Apple documentation site<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I have recently published my new game for iOS, made with libGDX: Rainbow Diamonds. Once the app is packaged to distribute for iOS devices, I found some errors when I tried to upload the app to iTunes Connect. This issues <a class=\"more-link\" href=\"https:\/\/www.pixnbgames.com\/blog\/libgdx\/how-to-solve-issues-in-libgdx-at-ios-version-uploading-to-itunes-connect\/\">Seguir leyendo <span class=\"screen-reader-text\">  How to solve issues in libGDX at iOS version uploading to iTunes Connect<\/span><span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[14],"tags":[51,15],"language":[4],"_links":{"self":[{"href":"https:\/\/www.pixnbgames.com\/blog\/wp-json\/wp\/v2\/posts\/668"}],"collection":[{"href":"https:\/\/www.pixnbgames.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.pixnbgames.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.pixnbgames.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.pixnbgames.com\/blog\/wp-json\/wp\/v2\/comments?post=668"}],"version-history":[{"count":3,"href":"https:\/\/www.pixnbgames.com\/blog\/wp-json\/wp\/v2\/posts\/668\/revisions"}],"predecessor-version":[{"id":671,"href":"https:\/\/www.pixnbgames.com\/blog\/wp-json\/wp\/v2\/posts\/668\/revisions\/671"}],"wp:attachment":[{"href":"https:\/\/www.pixnbgames.com\/blog\/wp-json\/wp\/v2\/media?parent=668"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.pixnbgames.com\/blog\/wp-json\/wp\/v2\/categories?post=668"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.pixnbgames.com\/blog\/wp-json\/wp\/v2\/tags?post=668"},{"taxonomy":"language","embeddable":true,"href":"https:\/\/www.pixnbgames.com\/blog\/wp-json\/wp\/v2\/language?post=668"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}