Duplicating bones with child objects

I’m working on quite a complicated robot model and I’ve finished one of it’s leg which I now need to duplicate. But the problem I’m facing is that I haven’t got a clue how to duplicate the leg without having to re-parent every single part for every leg. So is there a way to do this without having to re-parent every single piece of every single leg?

OK, so the easiest way is to make one leg and one armature for that one leg, then parent everything together, I presume you are using bone parents for a rigid body model like this, anyway it doesn’t matter too much. Then what you do it to select the leg components and the armature and key SHIFT+D and the whole lot is duplicated - move/mirror/rotate the new copies to where you want them. If you only have two legs, you can then join the two armatures together by electing first in Object Mode, the nSHIFT+Select other and key CTRL+J and the armature will join. Simples!

There may be other methods, but this is what I do.

Cheers, Clock.

Thanks for your help but when I try to join the two armatures the pieces from the duplicated leg jump to where the originals are and get parented to the original bones.

That’s weird, it works for me - make sure you do the duplication all in one operation with the armatures in Object Mode before you duplicate them.

Cheers, Clock.

That’s what I did. And everything works fine before I join them.

I just renamed one of the bones before joining which fixed the problem for that bone. But this would mean that I would have to rename every single bone. And I’m also quite sure that you didn’t rename any bones. So does anyone know whats going on here and how to fix it?

Ok so I found out what I do without even thinking about it… When you move an armature you should apply the Location after you move it. So select the duplicate armature in Object mode and key CTRL+A => “Location” - make sure you apply location to an armature ALL the time unless you can think of a very good reason why not to. You should also apply rotation and scale - never scale an armature in Object mode without applying the scale, same applies for rotation. I have just done this again and time after time it always works for me. You should always create armatures with their origin points at 0,0,0 - others may disagree - I have never had issues doing this.

Cheers, Clock.

Nope did that too.

I give up - post the blend file please and I’ll look at it. if its big cut it down to a piece that shows the problem and post it at pasteall.org/blend then post the URL here.

Cheers, Clock.

Your link doesn’t work for me but here’s a cut down blend file.
recon_r (copy).blend (2.78 MB)

That’s because there was a typo in there… D’Oh - OK I will look at your file.

Cheers, Clock.

OK - there are unapplied rotations scales and all sorts in your file on the meshes - too much for me to try to sort out tonight. Also there are loads of IK constraints with other constraints on the same bones, this does not work too well. I need some time to sort all this out.

Cheers, Clock.

I’ll keep trying things as well. Thanks a lot for your help.

I’ll take a look Clock. Have it figured for the most part.

OK, sorry. Too many issues here to tackle in any short amount of time. I’ll leave it to Clockmender.

Naming, cyclic dependencies, bone layer organizing, shoulder rig is not right, etc, etc. All of these need to be addressed before duplication and flipping can be done.

Sorry. Good luck!

Took another quick shot at it. I renamed a few bones, added new targets for the pistons (Shoulders and arms only. I’ll leave the hands for you. :wink: ), moved all bones to the right (x -1) auto named the bones .R, symmetrized the right side bones to create left side, flipped the axes on some IK limits for the left side.

You should be able to take it from here. http://pasteall.org/blend/index.php?id=44629

Good luck!

Thanks a lot, I’ve had quite a bit of trouble rigging this model and everything works a lot better with your changes. But I don’t really see what these things, besides maybe the auto-naming, have to do with the duplication problem.

All our techniques have consequences down the line, errors in technique might not show problems until you start to animate for example, but they WILL cause problems somewhere, somehow.

I also don’t have enough time to correct all the problems, sorry, but I have other things to do. All I seem to be doing is “chasing my tail” - correct one thing and it causes another issue, for example if you parent an object to a bone using a “bone” parent, and the object has unapplied rotation or scales, when you apply these it twists and jumps off somewhere…

So you have two choices I think:

  1. Leave things as they are and just duplicate the armatures and don’t try to join them - this will “sort of” work, but may lead to the problems down the line and will not teach you better technique. There is not rule that says you can only have one armature in a project file.

  2. Start over again only this time watch the following:

a) Create your armature first and name the bones so they have meaning and are Left/Right symmetrised (Is that a word even?). It is good practice, but not essential, to have the Armature origins at 0,0,0.

b) Avoid Cyclic dependencies - so one bone may have a IK constraint with a second bone as the target, which in turn is parented to the first bone or has a constraint route back to the first bone - this is a Cyclic Dependency and will cause issues. You should always be able to move or rotate a bone - say with a R command and move it a little with the cursor but don’t make the final Click, then press Escape key and the Rig should return to rest pose, if it doesn’t you have an error, which will also show in the Console window.

c) Do ALL editing of your Meshes and Armatures in EDIT Mode NOT Object Mode. Note I emphasise this a lot for a very good reason - problems will ensue when it comes to duplicating, parenting, mirroring, animating, etc. etc. So say you want to scale an object by a factor of two in Z axis; Set the 3D cursor to the object origin (Key SHIFT+S “Cursor to Selected”), Chose 3D cursor mode from the menu at the bottom of the 3D View, Tab to Edit Mode, Select All vertices (Key A once or twice till they all are selected), Key S Z 2 Return - Tab out of Edit Mode, This object will then not cause you any problems down the line. Same applies if you want to rotate the whole thing, either do it in EDIT mode - good practice to get into, or if you do it in Object Mode - Apply the rotation immediately afterwards - Key CTRL+A => “Rotation”.

d) if you are doing hard object modelling, like a robot that does not have pieces that need to deform, make each part and then parent the part to the Armature immediately - (Select Object, SHIFT Select Bone in Armature. key CTRL+P => “Bone”). If you need to duplicate an object so you have one either side for example, duplicate first then parent each bit to its bone. If you mirror an object - Tab into Edit mode, select all vertices and key CTRL+N to normalise them again, so you don’t get shading errors.

Look at my Meccano project in the WIP https://blenderartists.org/forum/showthread.php?409040-Meccano-Project&p=3127906#post3127906- there are over 3,000 parts all “bone” parented to various armatures, this would be a nightmare if I did not parent them as I go - I even add more bones to the armatures if I decide an extra one is needed.

Sorry I cant be more help and maybe I sound a little “School master-ish”, but I think this will help you in the future and make life a whole lot less frustrating.

Keep up the good work!

Cheers, Clock.

PS. Sorry for any typos - I am in a hurry today!

I won’t be starting over because I’ve made too much progress and I’ll probably lose to much motivation by starting over. But I’ll definitely keep your tips in mind.

Interestingly the duplication seems to work if I rename the bones so I’ll just auto name them and that should fix the problem, that way I don’t have to have different armatures for every limb. I’ll also remove all of the cyclic dependencies and I’ll fix some other issues as well.

Thanks a lot everyone and next time I’ll do everything right from the start. :slight_smile:

I have your solution, but it would take too long to write all the steps. If you are willing, I could record the fixes and put the tutorial on my youtube channel. I’d like your permission before I do that.