Saturday Discount - Lifetime Access for $20!!!! - Click Here!

Upgrading from Specific Builds – Story Tellers iOS Starter Kit Documentation

Upgrading from Specific Builds

Story Tellers iOS Starter Kit Documentation

In this article, we’ll discuss upgrading from specific Builds. If you want to visit our article on upgrading in general, it’s right here. You can also visit the Change Log here.


 

Upgrading from Build 1.08 to 1.09

Build 1.09 moved some sound playback code to the GameViewController.swift class (to play audio files continuously while transitioning pages). To update, you’ll need to replace these two files…

  •  Page.swift
  • GameViewController.swift

As usual there’s two ways to do this. You can copy and paste all the code from one file to another. Or just copy and paste the files from the latest project to your project via the Finder. If you notice more recent save dates on any other class files, you can replace them as well.

Upgrading from Build 1.07 to 1.08

Build 1.08 added In-App Purchasing to the kit. To update, be sure to include the Page_Store.swift class. You can drag it from the latest build directly into your project.

When you drag it in, you’ll get a prompt like this…

Add to Targets in Xcode

As always be sure Copy items if needed and Add to Targets is checked on.

Also be sure to update the Page.swift file. You can copy and paste all the code from one file to another. Or just copy and paste the Page.swift from the latest project to your project via the Finder. If you notice more recent save dates on any other class files, you can replace them as well.

 

Upgrading from Build 1.06 to 1.07

Build 1.07 added some awesome new events to the kit, including picking images from the Camera Roll / taking photos from the Camera to use in a page, video features, and a whole new way to run Actions / compose Actions via the property list.

With great features, comes great responsibility, so we’ve added a few new class extensions that will need to be added to your project for the upgrade. Don’t forget to update the other class files as usual, but those don’t need to be added to your project (since they are already in it).

The new files to add are selected in the image below…

Screen Shot 2015-09-11 at 11.13.03 AM

  • Page_Camera.swift
  • Page_Video.swift
  • UIView_Extension.swift

To add them to your project, you can simply drag and copy them from the latest version into your project. Try to keep things organized and drag them into the Page_Extensions folder. When you drop them in, you’ll get a prompt like this…

Add to Targets in Xcode

As always be sure Copy items if needed and Add to Targets is checked on.


 

Slight change to the App Delegate

To account for the new camera features, we needed to add a little to the AppDelegate.swift file (its in the Misc folder). The code we added is listed below…

App delegate Xcode

In the latest version, you can just copy this and paste it into your AppDelegate.swift file.

Then in the main Deployment Settings of Xcode, check on Requires full screen. This probably should have been checked on previously. If it’s not checked on, you get a harmless warning about it.

How to require full screen in Xcode 7


 

Optional Stuff

If you want to test out the video features, the kit has a small video file called CartoonSmart_Stinger.mp4 you can copy into your project.

The Info.plist file has always been inside the Fonts folder. We renamed that folder to Fonts and Info.plist so its easier to find the Info.plist.

And speaking of, we noticed when toggling Device Orientation in the Deployment Settings (see the image above), Xcode 7 wasn’t always updating the Info.plist file. The image below shows where to manually change the supported orientations (see the green arrows)… You can toggle those to switch to Portrait or add Portrait as well as Landscape.

Change orientations in Xcode 7 in Info plist

Finally, the App Transport Security Settings are circled above in orange. If your app will be pulling data from a site (for example, video hosted on your server), you need to specify that domain is allowed to access the app.

App Transport Security Settings - Exception Domains

This is done through the Exception Domains dictionary. Replace “yourdomain.com” with whatever your domain is where the content is hosted.

Personally, I would load external video using On-Demand Resources instead. Let Apple deliver it, and the content can be used as needed, but stay accessible after it’s downloaded.

If you stumbled onto this article, it is part of our documentation for the Story Tellers iOS Starter Kit 2. The kit enables you to make children’s book apps and games without writing any code! But it is Swift 2 based and compatible with iOS9 (or higher) and Xcode 7 (or higher), so kit buyers can even extend the functionality to fit their needs further. Some of what we cover in the kit documentation may apply to Xcode in general, so this article could be worth a read even if you aren’t a user. You can purchase Lifetime Updates the kit here, or subscribe Yearly to CartoonSmart and get the latest version, plus access to all of our other kits / tutorials.

We’ve also created an iBook to document the very latest properties in the kit, so be sure to download that as well.




Know what an affiliate program is? You make money just by sharing links to our site! Win. Win.

Earn when you refer any buyer here! 30 day tracking. Commissions are 33%-50% and recur on subscription products!