Skip to content

Commit

Permalink
fix: the layer is not cloned when the node is cloned (#1636)
Browse files Browse the repository at this point in the history
  • Loading branch information
cptbtptpbcptdtptp authored Jul 7, 2023
1 parent 97ab014 commit 50a68c3
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions packages/core/src/Entity.ts
Original file line number Diff line number Diff line change
Expand Up @@ -358,6 +358,7 @@ export class Entity extends EngineObject {
cloneEntity._hookResource = hookResource;
hookResource._addReferCount(1);
}
cloneEntity.layer = this.layer;
cloneEntity._isActive = this._isActive;
cloneEntity.transform.localMatrix = this.transform.localMatrix;

Expand Down

0 comments on commit 50a68c3

Please sign in to comment.