Skip to content
Snippets Groups Projects
Commit 3e9408cb authored by Campbell Barton's avatar Campbell Barton
Browse files

missed this in last commit

parent e6e82736
No related branches found
No related tags found
No related merge requests found
...@@ -447,20 +447,17 @@ class add_corrective_pose_shape_fast(bpy.types.Operator): ...@@ -447,20 +447,17 @@ class add_corrective_pose_shape_fast(bpy.types.Operator):
return context.active_object != None return context.active_object != None
def execute(self, context): def execute(self, context):
if len(context.selected_objects) > 2:
print("Select source and target objects please")
return {'FINISHED'}
selection = context.selected_objects selection = context.selected_objects
if len(selection) != 2:
self.report({'ERROR'}, "Select source and target objects")
return {'CANCELLED'}
target = context.active_object target = context.active_object
if context.active_object == selection[0]: if context.active_object == selection[0]:
source = selection[1] source = selection[1]
else: else:
source = selection[0] source = selection[0]
print(source)
print(target)
func_add_corrective_pose_shape_fast( source, target) func_add_corrective_pose_shape_fast( source, target)
return {'FINISHED'} return {'FINISHED'}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment