Deploy your C2 game to iOS - The easy way.

Favourite 123 favourites
Tutorial written by TaurianOriginally published on 15th, March 2014 - 6 revisions

Like the tutorial? Want it updated regularly? ^^ Favorite it ^^ -- please?

Prerequisites:
- You need a iOS Developer Account.
- You need to create your app in iTunes Connect before continuing here.
- Don't worry about the certificates and provisioning files! XCode will create them for you. (Yay!)

- You don't need to buy a mac.

----------------------------------------------------------------------

*Update: Game is now live on iTunes. It's free so check it out:

I recently used a combination of VMware and Ejecta to publish one of my iOS apps, Epic Space: Insurgence, after a few weeks of hair pulling.

----------------------------------------------------------------------

On to the good stuff

It's March 15th 2014 and CocoonJS is... broken.

No one from Ludei is responding to your requests for help. Your app is free -- and it needs a working leaderboard, in app purchases, iAds and more. (Because you have to eat).

Ashley is busy working on Websockets and probably doesn't notice that some developers are facing a dilemma. (And would probably tell you to take your problems up with Ludei anyway.)

You're starting to think you're screwed.

- Intel XDK is clunky.
- Phonegap is... Adobe.

There is no official, stable, and easy way to get your Construct 2 game into the hands of iDouches! What do you do?

Even if Ludei releases a more stable version of CocoonJS, Scirra has to import it, test it and more, or the plugin may have an unforeseen problem. Then you'll find yourself in yet another bind. You need a more stable solution:

----------------------------------------------------------------------

Introducing Ejecta


It's free, open source and probably your BEST solution to deploy stable iOS games.

Supports:
Game Center – Use Game Center's Leaderboards and Achievements
In App Purchases – Use the AppStore's In App Purchases
iAds – Show iAd Banners in your game

With this sucker in your toolbox, you'll speed up development time, test easily in XCode, and have one less company hoop to jump through (Yuck!).

The Steps:

1. Download the Ejecta Kitchen and place on your Desktop.
2. Place your Construct 2(unminified only) HTML5 Exported files into the App folder
3. Run Either EjectaXporter_2d.bat or EjectaXporter_WebGL.bat depending on your preference (They both work great at this time. Rename them to .txts to see exactly what they do.)

Then finally move the entire Ejecta_Kitchen1-4 Folder to a place that's accessible on your network. You'll load up your VMware Mac and access in a moment.

----------------------------------------------------------------------

You don't need to buy a Mac! Use VMware! It's such a life saver.


1. Follow the instructions here: How to setup OS X 10.9 with VMware - Windows 8.1
2. Move the Ejecta_Kitchen-14 (Which has your C2 Export files) some where on your desktop.
3. Load up the Xcode Project and test!

It doesn't have to be difficult, you may encounter challenges, but if this solution didn't save me time and energy, I wouldn't have written this here tutorial.

----------------------------------------------------------------------

TL;DR? Checkout my video

Your Thoughts:

- Are you having problems with CocoonJS?
- Did you incorporate Ads and a Leaderboard? (What lead me to Ejecta.)
- What kind of process are you using now that blows mine away?

Please share in the comments below.

Unlock your full gamedev potential

Upgrade to the Personal Edition of Construct 2, it has way more features and won't holding back from making money and using your full creativity like the free edition does. It's a one off payment and all Construct 2 editor updates are free for life!

View deals

Plus, it's got a lot of additional features that will help you save time and make more impressive games!

Congratulations on finishing this tutorial!

Did you learn a lot from it? Share it now with your friends!

Share and Copy this Tutorial

You are free to copy, distribute, transmit and adapt this work with correct attribution. Click for more info.

Comments

9
DatapawWolf 30.9k rep

Thanks man, I am bookmarking this for when I finally want to port to iOS. Great work!

Saturday, March 15, 2014 at 4:55:43 PM
6
5Type 3,754 rep

