diff --git a/CHANGELOG.md b/CHANGELOG.md index 85b3a0e..3e3a461 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +1.6.1 + +- changed: `on select` options using `pin feet` target selected bones instead (wuthout the option only target bones with `foot` in name) + 1.6.0 - added: World space copy/paste from `Pin tool` panel can now copy/paste multiple selected posebones positions diff --git a/OP_expand_cycle_step.py b/OP_expand_cycle_step.py index 898957c..a2eac6a 100644 --- a/OP_expand_cycle_step.py +++ b/OP_expand_cycle_step.py @@ -273,8 +273,11 @@ def pin_down_feets(): if obj.type != 'ARMATURE': print('ERROR', 'active is not an armature type') return + debug = fn.get_addon_prefs().debug + scn = bpy.context.scene + on_selected = scn.anim_cycle_settings.expand_on_selected_bones # Delete current action if its not the main one # create a new '_pinned' one act = fn.set_generated_action(obj) @@ -346,8 +349,8 @@ def pin_down_feets(): b_name = fcu.data_path.split('"')[1] # print('b_name: ', b_name, fcu.is_valid) - ## TEST : only foot bones - if not 'foot' in b_name: + ## if working without selection, target only foot bones. + if not on_selected and not 'foot' in b_name: continue pb = obj.pose.bones.get(b_name) @@ -355,6 +358,10 @@ def pin_down_feets(): print(f'{b_name} is invalid') continue + if on_selected and not pb.bone.select: + # filter selection + continue + contact_ranges = [] start_contact = None prev = None diff --git a/__init__.py b/__init__.py index 5bbb1b9..f3bed84 100644 --- a/__init__.py +++ b/__init__.py @@ -4,7 +4,7 @@ bl_info = { "name": "Auto Walk", "description": "Develop a walk/run cycles along a curve and pin feets", "author": "Samuel Bernou", - "version": (1, 6, 0), + "version": (1, 6, 1), "blender": (3, 0, 0), "location": "View3D", "warning": "",