1.到Cocos2d-x官方网下载最新版,解压后在目录cocos2d-x-2.1.5 oolsproject-creatorcreate_project.py
2.安装Python,到网站http://www.python.org/getit/下载 Python2.7.5版本,并安装到默认路径C:Python27;
安装好后配置环境变量Path,指定默认C:Python27
3.将脚本放置到Cocos2d-x-2.1.5文件目录下
例如:python create._project.py -project HelloWorld -package com.cocos2d-x.org -language cpp
这个不需要命令,直接运行脚本即可!根据提示输入项目名。
@echo off cd tools/project-creator set /p projectName=Please Input ProjectName: if "%projectName%"=="" goto inputError set /p packageName=Please Input PackageName: if "%packageName%"=="" goto inputError create_project.py -project %projectName% -package com.cocos2d-x.org -language cpp pause exit :inputError @echo ProjectName Or PackageName is not NULL! pause