From db34f2884f1a6dd52165b504f3d1bef7677b7553 Mon Sep 17 00:00:00 2001 From: Knox Date: Mon, 20 May 2019 17:51:35 +0800 Subject: [PATCH] fix instantiate prefab scale error (#4454) --- cocos2d/core/CCNode.js | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/cocos2d/core/CCNode.js b/cocos2d/core/CCNode.js index b67b0fd492b..500c67818a5 100644 --- a/cocos2d/core/CCNode.js +++ b/cocos2d/core/CCNode.js @@ -560,7 +560,7 @@ var Node = cc.Class({ default: undefined, type: cc.Float }, - _scale: cc.Vec3, + _scale: cc.v3(1, 1, 1), _rotationX: 0.0, _rotationY: 0.0, _quat: cc.Quat, @@ -1150,11 +1150,6 @@ var Node = cc.Class({ // Mouse event listener this._mouseListener = null; - // default scale - this._scale.x = 1; - this._scale.y = 1; - this._scale.z = 1; - this._matrix = mathPools.mat4.get(); this._worldMatrix = mathPools.mat4.get(); this._localMatDirty = LocalDirtyFlag.ALL;