How to get physically based animation?

Hi everyone,
How can i get something like this: https://www.youtube.com/watch?v=on7wAz0fsGg in BGE?

I’ve been looking for this for a long time.

Search non pid walking ragdoll rig

Or you may wait a few weeks(yeah, sorry that it’s so loong) for my upcoming tutorial series about using neural networks in BGE. I am not still sure if I will show how to make ragdoll’s motion attempt to match animations or make it learn all the movement on it’s own. It will be good for physical movements of characters any way :slight_smile:

I like ai sounds interesting.

Oooh that’s an interesting one : D I’ve been meaning to do the same for quite some time. If I recall correctly, there was a zelda demo on the forums with something similar. I’ll try to look it up.

Edit: Here it is https://blenderartists.org/forum/showthread.php?395780-Procedural-Zelda-(added-grass-simulation)&highlight=zelda+physics

I believe that video is just playing with vectors/points. My guess is he adds the animation movement to the bones that are also rigid bodies. The engine physics should handle most of it for you. I did a ragdoll-to-animation human by linearly interpolating from the rigid body position back to the animation position.

Search non pid ragdoll rig

No, no, no… I know about ragdoll rig. It’s based on animations. You animate bones, than apply on physics body. It will copy bones, but react to environment a little. I am already building a neural network system in Blender. In this case you’ll be able to give a rigid body constraint several goals. For example, have one of bodies at certain distance from others most of time(if you want it to follow specific walking guidelines not learn it’s own way). Than you give it task to learn to move at certain speeds. And computer will learn it itself. Than you save the network node values and have a ready AI-controlled rigid body(but you can give it input yourself to control it). It will be more clear once you see it.

My plans:
-Make this for car AI learning (plus publish it with download)
-Make tutorial series for controllable rigid body character

The problem in this case is - I don’t know how long time it’ll take.

OK! Stay tuned and enjoy blending:)

I implemented procedural animation before but they requires too many hacks and pains to maintain so I had to scrap the idea, would love to see what others were doing with this

try animating the focus, hand, and feet using seperate systems and bones,

you can have 2 ik targets (animation) and (procedural)

start an animation normal and near the end swap to the procedural target
(great for grabbing things)

you need to check orientations / ranges before giving the actor the commands to align etc / play walk / duck / engage IK near end


if own['IKMODE']==True:
    #Switching to Procedural mode
    if armature.constraints['IK_Animation_Right_Hand'].enforce>=.05:
         armature.constraints['IK_Animation_Right_Hand'].enforce-=.05
    else:
         armature.constraints['IK_Animation_Right_Hand'].enforce=0

    if armature.constraints['IK_Procedural_Right_Hand'].enforce<=.95:
         armature.constraints['IK_Procedural_Right_Hand'].enforce+=.05
    else:
         armature.constraints['IK_Procedural_Right_Hand'].enforce=1



else:
    #Switching back to animation mode
    if armature.constraints['IK_Animation_Right_Hand'].enforce<=.95:
        armature.constraints['IK_Animation_Right_Hand'].enforce += .05
    else:
        armature.constraints['IK_Animation_Right_Hand'].enforce=1

    if armature.constraints['IK_Procedural_Right_Hand'].enforce>= .05:
        armature.constraints['IK_Procedural_Right_Hand'].enforce -= .05
    else:
        armature.constraints['IK_Procedural_Right_Hand'].enforce=0


can you link a simple blend file with the code and a pair of bones pls, im interested too
thx

anything new ?

still working on this ?

Makes me wonder if it also implemented reaction forces of one limb on the rest of the body. In the past I have also dabled with ragdolls. Using some control scheme to have the limbs move towards their target using forces. One thing I never got a simple idea for is best ilustrated with following example: say your lying face down on the ground. Then if you push your arms forward you should lift yourself. But a simple implementation of moving the hands harder into the floor will not cause the main body to rise.

we need BTMultiBody implimented from Bullet :smiley: