User Tools

Site Tools


proton:ios_setup

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
proton:ios_setup [2010/10/27 09:43] – created sethproton:ios_setup [2012/07/03 04:03] (current) seth
Line 1: Line 1:
 +==== First things first ====
 +If you haven't already, you should read the [[proton:win_setup|Windows compile instructions]] to get up to speed.
 +
 ==== Compiling RTBareBones for iOS ==== ==== Compiling RTBareBones for iOS ====
  
-Easy.  Open Finder, navigate to the RTBareBones directory and double click RTBareBones.xcodeproj.+Easy.  Open Finder, navigate to the **RTBareBones** directory and open **RTBareBones.xcodeproj**.
  
 The project will open in Xcode.  It should compile and run out of the box. The project will open in Xcode.  It should compile and run out of the box.
Line 13: Line 16:
 To test on a real device and actually publish in the AppStore: To test on a real device and actually publish in the AppStore:
  
-  * Join the [[http://developer.apple.com/programs/ios/|iOS developer program for $99]]+  * Join the [[http://developer.apple.com/programs/ios/|Apple iOS developer program for $99]]
   * Setup security certificates and bunch of junk, there are tutorials out there on how to set it up, it's not that difficult these days   * Setup security certificates and bunch of junk, there are tutorials out there on how to set it up, it's not that difficult these days
   * Submit your app and wait like 10 days before it's rejected because you broke one of the many rules.  I'm just saying they're picky, maybe that's a good thing.   * Submit your app and wait like 10 days before it's rejected because you broke one of the many rules.  I'm just saying they're picky, maybe that's a good thing.
Line 19: Line 22:
 ==== Compiling RTSimpleApp ===== ==== Compiling RTSimpleApp =====
 It's the same as above except you'll also need to build the media directory first, check the [[http://www.rtsoft.com/wiki/doku.php?id=proton:win_setup2|Building Resources]] section of the Windows setup for that. It's the same as above except you'll also need to build the media directory first, check the [[http://www.rtsoft.com/wiki/doku.php?id=proton:win_setup2|Building Resources]] section of the Windows setup for that.
 +
 +==== Design notes =====
 +If you check the **RTBareBones's** source folder you may scratch your head.  There is no iOS specific code at all, only App.cpp.  Where is all this Objective-C glue code I thought iOS needed?!
 +
 +It's shared between all apps in **/shared/iOS/app**.  It's about six files.
 +
 +If I add a feature, all my apps get the benefit.
 +
 +If for some reason you need more control of the Objective-C side, you could just copy them into your app level folder and use those customized versions instead.
 +
 +==== Resources, network drives =====
 +
 +The way I do my iOS builds is I share my Windows HD drive to OS X, and open the Xcode project on the network drive.  The projects are setup to use local drives for the intermediate compile-build processes so performance is good. (Update - actually I don't, due to some problem between xcode, lion's new samba replacement, and Win7.  I've been using robocopy in .bat files instead... sucks.
 + 
 +Under "Resources" in the groups and files tree in the Xcode project, you'll see little blue folders named "game", "audio", "interface" These are virtual folders that will automatically copy ALL their contents (bmps, wavs, etc) into the final package.
 +
 +You don't have to edit the project file when you change/update resources, it's more or less automatic.
 +
 +==== Switching from a "combo app" to iPhone only =====
 +The examples are all "combo apps" which mean they run on each device at its native resolution.  If for some reason you'd like an iPhone only app (it can still be run on an iPad, but in the iPhone emulation mode) then do this:
 +
 +  - In the XCode project build settings, set "Targeted Device Family" to "iPhone" instead of "iPhone/iPad"
 +  - Edit the Info.plist with a text editor and remove the lines <key>NSMainNibFile~ipad</key> and <string>MainWindow-iPad</string>
 +  - Remove the Resources-iPad folder from the project, you don't need the MainWindow-iPad.xib
 +  - Do a full rebuild, you're done!
proton/ios_setup.txt · Last modified: 2012/07/03 04:03 by seth