打开APP
userphoto
未登录

开通VIP,畅享免费电子书等14项超值服

开通VIP
cocos2dx 3.0后创建工程

//创建工程

$ cd cocos2d-x$ ./setup.py$ source ~/.bash_profile # may be ~/.bash_login or ~/.profile, depends on your environemnt$ cocos new MyGame -p com.MyCompany.MyGame -l cpp -d ~/MyCompany
  • MyGame: name of your project
  • -p com.MyCompany.MyGame: package name for android
  • -l cpp: programming language used for the project, valid value is cppand lua
  • -d ~/MyCompany: directory to hold your project


Folder structure of the generated project is as following:


(Note: The directory may be different when the project type is lua.)


Build And Run New Project

$ cocos run -s ~/MyCompany/MyGame -p ios
  • -s: directory of the new project. This could be an absolute path or a relative path.
  • -p: which platform to run on. Options are ios,android,win32,mac and linux.

(Note: You are a tmux user, you should add reattach-to-user-namespace before the command cocos. For more information, please refer to this link for more information.)

You can run cocos run --help for more detail information.





本站仅提供存储服务,所有内容均由用户发布,如发现有害或侵权内容,请点击举报
打开APP,阅读全文并永久保存 查看更多类似文章
猜你喜欢
类似文章
用python创建cocos2d-x项目
Cocos2d
Cocos2d-x Application Wizard for Visual Studio User Guide
Maven 基础知识(一)工程结构
关于J2me创建Java工程类的简单记录
CMake:Eclipse UNIX Tutorial
更多类似文章 >>
生活服务
热点新闻
分享 收藏 导长图 关注 下载文章
绑定账号成功
后续可登录账号畅享VIP特权!
如果VIP功能使用有故障,
可点击这里联系客服!

联系客服