Cocos2d-x 3.1.1 Learning Log 12 -- A Cocos2dx3.1.1 porting to the Android platform method (the most useful and most effective !!), 12 -- android
Tools Required (in order ):
1. JDK
2. NDK
3. ANT
4. Adt-bundle-windows
Add the bin folder path under the JDK directory to the system environment variables.
Decompress NDK
Decompress Adt-bundle-windows
Run the eclipse.exe
File-> import
Then browse and find the directory where the project is located
Then finish ..
An error is prompted, but do not be afraid.
Open and check the cause of the error.
Right-click and choose Properties.
Click edit
Find the absolute path. In other words, it is the path of the folder where you decompressed cocos2dx3.1.1, but we need to find this... \ Cocos \ platform \ android \ java \ src
Because we need to use src .....
Click OK.
Return to the main interface
The error disappears...
Right-click the file name and choose Debug as> Android Application.
Compiling project .....
Click no
Okay, you can export it.
Return to the main interface
File-> export
Next is easy. next
Then
Enter the path, password, and confirmation !!
The next step is to enter
Click next and the path of the last apk step. OK !!!
If you don't know, add my QQ group: 239982941 (cocos2d-x 3.1.1 Learning Group)
Can android games developed with cocos2d be transplanted to ios?
1. C is a process-oriented language, C ++ is an object-oriented language, and Objective-C is an object-oriented language. Therefore, C ++ is very similar to Objective-C, C and Objective-C are different types of languages. 2. Objective-C language is an object-oriented language extended based on C ++, objective-C supports most of the features of C ++ (such as class, object, encapsulation, polymorphism, and inheritance). After learning C ++, learn Objective-C, be familiar with the syntax and ideas of object-oriented development, so that you can learn more about Objective-C. 3. The Object-oriented Thinking of C ++ is closer to Objective-C. Learning C ++ is very helpful for iPhone development and understanding iPhone development, this is also the root cause why many people did not learn C ++ and started iPhone development. 4. iPhone development mainly uses Objcetive-C language, and can also be directly developed using C ++. It is also very popular to mix Objective-C and C ++. And now the most popular Cocos2D-X iPhone game development, the use of the development language is C ++, because the Cocos2D-X supports cross-platform development, so it is favored by many iOS game developers. 5. Another important reason is that learning about iPhone development is mainly for entering the mobile Internet Industry and learning C ++ well. Everything else can be done, because the mobile Internet industry is absolutely inseparable from C ++. For example, in the past, Symbian was also based on C ++. Now Symbian development is basically switched to the iPhone. The basic language is the same and there is no problem, therefore, learning C ++ is necessary. Therefore, it is recommended that iPhone beginners start learning from C and C ++ languages and then learn Objective-C languages, which will be of great benefit to future career development.
Cocos2d-x win32 program porting to Android
APP_CPPFLAGS + =-Wno-error = format-security
Blog.csdn.net/.42411419