Use WeakDom::into_raw for faster snapshot generation from models

This commit is contained in:
Lucien Greathouse
2022-05-27 18:39:36 -04:00
parent 824cdc5dcd
commit 9767d4d8bd
5 changed files with 29 additions and 32 deletions

View File

@@ -24,7 +24,8 @@ pub fn snapshot_rbxmx(
let children = root_instance.children();
if children.len() == 1 {
let snapshot = InstanceSnapshot::from_tree(&temp_tree, children[0])
let child = children[0];
let snapshot = InstanceSnapshot::from_tree(temp_tree, child)
.name(name)
.metadata(
InstanceMetadata::new()