Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--release/scripts/startup/bl_operators/rigidbody.py11
1 files changed, 6 insertions, 5 deletions
diff --git a/release/scripts/startup/bl_operators/rigidbody.py b/release/scripts/startup/bl_operators/rigidbody.py
index 03dd2c9118a..d334e404a5d 100644
--- a/release/scripts/startup/bl_operators/rigidbody.py
+++ b/release/scripts/startup/bl_operators/rigidbody.py
@@ -190,7 +190,7 @@ class BakeToKeyframes(Operator):
class ConnectRigidBodies(Operator):
- '''Create rigid body constraint between two selected rigid bodies'''
+ '''Create rigid body constraints between selected and active rigid bodies'''
bl_idname = "rigidbody.connect"
bl_label = "Connect Rigid Bodies"
bl_options = {'REGISTER', 'UNDO'}
@@ -237,9 +237,10 @@ class ConnectRigidBodies(Operator):
con.type = self.con_type
con.object1 = obj_act
con.object2 = obj
+ # restore selection
+ bpy.ops.object.select_all(action='DESELECT')
+ for obj in objs:
+ obj.select = True;
+ bpy.context.scene.objects.active = obj_act
return {'FINISHED'}
-
- def invoke(self, context, event):
- wm = context.window_manager
- return wm.invoke_props_dialog(self)