UDN
Search public documentation:

UnrealOniOS
日本語訳
中国翻译
한국어

Interested in the Unreal Engine?
Visit the Unreal Technology site.

Looking for jobs and company info?
Check out the Epic games site.

Questions about support via UDN?
Contact the UDN Staff

UE3 Home > Mobile Home > Unreal Engine 3: Mobile Overview > Unreal Engine 3: Apple iOS Overview

Unreal Engine 3: Apple iOS Overview


Overview


Developing games for Apple's iOS platform using Unreal Engine 3 is similar in many ways to developing on other mobile platforms. The platform does have some of its own features and considerations that must be addressed, however. This document provides a general overview of developing games for iOS devices using Unreal Engine 3.

Getting Started


Developing games for iOS devices using Unreal Engine 3 comes with special requirements, workflow, and considerations that must be taken into account, such as setting up your development environment for building games for iOS devices, as well as general workflows for testing, packaging, and deploying an Unreal project that runs on iOS devices.

See the Getting Started: iOS Development page for complete details to get up and running creating games for iOS devices.

Gamma Correction


As of June 2011

Gamma correction is supported on iOS devices allowing the creation of levels and content with consistent lighting across platforms.

mobile_gamma_results.jpg

To Enable Gamma Correction

Gamma correction on mobile platforms is not enabled by default. To make use of gamma correction for mobile games, enable the Use Gamma Correction property in the World Properties for your map(s).

gamma_enabled.jpg

Performance Considerations

Gamma correction on mobile devices can cause a fairly noticeable impact on performance. It is mainly meant as a feature for use on future mobile devices. Currently, iPad 2 is the only device that is really capable of running games using gamma correction.

VGA output


The engine has basic VGA output support, using the VGA Dock Adapter. It will display the 3D viewport over VGA, with the following considerations:

  • You must run the game with -vga on the commandline
  • You must have the VGA connector connected before the game starts up
  • It queries the VGA device for supported resolutions, and chooses the highest resolution whose width is no more than 1024 (which is used to generally match the iPad resolution of 1024x768)
  • Loading screens/movies will usually look incorrect
  • Touch input is done on the device, in the solid pink area. However, there is currently no remapping of the input locations, so if the resolution is chosen to be 640x480, you would need to use the upper left 640x480 area of the pink area.

Commandline settings via iOS Settings app


The engine has support for modifying the game's commandline via switches and strings in the external Settings app in iOS (this is the standard Settings place you would go to set up WiFi, sounds, Airplane mode, etc). The settings are specified in a file called Root.plist in the Settings.bundle directory:

   //depot/UnrealEngine3/UDKGame/Build/IPhone/Resources/Settings/Settings.bundle/Root.plist
   //depot/UnrealEngine3/UDKGame/Build/IPhone/Resources/Settings/Distro_Settings.bundle/Root.plist

Here is what you can see in Settings:

SettingsOuter.png SettingsInner.png

Generally, these settings are used for debugging, and you wouldn't want to ship a game with them. The Distro_Settings.bundle will be used when making a Distribution build (the shipping one). If you don't want anything to show up in Settings app, simply delete the Distro_Settings.bundle directory. It will not fall back to Settings.bundle when making the Distribution build, it will only use Distro_Settings.bundle.

The format for the Root.plist file is documented, but there for UE3 commandlines, you need to know how to specify what is put on the commandline. Here are two example settings we use:

  <dict>
    <key>Type</key>
    <string>PSToggleSwitchSpecifier</string>
    <key>Title</key>
    <string>Benchmarking?</string>
    <key>Key</key>
    <string>-benchmark</string>
    <key>DefaultValue</key>
    <false/>
  </dict>
  <dict>
    <key>Type</key>
    <string>PSTextFieldSpecifier</string>
    <key>Title</key>
    <string>Benchmark seconds</string>
    <key>Key</key>
    <string>-benchmarkseconds=</string>
    <key>KeyboardType</key>
    <string>NumberPad</string>
  </dict>

There are many things to set, each being two lines, on first line, and then the second line is dependent on the key. Breaking them down, we have:

  • Type - This is the setting type. PSToggleSwitchSpecifier is an On/Off switch, PSTextFieldSpecifier is a text box.
  • Title - This is what is displayed to the user (if it's too long, TextFields will have little room to display the text)
  • Key - This is the critical information. This is what is put directly onto the commandline. It must start with - or ?. For Toggles, the Key will be put onto the commandline if the Toggle is set on On. For TextFields, the Key will be put onto the commandline if the text is not empty, then followed by the text entered by the user.
  • DefaultValue - You can set what to initialize the setting's value to whatever you want.
  • KeyboardType - What type of keyboard to use. See the docs for more information about TextFields.

You should also be able to use Slider and MultiValue types, although we have not tested them. The code will simply get the string value of the setting, no matter what the type of setting. See main.mm for the code that process this.

Non-commandline uses of Settings app


You can also expose the same settings as described here in the Settings.bundle. If you make a new group with a PSGroupSpecifier, then make more settings with Keys that don't begin with - or ?, then you can use the "mobile LoadSetting " console command to get the value (using the case-sensitive Key specified in the Root.plist file).

Version string


Version.png

When UnrealFrontend packages up the iOS application bundle, it adds a key/value pair for the version of the engine and build date for the iOS executable. The key is called EpicAppVersion. This value is displayed in non-Shipping builds. You can however, force this display on or off via the Engine.ini file, as seen in UDKGame's Config\Mobile\MobileEngine.ini:

[Build.Version]
bForceShowAppVersion=False
bForceHideAppVersion=False

Game Center


Unreal Engine 3 on iOS has support for multiplayer and achievements through Game Center. See the Game Center documentation for information on how to set up and use these features.

iAds


Support for displaying in-game ads through Apple's iAd network is provided in Unreal Engine 3 on iOS platforms. See the In-Game Ads page for details on how to use ads in your game.