Building an android project.

Building an android project.
0.0 0


I am working on porting my win32 game to android…

I already successfully installed test on my android device, and I am trying to install my own project.

Where do I select the win32 project want to run on android when I build android project?
I created a project called “game_test”, and if I tried to type in my project name “game_test” in create-android-project->Please enter your project name:, it says it already exists.(I assume it’s because there is already a folder at cocos2dx root)

thank you in advance…


The name doesn’t matter, It’s just a name for the android project. You can call it like MyFirstTest or something. Then you get a folder MyFirstTest inside the root of cocos2d-x, Open it.
You see Android - Classes - Resources. Put your classes in side the classes folder, and for the resources the same :).
Then you have to open the file (if you use version 0.13, it should be at) MyFirstTest/Android/jni. Open it and add your classes you made to it.

Like so:

LOCAL_SRC_FILES := helloworld/main.cpp …/…/Classes/AppDelegate.cpp …/…/Classes/Player/Player.cpp
If you have done that, then you should open cygwin and go to the folder. cd /cygdrive/c/cocos2d-x/MyFirstTest/Android (ENTER) and then ./
And if anything goes wrong you will see it there :slight_smile:
Hope that gives you a start and answer to your question :slight_smile: