Cocos Creator v1.5.0 Release!

Cocos Creator v1.5.0 Release!
0.0 0


1.5 Release: Physics engine, TypeScript support

This version 1.5 update focuses on the lack of features for action games large-scale project development, through the provision of physics engine, camera and TypeScript support.

Cocos Creator is now able to develop all kinds of action games and large projects for much better experience. In addition to the high expectations of the community requested new features, we once again optimized the engine load logic, a substantial increase in the scene loading and parse speed; In addition, we refactored the Windows desktop and Android platform Label and EditBox implementation, greatly enhanced the experience and compatibility.

Highlight features

  • Integrated Box2D physics engine, add rigidbody and joint components
  • Add Camera components to support high speed scrolls without loss of performance
  • TypeScript and ES6 Class support, fully enhanced IDE code prompt
  • Optimize the scene loading process, the scene load speed increased by 38%
  • Cross-project assets export / import, assets dependencis will be automatically associated.
  • Enhance the experience and compatibility of Label and EditBox in the Windows desktop platform and Android platform
  • Improved hot update with continued download after connection broken.

Below we will list details of key new features.

Integrated Box2D physics engine

Cocos Creator in the 1.5 version has finally integrated the well-known physics engine Box2D, this easy-to-use powerful physics engine will bring a comprehensive physical detection and computing power to Cocos Creator to fully support your actions and physical games.

In addition to the common physics engine functionality, Cocos Creator’s integrated physical system incorporates Rigidbody and Joint components, plus Collider components tailored specifically for the physics engine. You can achieve interesting interactive effect just by placing a variety of different physics components in your scene. With the newly added Camera components, the editor can build scroller game levels with rich content very easily!


Camera component

In the development of action and adventure games, the change of viewport or screen scroll across scene is essential. In earlier versions developers can only move all nodes of scene to simulate the effect of perspective movement, but a large number of node displacement operations will affect performance, especially after integrate physics engine. Each time moving the collision body will lead to the regeneration and calculation of the physical world.

And in the 1.5 version Camera component can be added to solve the problem of moving perspective. Camera component can specify one or more nodes as the camera rendering target. You can drag the root node of the scene into the Camera target list, then just move the node with Camera component will give you the effect of viewport moving across the scene. Camera rendering is achieved through the matrix operation, so the scene will not bring in additional overhead


TypeScript and ES6 Class support

In order to better support coding in various IDEs (such as VS Code, WebStorm, etc.) with full code prompt and auto complete, we made a refactoring of the declaration of cc.Class in version 1.5 and can now use ES6 or TypeScript to declare components and write game logic in Cocos Creator.

Many users who have experience with strong typed language before using Creator give feedback about poor code prompts and automatic completion. This is mainly due to the editor needs the special declaration format for data serialization. But major IDEs cannot recognize the format for properly code parse and code prompt. In this version’s refactoring we introduced the decorator syntax to help the editor to identify the data, and then we can use ES6 and TypeScript standard syntax to declare cc.Class and cc.Component. Use the standard syntax will make sure all mainstream IDE can parse the code correctly and can correctly prompt almost all the relevant interface code!

TypeScript supports strong typing declarations that provide more accurate interface communication specifications and error reporting for large projects that are collaboratively developed. Recommend the relevant strong type of language development experience and large-scale project technical team to try!

Auto complete

Scene loading speed increased by 38%

The biggest advantage of web game is instant play without installation, so web game scene loading speed, especially the initial scene loading speed is essential for user experience and retention. This update has included many optimization for scene asset loading, using the object pool to greatly reduce the frequency of object creation in the uuid-loader and deserialize modules, with a 38% increase in scene loading speed during local preview. But the actual project load speed bottleneck may come from the network connection speed, so the actual game speed increase depends on network settings, but basically there will be 200ms ~ 300ms improvement at least.

Cross-project asset import / export

In the previous release, we implemented the functionality of sharing a asset folder between projects by editor extension system, but there were more users who wanted us to provide a simpler, more direct, cross-project import and export mechanism, so that we can export assets from existing projects into new projects, or separate art and developer projects.

Through the main menu “File -> Import / Export Assets” to open the assets import and export tool. We can easily drag a scene or Prefab for export, the tool will automatically list the assets dependencies, then automatically generated zip package for all exported asset files. In another project you can easily import the zip package. If you encounter uuid conflict you can also choose to automatically update uuid to retain two versions of the assets.


