diff options
author | Bastien Montagne <mont29> | 2022-08-25 18:21:39 +0300 |
---|---|---|
committer | Bastien Montagne <bastien@blender.org> | 2022-08-25 18:21:39 +0300 |
commit | 500d815478966de6ad509c2e6a73c61fce8513a5 (patch) | |
tree | 32cfbf558ce022a6f37ef01ac658d76c936c5e5d /source/blender/editors/physics | |
parent | b27856f12e35b23b5e30443e2647ac76234c2fa7 (diff) |
Fix T100255: Make RigidBodyWorld (and effector_weights) collections refcounted.
Those collections were so far mainly just tagged as fake user (even
though a few places in code already incremented usercount on them).
Since we now clear the fakeuser flag when linking/appending data, ensure
that these collections are preserved by making these usages regular ID
refcounting ones.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D15783
Diffstat (limited to 'source/blender/editors/physics')
-rw-r--r-- | source/blender/editors/physics/rigidbody_constraint.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/editors/physics/rigidbody_constraint.c b/source/blender/editors/physics/rigidbody_constraint.c index 66ae2d323fd..b7c82c18433 100644 --- a/source/blender/editors/physics/rigidbody_constraint.c +++ b/source/blender/editors/physics/rigidbody_constraint.c @@ -88,7 +88,7 @@ bool ED_rigidbody_constraint_add( /* create constraint group if it doesn't already exits */ if (rbw->constraints == NULL) { rbw->constraints = BKE_collection_add(bmain, NULL, "RigidBodyConstraints"); - id_fake_user_set(&rbw->constraints->id); + id_us_plus(&rbw->constraints->id); } /* make rigidbody constraint settings */ ob->rigidbody_constraint = BKE_rigidbody_create_constraint(scene, ob, type); |