Cocos2dx for the first time.
It seems that there are great differences between versions. Compared with the previous versions, 3. X is easier to use and more convenient.
1. Install python. My python-2.7.3. Configure Environment Variables
In the system variable: Add D: \ 2013 \ python \ Python27 to the Path.
2. Install ant. Apache-ant-1.9.3. Configure Environment Variables
In the system variable: Create a New ANT_HOME (D: \ 2013 \ ant \ apache-ant-1.9.3), and add D: \ 2013 \ ant \ apache-ant-1.9.3 \ bin
In the user variable: Create a New ANT_ROOT (D: \ 2013 \ ant \ apache-ant-1.9.3 \ bin)
3. cocos2dx 3.1.1.
Execute the download-deps.py in sequence, setup. py
Configure NDK_ROOT (D: \ TOOL \ android-ndk-r9d), ANDROID_SDK_ROOT (D: \ TOOL \ android-sdk), ANT_ROOT (D: \ 2013 \ ant \ apache-ant-1.9.3 \ bin)
Pay attention to the ndk version, log out of the host, and execute setup. py again. If the flash passes, the configuration is complete.
4. Create a new project.
Cocos new-p com. xxx. simple-l cpp-d D: \ 2013 \ cocos2dx \ projects simplegame
V. Compilation
1. Command Line Compilation: Enter the project directory through the command line. cocos compile-p android (ant can also be compiled and the command is ant debug)
2. eclipse Compilation: directly import eclipse, which is no different from 2.x. After being imported, you can directly run the compilation. (You do not need to configure this configuration here, which is much easier than 2.x)
I wrote about it and left a message if I don't understand it.