NOTE: This post is definitely in the Notes to Self category. Not sure how useful this may be to anyone I’m not directly working with.
Apple Developer Center
There are plenty of free tutorials on how to do this but here’re the steps:
1. [First time only] Set up Apple Developer Account & Create your personal Certificate in .p12 format.
2. Create an App ID
3. add Device IDs if needed
4. Create Dev Provisioning Profile & download it to your machine.
Set Up Unity Project for iOS
- Create a New Project & go to File > Build Settings > Player Settings
- Fill in Company Name & Product Name (the app name you picked in Apple Dev Center when setting up the App ID).
- In Player Settings, under Per-Platform Settings in Other Settings set Bundle Identifier* to the App ID you created in the Apple Developer Center (something like “com.yourcompany.yourAppName”)
- Other Player Settings seem fairly self-explanatory if you’ve done iOS dev before
Import Your Assets, Copy/Paste Items
- Imported your team mate’s game scene(s) from their latest .unitypackage.
- Imported MainMenu & endGame scenes, import level1 and level2 for reference from Cubesteroids3 (or latest).
- Add any GameManager or GameSettings objects & their related scripts to the Hierarchy in the imported scene.
- Add UIToolkit’s UI object to imported scene. Notice, it’s UILayer setting in Inspector will probably be unset. If you don’t feel like updating this every time – turn UI and it’s children into a Prefab, which will retain layer settings for you.
- If a Layer named UIToolkit doesn’t exist – name User Layer 10 (or one of your choice) “UIToolkit”. Click on UI in the Hierarchy, in the Inspector the UILayer setting should now be set to UIToolkit.
- Select “UIToolkit – text” in Hierarchy, in the Inspector the Layer should be set to UIToolkit. If not, manually set the Layer to “UIToolkit” in the Inspector.
- Merge ui / gui code from the old [GameManager class called] ThrowRigidBody.js to the new ThrowRigidBody.js. Without a “Team License” from Unity Technologies, this is a manual, line-by-line process unfortunately.
Prior to Build & Run
- Download your Dev Provisioning Profile
- If it’s an official release, make sure you’ve switched the Dev Provisioning profile from a test one to one using your Team’s Apple account
- Open Xcode. Do Window > Organizer.
- Drag your Dev Provisioning Profile into your list of profiles in Organizer. Connect your Device – you might need to drag a copy of the Profile to your device’s Provisioning Profiles tab in Organizer
- Hit Build & Run in Unity… should work.
To Distribute Wirelessly via TestFlight
- Set up an account at TestFlightApp.com, if you don’t already have one OR ask to be added as a Developer to an existing Team account.
- Open the Xcode project generated by Unity when you Build & Run
- Create an Archive in Xcode. When the Archive is read, click the SHARE button in the upper right corner of the IDE. Choose the appropriate Dev Provisioning Profile (there can be several in the list if this isn’t your first iOS project). Choose where to save the .ipa. If this part is confusing – a quick Google search will help w/ sources like Stackoverflow.
- Drag the .ipa into TestFlightApp.com’s Upload page.
- Follow TestFlight’s link to Invite Testers. NOTE: After new testers register their devices you might have to add them to your Dev Provisioning Profile via Apple’s Dev Center, recompile your app w/ the new profile & reupload your .ipa. Not sure if TestFlight has found a faster workaround to this.
To Quickly Allow a New TestFlight User to Install Your Build
- Send them a Tester invite via TestFlight. After they register their device, grab the Device ID.
- Add Device ID to your/your team’s Apple Developer Account
- Add the newly added Device to a Dev Provisioning Profile for your App ID
- Download your new/updated Dev Provisioning Profile to your machine
- On TestFlightApp.com go to Builds > Your Latest Build, choose Permissions in the left nav.
- Click on the UPDATE PROFILE button under Update Provisioning Profile to upload the new Dev Provisioning Profile that includes the new Tester’s device ID. This step allows you to skip re-compiling your app just to add dev install permissions for a new device.
- Notify your new Tester.