UE4 + iOS8 + GameCenter Sandbox + TestFlight: Survival guide

Last week, we sent Bovine Simulator to the AppStore for review. We were super happy, because we were finally releasing our first game!!  There were some minor bugs, but it was OK, since it was some kind of experimental project for us. We even uploaded screenshots for the new iPhone 6, just to be super up-to-date.

BUT…. we did not count that, a couple of days later, iOS8 was released… and, of course, it wasn’t working. Aaaargh!

 

issue #1: iOS8 + UE4 and landscape mode

For some reason, the game wasn’t accepting anymore the landscape mode, and it was loading weird (look at the image below).
The .plist file looked ok, the settings on UE4 were correct too, but the app was being displayed in a weird way. Well, after some headache, we discovered that upgrading to UE4.4 solved this issue (we were using 4.3 at the time). Wonderful!

 

issue #2: iOS8 + UE4 and the missing provisioning

But no, it wasn’t wonderful. Because at that point, we started having major problems packaging the app for distribution. UE4, for some reasons, did not include in the package neither the provisioning, nor the resources file. 

(Just to let you know, you can check your app’s signatures by running this command:

codesign -dvv Payload/UE4Game.app

​We searched on the internet, and we weren’t alone: they suggested us to unpackage the .ipa file, and the sign it again manually using the xcrun command. But something was still wrong, since we got an error stating that our “.plist file had been modified”, and it could not sign it. What? We didn’t even touch it! :(

After some more deep googling, we found out that you have to remove a .xcodeproject folder from your UE4 project before packaging. Appartently it was creating some conflict within UE4. After removing it, we could be able to easily package everything from UE again. Fantastic!!!

 

issue #3: can’t connect to GameCenter Sandbox :(

We were super happy, then. We uploaded our .ipa to TestFlight website (we used that a couple of years ago for Venice tides, too), with our ad-hoc provisioning, and we sent the test version of the app to our devices for a final control. Guess what? We got stucked again: Game Center wasn’t working anymore. 

Before iOS8, we had already created some sandbox account for GameCenter, and everything was working fine. Now, when trying to open GameCenter from within the game, we got an error saying that it could not connect the account. 

Our first idea was to reset the device (it used to solve the issue), but that wasn’t the case. We found some very useful articles (like this, and this) that helped us a lot. What we had to do was to test the app with TestFlight inside iTunesConnect (and not externally from the old website, as we were doing). By doing that, an option should appear in your device under Settings > Game Center, called “Sandbox”, that will let you test all the Game Center features.

 

issue #4: no more ad-hoc provisioning for TestFlight

We uploaded our .ipa to iTunes Connect then, but in the “Prerelease” tab we were getting this error: Build does not contain the correct beta entitlement

Wow… What we had to do was to recreate the provisioning (so that it will list, among entitlements, a property called “beta-reports-active: true”, package again the application and re-upload it to iTunes Connect (you have to wait about 10-15mins until Apple process your app).

Well… we tried again, and again, and again, but our new provisionings never had the beta-reports property. Why?!?

By the way, to check what entitlements your build has, you can run this command:

codesign -d --entitlements :- “Payload/UE4Game.app”

And, you know what? We were generating an ad-hoc provisioning, because in the past we always had to use that to beta-test apps with TestFlight. And no-one told us that wasn’t necessary anymore! Now you can upload to iTunes Connect your final build, with the AppStore provisioning. Before sending it to Apple for review, you can directly test your app with TestFlight and, when everything is ready, just send it to Apple right away.

Wow! That’s wonderful and way better than before actually, and we’re super glad it works this way now. But let’s be honest: the process had been very very harsh, and it would have been nice to get some news from Apple about how to handle this new changes to iTunesConnect.

 

But hey, all's well that ends well :)
Now we only have to wait for Apple’s approval. We’ll keep you updated! 

Add new comment