Rigid body / spring physics for bones

It’s basically feature complete, it’s well tested, and it’s very fast. But it could always use more testing (especially on real world projects).

It’s very safe and robust, but theoretically in very extreme situations it could mess up your bone’s parenting, so make backups of your .blend files!

Also, don’t add any objects into the RigidBodyBones collection, they will be deleted. In fact you just shouldn’t touch the RigidBodyBones collection at all.

Note that you need Blender 2.91.0 or higher, because of a severe bug in earlier versions of Blender.

3 Likes

I released version 1.2:

3 Likes

This addon looks incredible and super complete, I’m just starting to test it but it has a ton of options. Having said that, I had some problems.

  • If you active the bones in something different that frame 1 I think it offsets the position of the bone using the current frame and it just breaks (disabling and enabling rigid body, frame 1, fixes this)

Activating in frame 86

Going back to frame 1

  • If you have auto keyframe activated and no previous keyframes, the first move it’s gonna offset the dynamic bones.

  • Activating bones and pressing ctrl+z crashes blender (Tried it in a default config to see if it was conflicting with other addon)

  • Changing multiple bones to the min amount of weight 0.001 kg and pressing play crashed blender

  • I think the “disable collision” should be renamed to “parent collision” and shape to “shape collision” since at first it looks like the shapes are just guides

  • The default shape setting should be compound or capsule with 0.93 Y scale with rotation springs active since every other shape default setting has overlapping problems and at first glance it feels like the addon is wonky. This is more about first impressions

Those are all my findings for now, thank you very much for the addon it was just what I was looking for.

tested on: blender-2.91.0-02677ec4e0fa-windows64

This is a known bug in Blender:

I believe that is also a bug in Blender. I’ve had Blender crash many times with rigid bodies (even when not using this addon). The crashes seem to be random (but always when hitting Play).

Capsule only supports 2 dimensions, whereas box supports 3. Because “Disable collisions” defaults to true (and it should generally be left at true), there shouldn’t be any overlapping problems.

Why do you think that having springs enabled by default is better?

I’ll look into this.

1 Like

I had a feeling the crashes were gonna be blender side so there is no much to do there.

About the capsule instead of boxes I think the problem that I was having is specific to forked bones, it makes it collide the moment you press play.

The spring comment was in connection to the forked bone since it felt more stable with springs on so nevermind.

If you don’t mind me asking I was wondering if there are plans to implement or if it’s even possible to add subdivided bbone support and scale springs to get, in some instances, a more cartoony result.

Something like this, I used wiggle bones for the tip

Ty

Oh, that makes sense, since “Disable collisions” only applies to the parent, not siblings. So in that case you would have to resize the fork hitboxes so that way they don’t collide. Or you could move them to a different Collection (in Advanced).

I hadn’t thought of that, let me see if it’s possible.

1 Like

After investigating this, it’s not possible, because bbones cannot be changed individually, instead they are completely controlled by Blender.

However, you can achieve the same effect by simply subdividing the bones a few times (using Armature -> Subdivide), and then copying the Rigid Body settings (using Pose -> Rigid Body -> Copy from Active):

As a bonus, this will also work with game engines, since it’s using regular bones.

3 Likes

I released version 1.3:

1 Like

I encountered a small problem.

If there is no Rigid Body World created there is something like a 45 line error in console while changing modes with an armature selected. Creating the rigid world fixes the error.

Also if you get the previous error and delete that armature there is a new error that says it’s impossible to find the armature and the addon doesn’t let you activate the bones anymore.

#second error
Traceback (most recent call last):
  2.91\scripts\addons\Rigid Body Bones\utils.py", line 36, in update
    f(*args)
  2.91\scripts\addons\Rigid Body Bones\events.py", line 126, in next_tick
    utils.select_active(context, dirty.armature)
  2.91\scripts\addons\Rigid Body Bones\utils.py", line 169, in select_active
    obj.select_set(True)
RuntimeError: Error: Object 'Armature' can't be selected because it is not in View Layer 'View Layer'!

The first error is negligible so if you don’t delete any bones before activating the addon or creating a Rigid World it should be fine.

Other than that the addon works amazingly and as you said it saves a ton of time setting up rigs, since it does the heavy lifting you can even connect new constraints to rigid body ends and make puppet like animations. Thanks again!

2 Likes