Configuring the COCOS2D-JS environment on the Windows platform

Source: Internet
Author: User

Directory

    • Install Python
    • Cocos2d-js Frame
    • Development tools (Webstorm/cocos Code IDE)
    • View official instances with Webstorm
    • Creating a project using the Cocos Code IDE

1. Install the Python 2.7 and configure the System environment variable path join the Pyshon installation path (>>)

Enter Python--version on the command line display version number is installed successfully

2.cocos2d-js Library Download (>>)

Unzip in one place as the Cocos2d-js engine directory and then double-click inside the setup.py after the System custom config variable

3. Build Webstorm development environment

Download and install Webstorm

Plug-in installation: To fit Webstorm tool debug, install plug-in Jetbrains-ide-support (>>)

Open Google Chrome, chrome://extensions/Enter, unzip and drag into the. crx file, after successful installation, the "JB" icon will appear after the address bar of the browser.

Set the <COCOS2D-JS engine directory > to the project root directory:

Open webstorm, select Menu File->new project from Existing Files, after the interface is selected, click the Next button to enter the Setup Project root dialog box,

Select the <cocos2d-js engine directory, and then press the project root button, and then click the Finish button to complete the setup.

4. Use Webstorm to view official examples:

Select samples->js-tests->index.html in the navigation panel, right-click index.html Select ' Debug ... ', and Webstorm will start Google The Chrome browser shows the following: Click on the menu to run the sample

5. Build Cocos Code IDE development environment

To run the Cocos Code IDE tool, we need to install JDK or JRE,JDK is the Java SDK, the JRE is the Java Runtime environment.

First download install Cocos Code IDE (>>)

JDK Download and installation

To configure the JavaScript framework:

Open the Cocos Code IDE tool, select Menu Window->preferences, Pop-up dialog box as shown, select Cocos->javascript in the right JavaScript frameworks select < COCOS2D-JS Engine Catalogue >

When you create a project, the Cocos Code IDE tool creates the project file from the JavaScript framework directory.

6. Create a project using the Cocos Code IDE, select the menu file->new->project, select Cocos JavaScript Project, then click the Next button to configure the appropriate information to continue next

After you have created the project, you can test it, select the Index.html file in the project navigation panel on the left, and choose Run As->cocos jsbinding in the right-click menu to run the results as follows:

Configuring the COCOS2D-JS environment on the Windows platform

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.