diff options
author | Nathan Vegdahl <cessen@cessen.com> | 2013-02-15 19:30:45 +0400 |
---|---|---|
committer | Nathan Vegdahl <cessen@cessen.com> | 2013-02-15 19:30:45 +0400 |
commit | 3bd86cdc5ac8cc6acb462e36e729929052d4c1ad (patch) | |
tree | 31eeba6d5f20b5e4b9ada2a21aa9a265530c1eb3 | |
parent | a2b35fb7cca524a9027db863f00fe90d7c15c04f (diff) |
Rigify bugfix: deleted WGT objects now get properly replaced on generation.
WGT objects were sticking around even when the user deleted them
since they were being used by the bones for visual appearance. This
meant that if the user deleted the WGT objects in order for Rigify
to regenerate them the next time around, Rigify would fail.
Rigify now checks for this circumstance and handles it appropriately.
-rw-r--r-- | rigify/utils.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/rigify/utils.py b/rigify/utils.py index db66da63..379e1ea1 100644 --- a/rigify/utils.py +++ b/rigify/utils.py @@ -281,6 +281,7 @@ def create_widget(rig, bone_name, bone_transform_name=None): # This is necessary so we can then create the object without # name conflicts. if obj_name in bpy.data.objects: + bpy.data.objects[obj_name].user_clear() bpy.data.objects.remove(bpy.data.objects[obj_name]) # Create mesh object |