mirror of
https://github.com/rojo-rbx/rojo.git
synced 2026-10-22 04:51:47 +00:00
Mark project node as instigating source for instances from project
This commit is contained in:
parent
c051153a1f
commit
cb3211cf46
3 changed files with 22 additions and 1 deletions
|
|
@ -6,7 +6,7 @@ use rbx_reflection::try_resolve_value;
|
||||||
use crate::{
|
use crate::{
|
||||||
imfs::{FsErrorKind, Imfs, ImfsEntry, ImfsFetcher},
|
imfs::{FsErrorKind, Imfs, ImfsEntry, ImfsFetcher},
|
||||||
project::{Project, ProjectNode},
|
project::{Project, ProjectNode},
|
||||||
snapshot::{InstanceMetadata, InstanceSnapshot},
|
snapshot::{InstanceMetadata, InstanceSnapshot, InstigatingSource},
|
||||||
};
|
};
|
||||||
|
|
||||||
use super::{
|
use super::{
|
||||||
|
|
@ -174,6 +174,11 @@ fn snapshot_project_node<F: ImfsFetcher>(
|
||||||
metadata.ignore_unknown_instances = true;
|
metadata.ignore_unknown_instances = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
metadata.instigating_source = Some(InstigatingSource::ProjectNode(
|
||||||
|
instance_name.to_string(),
|
||||||
|
node.clone(),
|
||||||
|
));
|
||||||
|
|
||||||
Ok(Some(InstanceSnapshot {
|
Ok(Some(InstanceSnapshot {
|
||||||
snapshot_id: None,
|
snapshot_id: None,
|
||||||
name,
|
name,
|
||||||
|
|
|
||||||
|
|
@ -16,6 +16,14 @@ children:
|
||||||
- snapshot_id: ~
|
- snapshot_id: ~
|
||||||
metadata:
|
metadata:
|
||||||
ignore_unknown_instances: true
|
ignore_unknown_instances: true
|
||||||
|
instigating_source:
|
||||||
|
ProjectNode:
|
||||||
|
- Child
|
||||||
|
- class_name: Model
|
||||||
|
children: {}
|
||||||
|
properties: {}
|
||||||
|
ignore_unknown_instances: ~
|
||||||
|
path: ~
|
||||||
relevant_paths: []
|
relevant_paths: []
|
||||||
name: Child
|
name: Child
|
||||||
class_name: Model
|
class_name: Model
|
||||||
|
|
|
||||||
|
|
@ -17,6 +17,14 @@ children:
|
||||||
- snapshot_id: ~
|
- snapshot_id: ~
|
||||||
metadata:
|
metadata:
|
||||||
ignore_unknown_instances: true
|
ignore_unknown_instances: true
|
||||||
|
instigating_source:
|
||||||
|
ProjectNode:
|
||||||
|
- SomeChild
|
||||||
|
- class_name: Model
|
||||||
|
children: {}
|
||||||
|
properties: {}
|
||||||
|
ignore_unknown_instances: ~
|
||||||
|
path: ~
|
||||||
relevant_paths: []
|
relevant_paths: []
|
||||||
name: SomeChild
|
name: SomeChild
|
||||||
class_name: Model
|
class_name: Model
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue