Merge branch 'v1.2' of github.com:cocos-creator/engine into v1.2

This commit is contained in:
Nan Wang
2016-08-12 11:14:17 +08:00
3 changed files with 8 additions and 8 deletions
+1 -1
View File
@@ -400,7 +400,7 @@ cc.js.getset(CollisionManager.prototype, 'enabledDebugDraw',
}
else if (!value && this._enabledDebugDraw) {
this._debugDrawer.clear();
cc.director.getScene()._sgNode.removeChild(this._debugDrawer);
this._debugDrawer.removeFromParent(false);
cc.director.off(cc.Director.EVENT_AFTER_SCENE_LAUNCH, this.onSceneLaunched, this);
}
+6 -7
View File
@@ -166,17 +166,16 @@ var Animation = cc.Class({
}
},
__preload: function () {
if (CC_EDITOR || !this.enabled) return;
onEnable: function () {
if (!CC_EDITOR && this.playOnLoad && this._defaultClip) {
this.playOnLoad = false;
if (this.playOnLoad && this._defaultClip) {
var state = this.getAnimationState(this._defaultClip.name);
this._animator.playState(state);
}
},
onEnable: function () {
this.resume();
else {
this.resume();
}
},
onDisable: function () {
+1
View File
@@ -348,6 +348,7 @@ var actionUpdate = {
'JumpTo': syncPositionUpdate,
'JumpBy': syncPositionUpdate,
'Place': syncPositionUpdate,
'CardinalSplineTo': syncPositionUpdate,
'RotateTo': syncRotationUpdate,
'RotateBy': syncRotationUpdate,
'ScaleTo': syncScaleUpdate,