How to solve issues in libGDX at iOS version uploading to iTunes Connect

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 are showed because the file Info.plist.xml 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.

My game runs on iPhone and iPad using landscape orientation. In other cases, the configuration and needed resources can be slightly different.

Info.plist.xml

Next I show the original Info.plist.xml file and the modified version in order you can see the differences.

Original file (it fails)

The original file that don’t allow me to upload the app is like this one:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>CFBundleDevelopmentRegion</key>
    <string>en</string>
    <key>CFBundleDisplayName</key>
    <string>${app.name}</string>
    <key>CFBundleExecutable</key>
    <string>${app.executable}</string>
    <key>CFBundleIdentifier</key>
    <string>${app.id}</string>
    <key>CFBundleInfoDictionaryVersion</key>
    <string>6.0</string>
    <key>CFBundleName</key>
    <string>${app.name}</string>
    <key>CFBundlePackageType</key>
    <string>APPL</string>
    <key>CFBundleShortVersionString</key>
    <string>${app.version}</string>
    <key>CFBundleSignature</key>
    <string>????</string>
    <key>CFBundleVersion</key>
    <string>${app.build}</string>
    <key>LSRequiresIPhoneOS</key>
    <true/>
    <key>UIViewControllerBasedStatusBarAppearance</key>
    <false/>
    <key>UIStatusBarHidden</key>
    <true/>
    <key>UIDeviceFamily</key>
    <array>
        <integer>1</integer>
        <integer>2</integer>
    </array>
    <key>UIRequiredDeviceCapabilities</key>
    <array>
        <string>armv7</string>
        <string>opengles-2</string>
    </array>
    <key>UISupportedInterfaceOrientations</key>
    <array>
        <string>UIInterfaceOrientationPortrait</string>
        <string>UIInterfaceOrientationLandscapeLeft</string>
        <string>UIInterfaceOrientationLandscapeRight</string>
    </array>
    <key>CFBundleIcons</key>
    <dict>
        <key>CFBundlePrimaryIcon</key>
        <dict>
            <key>CFBundleIconFiles</key>
            <array>
                <string>Icon</string>
                <string>Icon-72</string>
            </array>
        </dict>
    </dict>
</dict>
</plist>

Modified file

This version of the file allows us to upload and distribute the app for iPhone and iPad.

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>CFBundleDevelopmentRegion</key>
    <string>en</string>
    <key>CFBundleDisplayName</key>
    <string>${app.name}</string>
    <key>CFBundleExecutable</key>
    <string>${app.executable}</string>
    <key>CFBundleIconFile</key>
    <string>Icon-57.png</string>
    <key>CFBundleIconFiles</key>
    <array>
        <string>Icon-29</string>
        <string>Icon-40</string>
        <string>Icon-50</string>
        <string>Icon-57</string>
        <string>Icon-58</string>
        <string>Icon-72</string>
        <string>Icon-76</string>
        <string>Icon-80</string>
        <string>Icon-87</string>
        <string>Icon-100</string>
        <string>Icon-114</string>
        <string>Icon-120</string>
        <string>Icon-144</string>
        <string>Icon-152</string>
        <string>Icon-180</string>
    </array>
    <key>CFBundleIconFiles~ipad</key>
    <array>
        <string>Icon-29</string>
        <string>Icon-40</string>
        <string>Icon-50</string>
        <string>Icon-57</string>
        <string>Icon-58</string>
        <string>Icon-72</string>
        <string>Icon-76</string>
        <string>Icon-80</string>
        <string>Icon-87</string>
        <string>Icon-100</string>
        <string>Icon-114</string>
        <string>Icon-120</string>
        <string>Icon-144</string>
        <string>Icon-152</string>
        <string>Icon-180</string>
    </array>
    <key>CFBundleIdentifier</key>
    <string>${app.id}</string>
    <key>CFBundleInfoDictionaryVersion</key>
    <string>6.0</string>
    <key>CFBundleName</key>
    <string>${app.name}</string>
    <key>CFBundlePackageType</key>
    <string>APPL</string>
    <key>CFBundleShortVersionString</key>
    <string>${app.version}</string>
    <key>CFBundleSignature</key>
    <string>????</string>
    <key>CFBundleVersion</key>
    <string>${app.build}</string>
    <key>LSRequiresIPhoneOS</key>
    <true/>
    <key>UIViewControllerBasedStatusBarAppearance</key>
    <false/>
    <key>UIStatusBarHidden</key>
    <true/>
    <key>UIDeviceFamily</key>
    <array>
        <integer>1</integer>
        <integer>2</integer>
    </array>
    <key>UIRequiredDeviceCapabilities</key>
    <array>
        <string>armv7</string>
        <string>opengles-2</string>
    </array>
    <key>UIRequiresFullScreen</key>
    <true/>
    <key>UISupportedInterfaceOrientations</key>
    <array>
        <string>UIInterfaceOrientationLandscapeLeft</string>
        <string>UIInterfaceOrientationLandscapeRight</string>
    </array>
    <key>MinimumOSVersion</key>
    <string>7.1.2</string>
</dict>
</plist>

New resources

It’s necessary to include new icons and launch images for all supported devices.

Icons

Now are declared new icons with different dimensions, so it’s necessary to add them to the data/ directory of the ios project module.

File name Dimensions
Icon-29.png 29×29 pixels
Icon-40.png 40×40 pixels
Icon-50.png 50×50 pixels
Icon-57.png 57×57 pixels
Icon-58.png 58×58 pixels
Icon-72.png 72×72 pixels
Icon-76.png 76×76 pixels
Icon-80.png 80×80 pixels
Icon-87.png 87×87 pixels
Icon-100.png 100×100 pixels
Icon-114.png 114×114 pixels
Icon-120.png 120×120 pixels
Icon-144.png 144×144 pixels
Icon-152.png 152×152 pixels
Icon-180.png 180×180 pixels

Launch screens

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:

File name Dimensions
Default.png 320×480 pixels
Default@2x.png 640×960 pixels
Default~ipad.png 768×1004 pixels
Default@2x~ipad.png 1536×2008 pixels
Default-Landscape~ipad.png 1024×768 pixels
Default-1024w-1366h@2x~ipad.png 2048×2732 pixels

 

To know more

You can check all information about the Info.plist file on the Apple documentation site.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

*