Search Unity

  1. We are migrating the Unity Forums to Unity Discussions. On July 12, the Unity Forums will become read-only.

    Please, do not make any changes to your username or email addresses at during this transition time.

    It's still possible to reply to existing private message conversations during the migration, but any new replies you post will be missing after the main migration is complete. We'll do our best to migrate these messages in a follow-up step.

    On July 15, Unity Discussions will become read-only until July 18, when the new design and the migrated forum contents will go live.

    Read our full announcement for more information and let us know if you have any questions.

Animation [WIP] How we made our active ragdolls somewhat convincing

Discussion in 'Projects In Progress' started by AiKodex, Jul 14, 2021.

  1. AiKodex


    Jan 21, 2021
    Ragdolls need a mind of their own to look real and dropping them limp and lifeless on the slightest nudge to a Capsule Collider on a RigidBody looks far from real. Running over people, crashing a motorcycle, pushing NPCs off a ledge or jumping over a flight of stairs to see if the game has fall damage might seem like a grim thought at first, but in reality, these actions test the depth of a game.

    Ragdoll Update.png

    An obvious answer to increase intractability of a game would be to use more animations for tasks like picking up objects from the ground, or dancing on the street for fun. This may work for thought based movement, but adding more raw animations for a physics based movement just won't cut it. Frankly, animators cannot animate tens of hundreds of motions depending on where the character was hit last and the subsequent hits in that combination. Moreover, having animation scripts running for thousands of lines calling the Animator.Play() method does not seem like an appealing idea for the programmers either.

    This is where active ragdolls shine! These procedurally generated animations automate the painstakingly difficult task of trying to animate every muscle. Take a look at what blend trees, parameter based variables and randomized algorithms can generate :

    These movements have been put together by mimicking a series of animations loosely while maintaining the physicality of a ragdoll put together by joints. Inspired by a GDC Talk - Animation Bootcamp: An Indie Approach to Procedural Animation where David Rosen explains the usage of simple procedural techniques to achieve interactive and fluid animations amazes us. We have tried replicating the pointers in our asset - Simple Motorcycle Physics and this has given us a convincing outcome.

    However, the concept of active ragdolls is certainly not novel and companies like Natural Motions have already collaborated with Rockstar games to make an AI based engine for their characters - Euphoria engine. The interactive ragdoll simulations look as if mocap data was being projected through a screen. This realism comes at an extremely steep cost, deep embeddedness in game systems and generally a restricted proprietary code base integrated on the discretion of Natural Motions.

    In traditional ragdolls, movements sometimes jitter and lag, or limbs get caught in terrain shaking violently on the floor or stretch out and separate. Although there are a few drawbacks with the current PhysX based model with inaccuracies in joint projections and dislocations occasionally, the simulation comes along nicely if the project settings are tweaked properly. If the initial velocities are clamped correctly, most of the projection problems and physics solver having to over work can be solved. Moreover, the range of physical animations not using specified AI but a general set of animations could in theory be expanded to quadruped or even multiped skeletons.

    Both the simulation types can come really close because the basic biped kinematic design is shared. On the left of these comparison images below, we have the AI mediated Euphoria Physics Ragdolls, and on the right, we have blend trees, parameter controlled randomized algorithm ragdoll physics. Even though self preservation, up righting, and spatial awareness is missing from the latter, by tweaking the probabilities of the blended animations, we can imitate the aforementioned features.





    We are glad to share the results and looking forward to queries, suggestions, and are hoping to see more games use these nifty active ragdolls to drastically increase the intractability of their games.
    Last edited: Jul 14, 2021
  2. Evans6


    Nov 10, 2018
    Hello, can the scenes in the second video also be included in the package, please
  3. bvonline


    Feb 27, 2021
    Is there a demo? Would like to test it.
  4. zhaozony


    Jan 7, 2020
    I heard that hellish quart use Active Ragdoll. How does it work? Is there a demo?
  5. Malzatron


    Jul 23, 2023
    Would this work like it does in Max Payne 3? It's hard to tell if they are ragdolls the entire time, or if they just activate when off balance.
  6. S_Bhatti


    Mar 6, 2023
    I am using Simple Motorcycle physics pro, when I build an apk of demo project, ragdoll behaves so weird.
    can you please suggest a solution. here is the reference image

    Attached Files: