Preface has not written a blog for a long time, because recently in the study of cocos2d-x, a few days ago saw a cocos2d-html5 in the MoonWarriors, thinking can not use cocos2d-x for restructuring, on the one hand, you can practice this flight game programming ideas, on the other hand, you can also deepen the understanding of cocos2d-x, good, not much said, began to refactor, first we from. Start to open xcode to create a project. Here we select cocos2dx, and Next is Next. After installation, run the following command to check whether the project can run. If yes, we can write a program. If not, let's take a look at the problem (Baidu finds it by yourself). Let's take pictures, music, and other resources under MoonWarriors (files under the src directory) first) drag it to the Resources directory of the project and remember to select and copy this option. The preparation is complete. Next, we will create a scenario one by one.