cocos-engine icon indicating copy to clipboard operation
cocos-engine copied to clipboard

node.worldScale has faulty logic

Open xianyinchen opened this issue 3 years ago • 2 comments

Cocos Creator version

3.6.0

System information

Chrome

Issue description

Set the world scale and print it, then get a different value? That's weird.

this.child.worldScale = new Vec3(1, 1, 1);
console.log(this.child.worldScale);

Relevant error log output

No response

Steps to reproduce

Reproduce project, press key 'A' on PC Chrome. NewProject.zip

Minimal reproduction project

No response

xianyinchen avatar Sep 22 '22 11:09 xianyinchen

This function is normal. After setting worldscale, the transform will change, and the final value obtained will change with the transform

bofeng-song avatar Sep 23 '22 03:09 bofeng-song

Cocos engine: update scale at the api of updateWorldTransform

bofeng-song avatar Sep 23 '22 03:09 bofeng-song