diff options
author | Bastien Montagne <bastien@blender.org> | 2020-06-10 20:44:59 +0300 |
---|---|---|
committer | Bastien Montagne <bastien@blender.org> | 2020-06-10 20:45:52 +0300 |
commit | 0621c13b3e60284e0116c4c3aeb11b175f903d52 (patch) | |
tree | 61b46be55a5bf10a9c123018108d14f2fc2b3285 /source/blender/blenkernel/intern/collection.c | |
parent | 14bd92b12f0fa2382c7157ebc00f7adb644c2e85 (diff) |
Add proper handling of liboverrides to Scene deep copy.
Followup to rB74ec37b70cbc8dc2, also missed a case in collection
deepcopy then.
Diffstat (limited to 'source/blender/blenkernel/intern/collection.c')
-rw-r--r-- | source/blender/blenkernel/intern/collection.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/collection.c b/source/blender/blenkernel/intern/collection.c index 675e86b1584..290b181f172 100644 --- a/source/blender/blenkernel/intern/collection.c +++ b/source/blender/blenkernel/intern/collection.c @@ -389,6 +389,10 @@ static Collection *collection_duplicate_recursive(Main *bmain, LISTBASE_FOREACH_MUTABLE (CollectionChild *, child, &collection_old->children) { Collection *child_collection_old = child->collection; + if (is_collection_liboverride && ID_IS_LINKED(child_collection_old)) { + continue; + } + collection_duplicate_recursive( bmain, collection_new, child_collection_old, do_hierarchy, do_objects, do_obdata); collection_child_remove(collection_new, child_collection_old); |