Question

I'm learning cocos2d-x and I want to create a project in VS, but I find that there is no template for VS, the version of cocos2d-x is 2.1.4. So I wonder what can I do to build a cocos2d-x project in VS2010 support both Lua and box2d

Many thanks :)

Was it helpful?

Solution

  1. Install python 2.6
  2. Open a command line window
  3. Go to your cocos2d-x-2.1.4\tools\project-creator folder
  4. Run create_project.py. Usage:

    create_project.py -project YourProjectName -package com.example.PakcageName -language cpp

  5. Your project will be created in cocos2d-x-2.1.4\projects

OTHER TIPS

If you follow the solution @Chen provided, I believe there is build-in box2d support. And you can add lua support following this step.

1.add "scripting/lua/proj.win32" project to your solution in visual studio. 2.right click solution, and add "liblua" rely to your project.

rebuild your project. And add

#include <CCLuaEngine.h>
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top