Thanks, going to have a look at ejecta, read about it before but was too lazy to try integrating it with c2.

If it works well i will drop Cocoonjs.

Saturday, March 15, 2014 at 5:09:19 PM
-11
liaeb 1,827 rep

I believe virtualising OSX on anything but Apple hardware is illegal! Consider macincloud.com or similar instead.

Saturday, March 15, 2014 at 5:24:52 PM
7
Taurian 6,707 rep
I believe virtualising OSX on anything but Apple hardware is illegal! Consider macincloud.com or similar instead.
quoted from liaeb

Actually that's not true. You can also buy the disk from apple directly and install on your VM. You should google it.

Saturday, March 15, 2014 at 5:35:47 PM
5
Tedg 9,888 rep

Thank you for share this .)

Saturday, March 15, 2014 at 6:20:41 PM
-3
liaeb 1,827 rep

I checked this out a while ago and unless anything has changed the EULA states it can only be virtualised on apple hardware.. Can you provide some evidence against this? Cheers

Saturday, March 15, 2014 at 6:40:13 PM
6
5Type 3,754 rep

Tried it and it works really well.
Once i figured out how i can replace the Bunde ID with my own and do not have this .ejecta fixed at the end, i will update my ios apps to ejecta. Dropping cocoon and all its bugs all the way :)

Well done @Taurian

Saturday, March 15, 2014 at 6:56:54 PM
6
EddyDingDongs 3,447 rep

Thank you so much, this tutorial is so important and I have bookmarked it :-)

Saturday, March 15, 2014 at 10:54:22 PM
9
producermark11 8,033 rep

For those overly concerned about the legality of using VMware,
they can simply buy a used Mac.

Sunday, March 16, 2014 at 12:44:21 AM
5
ArcadEd 22.1k rep

@5Type
You need to edit the info.plist in xcode. In the bundle id it has something like com.yourcompay.{PRODUCT_NAME} or something like that. Just edit it to your bundle id.

For some reason Ejecta did not work well at all on my small flappy clone. Lots of random lockups. It's strange because I had used it before on another game and didn't run into any issues.

I wish the plugin would get a little more robust. You can only use iAds, and only banner ads, not full screen. I have very little problems with CJS on the iOS side. My issues are more with getting facebook and google play games support.

Glad you got everything worked out though, I know how frustrating it is to wait for answers from Ludei.

Sunday, March 16, 2014 at 4:07:49 AM
8
Taurian 6,707 rep

See that's the thing. CocoonJS is closed source. With Ejecta, because it's open and extendable, you can find out how to call the full screen ad method in Objective-C.

It sounds complicated, because no one's done it before in Ejecta, but I'm pretty sure it's possible and you DON'T have to wait for someone to update a plugin.

But I'll add it to my Todo on my end.

Sunday, March 16, 2014 at 4:33:51 AM
8
ArcadEd 22.1k rep

That's a good point. I've built a few apps with C2/Xcode and Phonegap to get admob ads working. I'm sure it's possible as well. That function in the plugin would just be nice.

Closed source doesn't bother me if it works :), and you get support, haha. Like I said, so far I have had very little issues with CJS with 7 apps published (4 with CJS). Hopefully the monetizing course I am doing now will help everyone with it. I do plan on adding a section for Ejecta though, for those that want to go that route.

Sunday, March 16, 2014 at 4:52:29 AM
4
Lordshiva1948 44.2k rep

Thanks for sharing

Sunday, March 16, 2014 at 6:25:39 AM
2
jastrazz 3,535 rep

I will try too...Thank you for share!

Monday, March 17, 2014 at 4:33:44 PM
2
Joannesalfa 28.4k rep

I will consider to adopt your method to release my classic japanese beat em up game.

Tuesday, March 18, 2014 at 1:05:34 AM

Leave a comment

Everyone is welcome to leave their thoughts! Register a new account or login.