Skip to content

Conversation

@Squareys
Copy link
Collaborator

Also enables sourcemaps for better stack traces.

Signed-off-by: Squareys <squareys@googlemail.com>
Signed-off-by: Squareys <squareys@googlemail.com>
vrm.ts Outdated
const {root, extensions} = this.engine.scene.instantiate(prefab);
root!.children.forEach((child) => (child.parent = this.object));
this._initializeVrm(prefab.extensions, extensions?.idMapping!);
root!.destroy();
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To avoid making too much changes in a row, this is fine to keep. However, I am pretty confident with the new system we can actually circumvent this in a nicer way.

We could use the gltf.extensions to do the changes directly on the prefab itself, since the original mapping works on that. Then instantiate the prefab in onActivate, and delete the objects in onDeactivate

Signed-off-by: Squareys <squareys@googlemail.com>
@Squareys Squareys merged commit 8f83bdd into main Mar 16, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants