How to loop thru all bones that are below in hierarchy of a given bone?
loop_thru_descendants.blend (643 KB)
These should be of interest.
nTimes = len(bpy.data.armatures['Armature'].bones[:]) #could be improved to shorten loop length. likely nbd though.
bpy.ops.armature.select_hierarchy(direction='CHILD', extend=False) #Edit mode
bpy.ops.pose.select_hierarchy(direction='CHILD', extend=False) #Pose mode
Haven’t viewed the blend.