@galacean/engine-core 1.6.0 → 1.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/main.js +13 -5
- package/dist/main.js.map +1 -1
- package/dist/module.js +13 -5
- package/dist/module.js.map +1 -1
- package/package.json +3 -3
- package/types/Entity.d.ts +1 -0
package/dist/main.js
CHANGED
|
@@ -7744,6 +7744,8 @@ function dependentComponents(componentOrComponents, dependentMode) {
|
|
|
7744
7744
|
rotation._onValueChanged = target._onRotationChanged;
|
|
7745
7745
|
// @ts-ignore
|
|
7746
7746
|
scale._onValueChanged = target._onScaleChanged;
|
|
7747
|
+
// When cloning, other components may obtain properties such as `rotationQuaternion` in the constructor, local related dirty flags need to be corrected
|
|
7748
|
+
target._setDirtyFlagTrue(2 | 64);
|
|
7747
7749
|
};
|
|
7748
7750
|
_proto._onLocalMatrixChanging = function _onLocalMatrixChanging() {
|
|
7749
7751
|
this._setDirtyFlagFalse(64);
|
|
@@ -21951,11 +21953,7 @@ var ComponentCloner = /*#__PURE__*/ function() {
|
|
|
21951
21953
|
], args));
|
|
21952
21954
|
this._components.push(component);
|
|
21953
21955
|
// @todo: temporary solution
|
|
21954
|
-
if (_instanceof(component, Transform))
|
|
21955
|
-
var transform = this._transform;
|
|
21956
|
-
this._transform = component;
|
|
21957
|
-
transform == null ? void 0 : transform.destroy();
|
|
21958
|
-
}
|
|
21956
|
+
if (_instanceof(component, Transform)) this._setTransform(component);
|
|
21959
21957
|
component._setActive(true, ActiveChangeFlag.All);
|
|
21960
21958
|
return component;
|
|
21961
21959
|
};
|
|
@@ -22384,6 +22382,16 @@ var ComponentCloner = /*#__PURE__*/ function() {
|
|
|
22384
22382
|
}
|
|
22385
22383
|
}
|
|
22386
22384
|
};
|
|
22385
|
+
_proto._setTransform = function _setTransform(value) {
|
|
22386
|
+
var _this__transform;
|
|
22387
|
+
(_this__transform = this._transform) == null ? void 0 : _this__transform.destroy();
|
|
22388
|
+
this._transform = value;
|
|
22389
|
+
var children = this._children;
|
|
22390
|
+
for(var i = 0, n = children.length; i < n; i++){
|
|
22391
|
+
var _children_i_transform;
|
|
22392
|
+
(_children_i_transform = children[i].transform) == null ? void 0 : _children_i_transform._parentChange();
|
|
22393
|
+
}
|
|
22394
|
+
};
|
|
22387
22395
|
/**
|
|
22388
22396
|
* @deprecated
|
|
22389
22397
|
*/ _proto.getInvModelMatrix = function getInvModelMatrix() {
|