Cocos Creator v1.6.0 released!

Cocos Creator v1.6 release is here! Thanks to the community for the patience of this version’s long test cycle and the positive trial and feedback on the beta versions. We continue to improve performance, efficiency and user experience in this version update.

The editor is where user spends most time on so we include several improvements on experience and efficiency. Then we keep on enhancing the performance of JS and C + + engine. We also solved issues that developers are most concerned about: package size, browser cache and network communications. Based on this goal, we added the following important features in version v1.6.

Feature Highlights

– JavaScript-Binding layer upgrade, a substantial increase in Android platform performance
– Preview the game do not need to bundle all scripts, instant refresh game after make changes to a script
– Batch editing node and component properties
– Add option to generate asset file names based on their MD5 when build for web platform
– Upgrade WebSocket library for iOS platform to solve most of the platform-specific network communication problems

### JavaScript-Binding layer upgrade

In this version, we upgraded the JavaScript-Binding layer between JS script and C++ engine. On the one hand we upgrade SpiderMonkey(a JavaScript engine) from v33 to v52. This results in a substantial script executing performance boost in Android platform (Because iOS platform does not enable JIT so the effect is not obvious); on the other hand, we started binding layer interface reconstruction from this version, the goal is:

– Provide a completely abstract JS-binding layer API, independent of the JavaScript engine, the user’s binding code will no longer be affected by the future updates of the JS engine.
– Support platform specific native JS engine: v8 engine on Android platform, JavaScriptCore on iOS platform.

After upgrading the binding layer, we not only provide a stable environment for binding JS code to C++, but also support the native JS engine on specific platforms that will make the package size significantly reduced for native builds, because SpiderMonkey engine library is not needed in the package.


### Preview game do not need to bundle all scripts

As a result of the need for modular scripting, we bundle user’s scripts before running it from the first version of Cocos Creator. But for a large project the number of scripts can easily go up to hundreds. Any change to any script will trigger the entire bundling process, and it will take a long time before the game can up and running with the updated scripts.

In order to solve this problem, we refactored script loading environment for a bundle-free modular system. When preview the game in editor, you can load a JavaScript script from another without having to bundle them. Any changes to the script will only trigger the script compilation (ES6 to ES5, TypeScript to ES5) itself, making the game instantly up and running after the modification of the script, greatly improving development efficiency.


### Batch edit node and component properties

When editing UI scenes, you often encounter the need to select some nodes and bulk modify a property to their needs, this version we added the batch editing function to Properties panel.

After selecting multiple nodes, the components and attributes shared by these nodes can be edited in batches. When the property values of different nodes are different, selecting these nodes will make them display as -, modify this value will make the property of all the selected nodes share the same value.


### Add option to generate asset file names based on their MD5 when build for web platform

For HTML5 game developers, the effective use of the browser’s cache system is very important, to prevent users to repeatedly download resources, and ensure that the cached resources can be correctly updated. In this version we add **MD5 Cache** option to the Build Settings panel. If checked the build process will add the MD5 of each asset file to the filename. So the end user’s browser will automatically re-download the asset files which has different MD5, to save traffic and ensure the consistency of the version.

### Using SocketRocket to replace previous WebSocket implementation on iOS platform

We use [SocketRocket library](, which developed by facebook, to replace the libWebsocket library that has been used in the cocos2d-x and Cocos Creator C++ engines. This new implementation supports the following features:

– The API of SocketRocket is easy for use, it’s all asynchronous API.
– No need to deal with thread communications, it’s wrapped inside SocketRocket.
– Network status change will not make connection closed, it just seems there is not any status change.
– Locking screen will trigger an error while libwebsockets or bsd socket will not.
– Do not depend on openssl library which is a little big
– Do not need to use a local CA root certificate (curl ca file is over 2MB) for wss connection
– Do not trigger signal pipe while closing wss connection

Follow-up version of the will be the original realization of our further optimization, hoping to provide developers with a simple, stable network communication programming environment.

Download it today!

Discuss here!

Posted in Uncategorized