Skip to content

Commit

Permalink
Merge branch 'master' into next
Browse files Browse the repository at this point in the history
  • Loading branch information
pandamicro committed Mar 13, 2018
2 parents 3cbc221 + e551128 commit 77febbf
Show file tree
Hide file tree
Showing 252 changed files with 2,737 additions and 655 deletions.
12 changes: 4 additions & 8 deletions CCBoot.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,19 @@
/****************************************************************************
Copyright (c) 2013-2016 Chukong Technologies Inc.
Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
http://www.cocos.com
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated engine source code (the "Software"), a limited,
worldwide, royalty-free, non-assignable, revocable and non-exclusive license
worldwide, royalty-free, non-assignable, revocable and non-exclusive license
to use Cocos Creator solely to develop games on your target platforms. You shall
not use Cocos Creator software for developing other software or tools that's
used for developing games. You are not granted to publish, distribute,
sublicense, and/or sell copies of Cocos Creator.
The software or tools in this License Agreement are licensed, not sold.
Chukong Aipu reserves all rights not expressly granted to you.
Xiamen Yaji Software Co., Ltd. reserves all rights not expressly granted to you.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
Expand Down Expand Up @@ -81,12 +82,7 @@ function _determineRenderType(config) {

function _afterEngineLoaded() {
cc._engineLoaded = true;
if (CC_EDITOR) {
Editor.log(cc.ENGINE_VERSION);
}
else {
console.log(cc.ENGINE_VERSION);
}
console.log('Cocos Creator v' + cc.ENGINE_VERSION);
if (_engineLoadedCallback) _engineLoadedCallback();
}

Expand Down
7 changes: 4 additions & 3 deletions CCDebugger.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,19 @@
/****************************************************************************
Copyright (c) 2013-2016 Chukong Technologies Inc.
Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
http://www.cocos.com
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated engine source code (the "Software"), a limited,
worldwide, royalty-free, non-assignable, revocable and non-exclusive license
worldwide, royalty-free, non-assignable, revocable and non-exclusive license
to use Cocos Creator solely to develop games on your target platforms. You shall
not use Cocos Creator software for developing other software or tools that's
used for developing games. You are not granted to publish, distribute,
sublicense, and/or sell copies of Cocos Creator.
The software or tools in this License Agreement are licensed, not sold.
Chukong Aipu reserves all rights not expressly granted to you.
Xiamen Yaji Software Co., Ltd. reserves all rights not expressly granted to you.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
Expand Down Expand Up @@ -100,7 +101,7 @@ cc.DebugMode = Enum({
*/
cc._initDebugSetting = function (mode) {
// reset
cc.log = cc.warn = cc.error = cc._throw = cc.assert = function () { };
cc.log = cc.warn = cc.error = cc.assert = function () { };

if (mode === cc.DebugMode.NONE)
return;
Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.txt
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ Cocos2d-JS v3.4 Beta0 @ March 19 2015

* Bug fixes:
1. Added `getSpriteFrame` to `cc.Sprite` to fix API inconsistency.
2. Added `getObejct` to `cc.TMXObjectGroup` to fix API inconsistency.
2. Added `getObject` to `cc.TMXObjectGroup` to fix API inconsistency.
3. Added `addImageAsync` to `cc.textureCache` to fix API inconsistency.
4. Fixed a bug of `cc.text` that its default font name is incorrect.
5. Fixed a bug of `ccui.PageView` that its `getPage` doesn't work.
Expand Down
30 changes: 29 additions & 1 deletion DebugInfos.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,28 @@
/****************************************************************************
Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
http://www.cocos.com
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated engine source code (the "Software"), a limited,
worldwide, royalty-free, non-assignable, revocable and non-exclusive license
to use Cocos Creator solely to develop games on your target platforms. You shall
not use Cocos Creator software for developing other software or tools that's
used for developing games. You are not granted to publish, distribute,
sublicense, and/or sell copies of Cocos Creator.
The software or tools in this License Agreement are licensed, not sold.
Xiamen Yaji Software Co., Ltd. reserves all rights not expressly granted to you.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
****************************************************************************/

if (CC_DEBUG) {
module.exports = {
// Common
Expand Down Expand Up @@ -79,6 +104,7 @@ if (CC_DEBUG) {
"1509": "Argument target must be non-nullptr", //isScheduled
"1510": "cc.Scheduler: Illegal target which doesn't have uuid or instanceId",
"1511": "cc.Scheduler: pause state of the scheduled task doesn't match the element pause state in Scheduler, the given paused state will be ignored",
"1512": "cc.Scheduler: updateFunc parameter is deprecated in scheduleUpdate function, and will be removed in v2.0",
//Node: 1600
"1600": "getZOrder is deprecated. Please use getLocalZOrder instead.", //getZOrder
"1601": "setZOrder is deprecated. Please use setLocalZOrder instead.", //setZOrder
Expand Down Expand Up @@ -256,7 +282,8 @@ if (CC_DEBUG) {
"3115": "Frame Grabber: could not attach texture to framebuffer", //CCGrabber.grab
"3116": "WebGLRenderingContext.CLAMP_TO_EDGE should be used in NPOT textures", //setTexParameters
"3117": "Mimpap texture only works in POT textures", //generateMipmap
"3118": "Lazy init texture with image element failed due to image loading failure: %s",
"3118": "contentSize parameter is deprecated and ignored for cc.Texture2D initWithData function", // initWithData
"3119": "Lazy init texture with image element failed due to image loading failure: %s",
//RectWidth: 3300
"3300": "Rect width exceeds maximum margin: %s, max x: %s, texture width: %s", //RectWidth
//RectHeight: 3400
Expand Down Expand Up @@ -389,6 +416,7 @@ if (CC_DEBUG) {
"3818": "Failed to read or parse project.json", //_loadConfig
"3819": "Warning: target element is not a DIV or CANVAS", //_initRenderer
"3820": "The renderer doesn't support the renderMode %s", //_initRenderer
"3821": "Cannot change hierarchy while activating or deactivating the parent.",
//Animation: 3900
"3900": "Invalid clip to add", //addClip
"3901": "Invalid clip to remove", //removeClip
Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ The framework is naturally integrated with Cocos Creator, so it's not designed t

### Prerequisite

- Install [node.js v4.2.1+](https://nodejs.org/)
- Install [node.js v8.0.0+](https://nodejs.org/)
- Install [gulp-cli v3.9.0+](https://github.com/gulpjs/gulp/blob/master/docs/getting-started.md)

### Install
Expand All @@ -38,7 +38,7 @@ gulp build
#### Prerequisite

- Install [express](http://expressjs.com/): `npm install express`
- Install gulp-qunit: `npm install gulp-qunit@1.3.0`
- Install gulp-qunit: `npm install gulp-qunit`

#### Unit Test

Expand Down Expand Up @@ -84,7 +84,7 @@ npm test

* [Official site](http://cocos2d-x.org/creator)
* [Download](http://cocos2d-x.org/download)
* [Documentation](http://cocos2d-x.org/docs/editors_and_tools/creator/index.html)
* [API References](http://cocos2d-x.org/docs/api-ref/creator/v1.0/)
* [Documentation](http://www.cocos2d-x.org/docs/creator/manual/en/)
* [API References](http://www.cocos2d-x.org/docs/creator/api/en/)
* [Forum](http://discuss.cocos2d-x.org/c/editors-and-tools/cocos-creator)
* [Road Map](http://discuss.cocos2d-x.org/t/cocos-creator-roadmap)
* [Road Map](https://trello.com/b/JWVRRxMG/cocos-creator-roadmap)
3 changes: 2 additions & 1 deletion cocos2d/actions/CCAction.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
/****************************************************************************
Copyright (c) 2008-2010 Ricardo Quesada
Copyright (c) 2011-2012 cocos2d-x.org
Copyright (c) 2013-2014 Chukong Technologies Inc.
Copyright (c) 2013-2016 Chukong Technologies Inc.
Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
http://www.cocos2d-x.org
Expand Down
3 changes: 2 additions & 1 deletion cocos2d/actions/CCActionCatmullRom.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
/****************************************************************************
Copyright (c) 2008-2010 Ricardo Quesada
Copyright (c) 2011-2012 cocos2d-x.org
Copyright (c) 2013-2014 Chukong Technologies Inc.
Copyright (c) 2013-2016 Chukong Technologies Inc.
Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
Copyright (c) 2008 Radu Gruian
Copyright (c) 2011 Vit Valentin
Expand Down
5 changes: 3 additions & 2 deletions cocos2d/actions/CCActionEase.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
/****************************************************************************
Copyright (c) 2008-2010 Ricardo Quesada
Copyright (c) 2011-2012 cocos2d-x.org
Copyright (c) 2013-2014 Chukong Technologies Inc.
Copyright (c) 2013-2016 Chukong Technologies Inc.
Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
http://www.cocos2d-x.org
Expand Down Expand Up @@ -271,7 +272,7 @@ cc.easeSineInOut = function(){

/**
* !#en
* Creates the action easing obejct with the period in radians (default is 0.3). <br />
* Creates the action easing object with the period in radians (default is 0.3). <br />
* Reference easeInElastic: <br />
* http://www.zhihu.com/question/21981571/answer/19925418
* !#zh
Expand Down
3 changes: 2 additions & 1 deletion cocos2d/actions/CCActionInstant.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
/****************************************************************************
Copyright (c) 2008-2010 Ricardo Quesada
Copyright (c) 2011-2012 cocos2d-x.org
Copyright (c) 2013-2014 Chukong Technologies Inc.
Copyright (c) 2013-2016 Chukong Technologies Inc.
Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
http://www.cocos2d-x.org
Expand Down
3 changes: 2 additions & 1 deletion cocos2d/actions/CCActionInterval.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
/****************************************************************************
Copyright (c) 2008-2010 Ricardo Quesada
Copyright (c) 2011-2012 cocos2d-x.org
Copyright (c) 2013-2014 Chukong Technologies Inc.
Copyright (c) 2013-2016 Chukong Technologies Inc.
Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
http://www.cocos2d-x.org
Expand Down
3 changes: 2 additions & 1 deletion cocos2d/actions/CCActionManager.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
/****************************************************************************
Copyright (c) 2008-2010 Ricardo Quesada
Copyright (c) 2011-2012 cocos2d-x.org
Copyright (c) 2013-2014 Chukong Technologies Inc.
Copyright (c) 2013-2016 Chukong Technologies Inc.
Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
http://www.cocos2d-x.org
Expand Down
25 changes: 25 additions & 0 deletions cocos2d/actions/index.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,28 @@
/****************************************************************************
Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
http://www.cocos.com
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated engine source code (the "Software"), a limited,
worldwide, royalty-free, non-assignable, revocable and non-exclusive license
to use Cocos Creator solely to develop games on your target platforms. You shall
not use Cocos Creator software for developing other software or tools that's
used for developing games. You are not granted to publish, distribute,
sublicense, and/or sell copies of Cocos Creator.
The software or tools in this License Agreement are licensed, not sold.
Xiamen Yaji Software Co., Ltd. reserves all rights not expressly granted to you.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
****************************************************************************/

require('./CCActionManager');
require('./CCAction');
require('./CCActionInterval');
Expand Down
25 changes: 25 additions & 0 deletions cocos2d/animation/animation-animator.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,28 @@
/****************************************************************************
Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
http://www.cocos.com
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated engine source code (the "Software"), a limited,
worldwide, royalty-free, non-assignable, revocable and non-exclusive license
to use Cocos Creator solely to develop games on your target platforms. You shall
not use Cocos Creator software for developing other software or tools that's
used for developing games. You are not granted to publish, distribute,
sublicense, and/or sell copies of Cocos Creator.
The software or tools in this License Agreement are licensed, not sold.
Xiamen Yaji Software Co., Ltd. reserves all rights not expressly granted to you.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
****************************************************************************/

var js = cc.js;
var Playable = require('./playable');
var DynamicAnimCurve = require('./animation-curves').DynamicAnimCurve;
Expand Down
25 changes: 25 additions & 0 deletions cocos2d/animation/animation-clip.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,28 @@
/****************************************************************************
Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
http://www.cocos.com
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated engine source code (the "Software"), a limited,
worldwide, royalty-free, non-assignable, revocable and non-exclusive license
to use Cocos Creator solely to develop games on your target platforms. You shall
not use Cocos Creator software for developing other software or tools that's
used for developing games. You are not granted to publish, distribute,
sublicense, and/or sell copies of Cocos Creator.
The software or tools in this License Agreement are licensed, not sold.
Xiamen Yaji Software Co., Ltd. reserves all rights not expressly granted to you.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
****************************************************************************/


/**
* !#en Class for animation data handling.
Expand Down
25 changes: 25 additions & 0 deletions cocos2d/animation/animation-curves.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,28 @@
/****************************************************************************
Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
http://www.cocos.com
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated engine source code (the "Software"), a limited,
worldwide, royalty-free, non-assignable, revocable and non-exclusive license
to use Cocos Creator solely to develop games on your target platforms. You shall
not use Cocos Creator software for developing other software or tools that's
used for developing games. You are not granted to publish, distribute,
sublicense, and/or sell copies of Cocos Creator.
The software or tools in this License Agreement are licensed, not sold.
Xiamen Yaji Software Co., Ltd. reserves all rights not expressly granted to you.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
****************************************************************************/


var bezierByTime = require('./bezier').bezierByTime;

Expand Down
25 changes: 25 additions & 0 deletions cocos2d/animation/animation-manager.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,28 @@
/****************************************************************************
Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
http://www.cocos.com
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated engine source code (the "Software"), a limited,
worldwide, royalty-free, non-assignable, revocable and non-exclusive license
to use Cocos Creator solely to develop games on your target platforms. You shall
not use Cocos Creator software for developing other software or tools that's
used for developing games. You are not granted to publish, distribute,
sublicense, and/or sell copies of Cocos Creator.
The software or tools in this License Agreement are licensed, not sold.
Xiamen Yaji Software Co., Ltd. reserves all rights not expressly granted to you.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
****************************************************************************/

var js = cc.js;

var AnimationManager = cc.Class({
Expand Down
Loading

0 comments on commit 77febbf

Please sign in to comment.