Skip to content

Commit

Permalink
Fix clone entity not loading new model because of mixin and inherited…
Browse files Browse the repository at this point in the history
… gltf-model (fix aframevr#689)
  • Loading branch information
vincentfretin committed Jul 23, 2023
1 parent 72fd461 commit 4bdfd69
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib/entity.js
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ function insertAfter(newNode, referenceNode) {
export function cloneEntity(entity) {
entity.flushToDOM();

const clone = entity.cloneNode(true);
const clone = prepareForSerialization(entity);
clone.addEventListener('loaded', function () {
AFRAME.INSPECTOR.selectEntity(clone);
Events.emit('entityclone');
Expand Down

0 comments on commit 4bdfd69

Please sign in to comment.