This commit is contained in:
1 parent
1ab3886028
commit
c55f34780f
4 files changed
+58
-13
No files matched your search
@@ -198,7 +198,20 @@ fn spawn_snapshot_with_parent(
|
||||
snapshot: &EditorEntitySnapshot,
|
||||
parent: Option<Entity>,
|
||||
) -> Entity {
|
||||
let mut entity_mut = world.spawn((LevelObject, snapshot.actor_kind, snapshot.transform));
|
||||
let visibility = if snapshot.editor_visibility.visible {
|
||||
Visibility::Visible
|
||||
} else {
|
||||
Visibility::Hidden
|
||||
};
|
||||
let mut entity_mut = world.spawn((
|
||||
LevelObject,
|
||||
snapshot.actor_kind,
|
||||
snapshot.transform,
|
||||
snapshot.editor_visibility,
|
||||
visibility,
|
||||
InheritedVisibility::default(),
|
||||
ViewVisibility::default(),
|
||||
));
|
||||
entity_mut.insert(
|
||||
snapshot
|
||||
.actor_id
|
||||
@@ -291,7 +304,6 @@ fn spawn_snapshot_with_parent(
|
||||
entity_mut.insert(link.clone());
|
||||
}
|
||||
entity_mut.insert(HierarchySiblingIndex(snapshot.hierarchy_sibling_index));
|
||||
entity_mut.insert(snapshot.editor_visibility);
|
||||
if let Some(order) = &snapshot.inspector_order {
|
||||
entity_mut.insert(order.clone());
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user