0
$\begingroup$

I copied one Copy Transform constrain to all my bones accidentally and didn't notice it at the right time. So I need to get rid of it now and it seems I can not just click and delete it for all selected bones. So it seems to me that the scripting should be involved? My constraints didn't have unique names. So on some bones, this one goes like the one and only, on others it is named with .001 or .002. It shares two features though: it goes last in the list and also it has the same Target. So the question is how can I delete this specific constraint without touching others, using scripting?

$\endgroup$

1 Answer 1

0
$\begingroup$

I think this can't be done without scripting. But the script to delete last constraint is easy:

import bpy

for pose_bone in bpy.context.selected_pose_bones:
    if len(pose_bone.constraints):
        pose_bone.constraints.remove(pose_bone.constraints[-1])
$\endgroup$
1
  • $\begingroup$ How to Apply the constraint? Not delete. $\endgroup$ Nov 27, 2022 at 5:19

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .