mirror of
https://github.com/cocos/cocos4.git
synced 2026-11-21 16:12:40 +08:00
Merge branch 'v1.2' of github.com:cocos-creator/engine into v1.2
This commit is contained in:
@@ -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);
|
||||
}
|
||||
|
||||
|
||||
@@ -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 () {
|
||||
|
||||
@@ -348,6 +348,7 @@ var actionUpdate = {
|
||||
'JumpTo': syncPositionUpdate,
|
||||
'JumpBy': syncPositionUpdate,
|
||||
'Place': syncPositionUpdate,
|
||||
'CardinalSplineTo': syncPositionUpdate,
|
||||
'RotateTo': syncRotationUpdate,
|
||||
'RotateBy': syncRotationUpdate,
|
||||
'ScaleTo': syncScaleUpdate,
|
||||
|
||||
Reference in New Issue
Block a user