I'm writing a little picker for Blender. The principle of operation is simple. I select some armatures, go into pose mode. If I select bones, then bones with the same name in other armatures become selected.
import bpy def picker(scene): selected_obj = [obj.name for obj in bpy.context.selected_objects] selected_arm = (bpy.data.armatures[selected_obj]) selected_bones = [bone.name for bone in bpy.context.selected_pose_bones] for bone in selected_arm.bones: if bone.name in selected_bones: bone.select = True bpy.app.handlers.depsgraph_update_post.append(picker)
The script works if you specify the name of the armature, for example:
selected_arm = bpy.data.armatures['Armature.001']
But I don't know how to make it work for any number of armatures with any names.