Full changelog


  • [Scripting] Add support for TypeScript script, add support for ES6 Class declaration for cc.Class and components. Enhanced code prompts in mainstream IDEs.
  • [Editor] Add asset export/import tool with full dependencies.
  • [Editor] Only one part of the large-size code file is previewed in the Properties panel to improve the editor performance when browsing large files
  • [Editor] Add the option “Load in the editor” for the script assets when checked “Import as plugin”. To determine a plugin script whether should be loaded in the editor, to improve the efficiency of the scene open.
  • [Editor] Exports all CCClasss for all project scripts by default.
  • [Editor] When the custom engine path fails to load, an error is reported and an attempt is made to use the built-in engine
  • [Editor] Fixed the issue when quit editor after modify the scene, and choose save in pop-up dialog cannot save the scene properly.
  • [Editor] Add update-db API in preview server so that you can send request to the preview server to trigger asset import and script compilation.
  • [Editor] Fix the alpha value of cc.Color will be deserialized wrongly when set to 0.
  • [Editor] Fix the problem when you cancel the save file dialog an error will be reported.
  • [Assets] Fixed sub-meta import failure does not show the error message issue.
  • [Assets] Add the “Open asset in library” option in the context menu of Asset panel.
  • [Assets] Fixed error when creating Prefab by dragging a scene node to Assets panel: typeError: s.canAddChild is not a function at assets-tree._onDropAreaMove
  • [Build] Fix compilation failure errors that may occur when building and compiling window and android platforms with binary templates
  • [Build] Combine SpriteFrame asset json file in an atlas into a single file.
  • [Build] Fixed command line build failed when the preview page is not closed.
  • [Build] Fix the issue of increased file count when building with inline all SpriteFrame option in some cases
  • [Build] supports the use of Android Studio 2.3+ and Build Tools 25 to build Android projects
  • [Build] Fix AutoAtlas on windows does not generate spriteFrame information correctly into settings.js issue.
  • [Build] Add custom build and compile event callback for editor extensions.
  • [Build] Fix the problem with wrong ndk.dir field name in when building Android Studio project
  • [Build] supports the use of Visual Studio 2017 to build native projects
  • [Prefab] Added dependency async loading option on Prefab asset
  • [Prefab] Fixed when save automatic synchronization prefab refers to other prefab assets will report error issue.
  • [AutoAtlas] Fixed AutoAtlas created in resources folder will not add spriteframe information to the settings in the settings.js issue.
  • [ProjectSettings] Fix the problem that the Properties panel not updated in time once group setting changed.
  • [ProjectSettings] Fix the problem of setting the simulator orientation vertical and horizontal does not take effect.
  • [Preferences] Fix preferences -> Native development environment, when the javascript or cocos2d-x engine path is not specified, the settings can still be saved.
  • [Preview] Replaces the FPS display module for web platform preview, adding more debugging information


  • [Render] set cc.macro.FIX_ARTIFACTS_BY_STRECHING_TEXEL macro back to 0 to fix the problem that the surrounding pixels of texture will be cut off. But this change will cause the issue that tiledmap may produce a black seam when zooming and paning. You can fix it by generate a tiledmap map with extruded pixel around each tile (If you use the shoebox to generate a map, you need to set extrude to 1, padding is set to 2)
  • [Engine] Optimized the deserialization and download of asset operations when the web platform loads scenes. In the local preview the speed of scene loading may increase by 38% (the bottleneck still depends on the speed of the connection when the resource is loaded, and the actual speed boost may be lower than that)
  • [Engine] In CCClass declaration’s editor properties add the executionOrder field to control the script execution order
  • [Engine] cc.loader.loadResAll has been renamed to loadResDir, added loadResArray interface, used to pass the same type of asset url array
  • [Engine] Enabled multi-touch events on the iOS device, now you can correctly use the two-finger zoom and other gestures
  • [Engine] Fixes customEventData in the EventHandler component may change to an invalid value in the script
  • [Engine] Fixed an issue where the capInsets setting was invalid when the Sprite component was not activated
  • [Engine] Fixed native platform using the relative path to load the tmx file will report error issue.
  • [Engine] Optimize the use of DOM Image memory, delete dom image after handleLoadedTexture, and use the object pool reuse dom image to reduce the memory footprint
  • [Engine] Add pauseAllActions and resumeAllActions interfaces on cc.Node
  • [Engine] Add pauseSystemEvents and resumeSystemEvents interfaces on cc.Node
  • [Engine] Upgrade the C ++ engine’s Audio and Network related code libraries
  • [Engine] Fixes crash when loading scenes with async asset loading that use the LabelAtlas font asset.
  • [Engine] Fixed calling cc.loader.release on prefab loaded by script will not release dependent asset issue.
  • [Engine] Fixed deactive node in onLoad may lead to onLoad callback not triggered on sibling node.
  • [Engine] Fixed when the width or height of Scale9Sprite is set to 0, the sliced ​​mode will lead to data calculation error issue.
  • [Engine] Fixed issue when some of the UI nodes call removeFromParent() after unload the scene, the UI object’s cleanup function will not be called correctly, resulting in the native platform ui control memory can not be cleared.
  • [Engine] Fixed an issue where a registered event on a node might be triggered when a non-active node was added to the node tree
  • [AssetManager] adds more progress information to the progress callback, including: total bytes, downloaded bytes, total number of files, number of downloaded files, and recovery from recovery.
  • [AssetManager] Fix setVersionCompareHandle in the init process can not take effect
  • [AssetManager] supports dynamic creation of manifest files and manual loading of local and remote manifests
  • [AssetManager] Fixed restart download cannot be completed after connection fail.


  • [Physics] Supports Box2D physics engine
  • [Camera] Add Camera component
  • [Animation] Fixes the use of cc.instantiate clone when the animation node is animated playOnLoad does not take effect
  • [Animation] Fixed animation delay setting is invalid
  • [Animation] Fixed an issue where the Animator object might leak when the node where the Animation node moved out of the node tree and then the node’s destroy operation
  • [Animation] Fixed the issue that add new component in the animation edit mode and edit the problem that will cause the error
  • [Animation] Fixed set asset with empty uuid will cause error issue.
  • [Animation] Fixed in animation editing mode, change the delete clip will lead to crash issue
  • [Particle] Fixed set auto release on particle component may cause error issue.
  • [Particle] Fixes the issue of using the animation editor to edit the particle position may cause error.
  • [BMFont] Fix the imported file in the file where the path is an absolute path when the import error will be reported
  • [Label] Refactored Label implementation on windows desktop platform to achieve the following problems:
    • Word wrap, Shrink and other text overflow effect is invalid
    • Single line text box is displayed as multiple lines when inputting content
    • The text box will only show the first few characters
    • Text can not be aligned when multiple lines of text are entered
  • [Label] Fixed iOS platform shrink mode will not show complete text content issue.
  • [Label] You can use the fontFamily attribute to specify the font type when using system fonts
  • [Label] Fixed BMFont in the native platforms will cause memory leak problem
  • [Label] Fixed bug where bmfont switched fonts will cause spaceX property fail to take effect.
  • [Toggle] modifies the timing at which the Toggle component sends events and sends events after the other toggle state changes
  • [Toggle] When isChecked now sets the target node’s active instead of setting the target node’s sprite.enabled
  • [ToggleGroup] Now calls addtoggle when it needs to be enabled
  • [EditBox] Refactored EditBox in the windows desktop platform to achieve directly in game interface to enter the text, no longer need to pop up a dialog box.
  • [EditBox] Improved EditBox compatibility on the Android platform: Fix the first time you click on the input box may not be able to pop up the keyboard problem; Fixed input before and after the font size is not uniform; Fixed switch EditBox single and multi line mode shows incorrect alignment problem.
  • [EditBox] Fixed textChanged event callback count on the native platform is not correct
  • [EditBox] Fixed the problem that the native platform displays double text when the string attribute is modified in the textChanged event
  • [EditBox] Fixed modifies EditBox.string in event callback will cause incorrect cursor position issue; Fixed switch single and multi-line mode, EditBox window adaptation is not correct issue.
  • [ScrollView] Fixed scrolling to the border events that can be fired multiple times after setting elastic rebound.
  • [ScrollView] Fixed the problem of inertia scrolling cannot bounce back to initial position, Fixed the issue using script to execute removeFromParent and then add it to the node tree will be unable to scroll.
  • [VideoPlayer] Add embedded video playback (inline play) mode for iOS platform.
  • [VideoPlayer] Fixed video cannot be played in iOS 10 browser issue.
  • [VideoPlayer] in toggle visibility, no longer remove dom, but only modify visibility
  • [WebView] Fixed webview size in iOS browser is not correct
  • [WebView] Fixed webview in chrome 58 may not work issue, toggleVisibility will no longer remove the dom node.

If you have any questions or problem regarding the new features of v1.5, please discuss here!

TileMap black line artefacts

Thanks! Can you please update the english api doc for v1.5?


Yes, I am working on API reference and Manual for v1.5.0.


@nantas is cc.loaders release dependencies intended to work on web version? I have been having issues since earlier version and I have checked with v1.5.0, the issue is still there.


Awesome! :slight_smile:

Though I was hoping that the scaling bug for particle system on web builds made it to v. 1.5 release!


I got error message “Unknown engine version!” when compile for android studio. I’m using cocos2dx 3.15, ndk r14b.




@nantas the Label bug is still happening with 1.5:

And this is somewhat critical if you plan to localize your game to a language with special characters (my guess, this is also happening with all romanic languages).



download complete 5 min



I just downloaded Cocos Creator 1.5 and my game halts during Web Preview, both FireFox and Chrome, and this game worked in the previous version of Cocos Creator. I really appreciate the effort that Cocos Creator team puts in giving this community, an open source solution to game creation. But I’m going to be honest with you, I’m really getting freaking tire of this nonsense, of downloading a supposed finish product and lo and behold, now the game doesn’t work in Web Preview, maybe it’s my code, but if it worked before, there’s no reason that it shouldn’t work now. This is really tiresome and very disheartening…:rage::tired_face::tired_face: I will download again Cocos Creator 1.5 and see if this would fix the issue, if not, I will need to investigate and see what’s causing it, so spend more time in why it doesn’t work, instead of adding the physics component, and finally finishing and releasing my first game with Cocos Creator…God Bless…




Who can I contact if I see typos in the documentation or in the screenshots?

e.g. On this page “tow more lines” and “two more linea” look strange.


Going to say it’s just that your code is using a piece of code that was probably deprecated or changed.On my end everything working fine


Hi @ht78

Thanks for the tip, but I just went to the API, and I don’t see any deprecated? I’m beginning to think, that it could be the Collider Component with the below code:

<code> var collidemanager = cc.director.getCollisionManager();
    collidemanager.enabled = true;</code>

But I don’t think this would affect the whole game, I mean, I see the game on the screen, but it freezes, nothing is clickable, nothing moves…I don’t know if I should get rid off regular ColliderManager and go with the Physics Collider, but then again, I can leave the orginal collider, and add the RigidBody component to get physical contact between objects? Really at odds with this…God Bless…




Hi @ht78

Forgot to say, not even in the simulator it works, it just freezes…the whole game…One thing I find strange that in the Web Preview, I take a look at the FPS window on the bottom left corner, and draw calls is at zero? My platform is Mac Mini with Mac OS Sierra 10.12.4? Still searching…God Bless…





I’m getting this in the simulator log within the editor:

Simulator: cocos2d: warning, Director::setProjection() failed because size is 0

So, I don’t know if this has to do with my current situation?

God Bless…




That does seem a bit weird, begginerI tried beginner project to see if everything was working cause I know that it isn’t updated every update, So, I fired it up to check if any recent changes in 1.5 would have affected it.It’s still working from my recent test, I’m on a Hp Desktop running windows 10 and everything is running fine.

I’m also surprised if it’s anything to do with your OS since the devs use MacOSX as their main workbenches from looking at the GitHub projects


Hi @ht78

Thanks for the feedback, much appreciated it…I even tested it out on Build - > Desktop and Web Mobile and the same situation, sometimes I see a white block, where there’s supposed to be a sprite. Once I get to the main scene, is where the game starts, it just freezes…I don’t even want to Build an apk or ipa without a defibrillator on hand, just in case…:grin: God Bless…




Im use android studio sdk and all is good

But download sdk is fail



Getting the below in Chrome Dev:

internal/process/warning.js:24 (node:739) Warning: Possible EventEmitter memory leak detected. 11 changed listeners added. Use emitter.setMaxListeners() to increase limitprocess.on @ internal/process/warning.js:24

God Bless…




Yes, i went back to version 1.4.2 because my games was not working in 1.5.0. May be it is better to wait until getting new versions if they are not compatible or stable.