diff options
author | Bastien Montagne <bastien@blender.org> | 2021-11-19 13:48:25 +0300 |
---|---|---|
committer | Bastien Montagne <bastien@blender.org> | 2021-11-19 14:09:28 +0300 |
commit | 83e245023c481aa2f57588724915e554c00c05d2 (patch) | |
tree | 2c26c51aebd12ffb4e99f853e492114be2b81e9b /source/blender/makesrna/intern | |
parent | de3fda29c79f143d0bc251ded5bcbf4613417247 (diff) |
Fix (unreported) wrong behavior of constraints in liboverrides.
All constraints were 'made local', including the ones comming from the
reference linked object.
Diffstat (limited to 'source/blender/makesrna/intern')
-rw-r--r-- | source/blender/makesrna/intern/rna_object.c | 1 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_pose.c | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/makesrna/intern/rna_object.c b/source/blender/makesrna/intern/rna_object.c index 99865078cbe..bf64196c8ab 100644 --- a/source/blender/makesrna/intern/rna_object.c +++ b/source/blender/makesrna/intern/rna_object.c @@ -1673,6 +1673,7 @@ static bConstraint *rna_Object_constraints_copy(Object *object, Main *bmain, Poi { bConstraint *con = con_ptr->data; bConstraint *new_con = BKE_constraint_copy_for_object(object, con); + new_con->flag |= CONSTRAINT_OVERRIDE_LIBRARY_LOCAL; ED_object_constraint_tag_update(bmain, object, new_con); WM_main_add_notifier(NC_OBJECT | ND_CONSTRAINT | NA_ADDED, object); diff --git a/source/blender/makesrna/intern/rna_pose.c b/source/blender/makesrna/intern/rna_pose.c index ee509fa92d4..cdf7fe5a7aa 100644 --- a/source/blender/makesrna/intern/rna_pose.c +++ b/source/blender/makesrna/intern/rna_pose.c @@ -650,6 +650,7 @@ static bConstraint *rna_PoseChannel_constraints_copy(ID *id, Object *ob = (Object *)id; bConstraint *con = con_ptr->data; bConstraint *new_con = BKE_constraint_copy_for_pose(ob, pchan, con); + new_con->flag |= CONSTRAINT_OVERRIDE_LIBRARY_LOCAL; ED_object_constraint_dependency_tag_update(bmain, ob, new_con); WM_main_add_notifier(NC_OBJECT | ND_CONSTRAINT | NA_ADDED, id); |