Need help getting started with Cocos2d-x to build for iOS & android

Need help getting started with Cocos2d-x to build for iOS & android
0.0 0


I need cocos2d-x only for android. So how I build my game for android in Xcode? I really waned to.

I’m using CocosBuilder(aka SpriteBuilder) and really happy with coding for iOS. So simple, fast and comfortable. So, for android I will export levels in xml and load them in cocos2d-x and build for android, thats what I need.

I searched but a lot of info looks outdated and many people talking about pre-release options for android studio…

Cocos2d-x docs is awkward, this topic actually about that. But where is in them some information and example how to build game for android in Android studio and finally see running scene anywhere?

SonarLearning - there is no such example for android studio to build or something.


For android i use console.
If need some android spec debug, then eclipse.
Android studio i use only for signing key generation, not more.


But I would need to add specific SDK’s for android,in-apps and game center. I’m looking for some IDE for that. So this should be Eclipse? And I should use another IDE just for signing?


In eclipse i add for example admob.
For signing you don’t need any IDE. I just use it, because i didn’t tried another mode, and it’s works like a charm.


Oh lol) again some problems. I just dowloaded Eclipse installer and run it and get -

I clicked more info and downloaded suggested - Download Java for OS X 2015-001 and installed it.
After that I try to run Eclipse Installer again but I get:

So Eclipse suggest me to install outdated java. Ah even here again these stupid problems with simple things.

I’m trying to download Eclipse from here -

Which should I use? “Eclipse IDE for C/C++ Developers” or “Eclipse for Android Developers” ?
I’m trying to download both currently but ETA is 4hours oh man… speed so slow. My internet is 100MB\s



And how they solve my problem? update: Updated about 2 years ago /
Eclipse ADT Bundle - goes to Android Studio download.

Upd. I also downloaded from link in this tutorial and when I tried to run it I get: “Eclipse quit unexpectedly.”

@slackmoehrle are you seeing this?



The wiki is out of date. We have t removed it because we want to merge still relevant content into other docs at some point.

I can ask someone from engineering to take a look at the issues you are experiencing.


These videos outdated. Have you tested by your own ? To do what described there?


I think you need a newer version of Eclipse

Can you check this doc:


I have Eclipse LUNA, with El Capitan


So you just throwing me links without trying to check this by yourself? I should test it?

Eclipse ADT Bundle

This link now goes to


No, I meant check as in take a look at the doc and see if there are any steps in it that need to be performed.

I updated the link to Eclipse, it will go out in the next deployment of docs.


Thats not actually helps me to get started. In another about compiling libs thread you can check how it goes.

When cocos2d docs, get started guide will be updated, fixed and fit to latest updates?


I test these docs every few releases and our engineering team provides input on these steps.

I’ll test these docs again, one by one to see if anything goes wrong for me. I will do it in clean virtual machines to ensure there are no dependencies lingering around.

While you are having difficulties, I can see and you have found a few holes for items in the cocos doc and the link in the Eclipse install doc. These docs are not completely wrong. Your tone in these threads is that of “Cocos2d-x is completely lacking in docs”. This is untrue. We acknowledge that our docs may need to be written at a level that is more focused towards inexperienced developers. This is something we will work on as we edit and review docs for accuracy. Example: When I test the install docs I will make the steps more detailed so those that are new can read in greater detail. Those that are experienced will skim it quicker.


So why when I started 3 days ago and tried to install and compile a simple initial project - I got a tons of problems and still getting them this Prebuilt generation not working in 3.13.1 and 3.11.1?

Also, after all this problems will be fixd(i hope) i would like to ask(like I did in another thread, but there it’s an off-topic) so I will repost it here:


I’m not experiencing what you are and I’m not receiving reports that others are either. That being said, I will test each install doc in a new VM and see what is going on.


Android Studio should work. I think most of our users use a text editor and the command-line on Mac.

Use logcat to debug on Android


Thats need more info and examples and tutorials. Also how to code something like game center or call specific android functions and I probably I should mix java and c++? I have any ideas how it works on android and so thats why I need info. For iOS all clear to my because I’m using Objective C++ and mix any calls there and use any specific to iOS technologies like iCloud or GameCenter.