Create a project
$ Cocos2d-x cd
$./Setup. py
$ Source FILE_TO_SAVE_SYSTEM_VARIABLE
$ Cocos new MyGame-p com. your_company.mygame-l cpp-d NEW_PROJECTS_DIR
$ Cd NEW_PROJECTS_DIR/MyGame
// If. bash_profile does not know how to create it, see http://blog.csdn.net/gamecocos2dx/article/details/24887113
Add ant in the. bash_profile File
Export ANT_ROOT =/Users/yangshengjie/apache-ant-1.9.3/bin
Download http://ant.apache.org/address
Previously:
./Create_project.py-project XXXX-package com. xxx. XXX-language cpp (no more !)
Now the new project creation command is: (you must run the./setup. py file only once before running this command)
Cocos new XXXX (project name)-p com. XXX. XXX (Project ID)-l cpp (ccp indicates the c ++ project, and lua identifies the lua project to be created)-d/Users/youmac/newprojects (Project path)
-L L: Yes. L: l in lower case. l: Yes. Don't mix it with |
This is written on the official website.
Https://github.com/cocos2d/cocos2d-console
The video of the http://v.youku.com/v_show/id_XNjg1Mzc4ODQ0.html sub-Dragon man can be used for reference (MacOS below the configuration to create a project and run)
The video of the http://v.youku.com/v_show/id_XNjg1Mzc4NzI0.html son three dragons can be used for reference (MacOS below the configuration android Development Environment)
// If you open github is 404 or there is no such page can refer to the following http://blog.csdn.net/gamecocos2dx/article/details/24882023
Run
Cocos run-s XXXX (PATH)-p ios (platform ios android mac)