Use this class to pilot a ragdoll on a character that is usually driven by an animator and have it fall elegantly If you have parts of your ragdoll that you don't want to be affected by this script (a weapon for example), just add a MMRagdollerIgnore component to them.  
 More...
Inherits MonoBehaviour.
|  | 
| virtual void | ForceRigidbodiesToSleep () | 
|  | Forces all rigidbodies in the ragdoll to sleep. 
 | 
| Vector3 | GetPosition () | 
|  | Returns the current position of the ragdoll (technically the hips position) 
 | 
|  | 
| virtual void | Start () | 
|  | On start we initialize our ragdoller. 
 | 
| virtual void | Initialization () | 
|  | Grabs rigidbodies, adds body parts and stores the animator. 
 | 
| virtual void | RegisterAnimatorParameters () | 
|  | Registers our animation parameters. 
 | 
| virtual void | SetIsKinematic (bool isKinematic) | 
|  | Sets all rigidbodies in the ragdoll to kinematic and stops them from detecting collisions (or the other way around) 
 | 
| virtual void | LateUpdate () | 
|  | On late update, we force our ragdoll elements to sleep and handle blending. 
 | 
| virtual void | HandleBlending () | 
|  | Blends between ragdolling and animated and switches to Animated at the end. 
 | 
| Vector3 | GetRootPosition () | 
|  | Returns the offset root position. 
 | 
|  | 
| bool | Ragdolling  [get, set] | 
|  | Use this to get the current state of the ragdoll or to set a new one. 
 | 
Use this class to pilot a ragdoll on a character that is usually driven by an animator and have it fall elegantly If you have parts of your ragdoll that you don't want to be affected by this script (a weapon for example), just add a MMRagdollerIgnore component to them. 
◆ RagdollStates
The possible states of the ragdoll : 
- animated : driven by an animator controller, rigidbodies asleep
- ragdolling : full ragdoll mode, purely physics driven
- blending : transitioning between ragdolling and animated 
| Enumerator | 
|---|
| Animated |  | 
| Ragdolling |  | 
| Blending |  | 
 
 
◆ ForceRigidbodiesToSleep()
  
  | 
        
          | virtual void MoreMountains.Tools.MMRagdoller.ForceRigidbodiesToSleep | ( |  | ) |  |  | virtual | 
 
Forces all rigidbodies in the ragdoll to sleep. 
 
 
◆ GetPosition()
      
        
          | Vector3 MoreMountains.Tools.MMRagdoller.GetPosition | ( |  | ) |  | 
      
 
Returns the current position of the ragdoll (technically the hips position) 
- Returns
 
 
◆ GetRootPosition()
  
  | 
        
          | Vector3 MoreMountains.Tools.MMRagdoller.GetRootPosition | ( |  | ) |  |  | protected | 
 
Returns the offset root position. 
- Returns
 
 
◆ HandleBlending()
  
  | 
        
          | virtual void MoreMountains.Tools.MMRagdoller.HandleBlending | ( |  | ) |  |  | protectedvirtual | 
 
Blends between ragdolling and animated and switches to Animated at the end. 
 
 
◆ Initialization()
  
  | 
        
          | virtual void MoreMountains.Tools.MMRagdoller.Initialization | ( |  | ) |  |  | protectedvirtual | 
 
Grabs rigidbodies, adds body parts and stores the animator. 
 
 
◆ LateUpdate()
  
  | 
        
          | virtual void MoreMountains.Tools.MMRagdoller.LateUpdate | ( |  | ) |  |  | protectedvirtual | 
 
On late update, we force our ragdoll elements to sleep and handle blending. 
 
 
◆ RegisterAnimatorParameters()
  
  | 
        
          | virtual void MoreMountains.Tools.MMRagdoller.RegisterAnimatorParameters | ( |  | ) |  |  | protectedvirtual | 
 
Registers our animation parameters. 
 
 
◆ SetIsKinematic()
  
  | 
        
          | virtual void MoreMountains.Tools.MMRagdoller.SetIsKinematic | ( | bool | isKinematic | ) |  |  | protectedvirtual | 
 
Sets all rigidbodies in the ragdoll to kinematic and stops them from detecting collisions (or the other way around) 
- Parameters
- 
  
  
 
 
◆ Start()
  
  | 
        
          | virtual void MoreMountains.Tools.MMRagdoller.Start | ( |  | ) |  |  | protectedvirtual | 
 
On start we initialize our ragdoller. 
 
 
◆ _animator
  
  | 
        
          | Animator MoreMountains.Tools.MMRagdoller._animator |  | protected | 
 
 
◆ _animatorParameters
  
  | 
        
          | HashSet<int> MoreMountains.Tools.MMRagdoller._animatorParameters |  | protected | 
 
 
◆ _bodyparts
◆ _getUpFromBackAnimationParameter
  
  | 
        
          | int MoreMountains.Tools.MMRagdoller._getUpFromBackAnimationParameter |  | protected | 
 
 
◆ _getUpFromBackAnimationParameterName
  
  | 
        
          | const string MoreMountains.Tools.MMRagdoller._getUpFromBackAnimationParameterName = "GetUpFromBack" |  | staticprotected | 
 
 
◆ _getUpFromBellyAnimationParameter
  
  | 
        
          | int MoreMountains.Tools.MMRagdoller._getUpFromBellyAnimationParameter |  | protected | 
 
 
◆ _getUpFromBellyAnimationParameterName
  
  | 
        
          | const string MoreMountains.Tools.MMRagdoller._getUpFromBellyAnimationParameterName = "GetUpFromBelly" |  | staticprotected | 
 
 
◆ _initialized
  
  | 
        
          | bool MoreMountains.Tools.MMRagdoller._initialized = false |  | protected | 
 
 
◆ _mecanimToGetUpTransitionTime
  
  | 
        
          | float MoreMountains.Tools.MMRagdoller._mecanimToGetUpTransitionTime = 0.05f |  | protected | 
 
 
◆ _ragdolledFeetPosition
  
  | 
        
          | Vector3 MoreMountains.Tools.MMRagdoller._ragdolledFeetPosition |  | protected | 
 
 
◆ _ragdolledHeadPosition
  
  | 
        
          | Vector3 MoreMountains.Tools.MMRagdoller._ragdolledHeadPosition |  | protected | 
 
 
◆ _ragdolledHipPosition
  
  | 
        
          | Vector3 MoreMountains.Tools.MMRagdoller._ragdolledHipPosition |  | protected | 
 
 
◆ _ragdollingEndTimestamp
  
  | 
        
          | float MoreMountains.Tools.MMRagdoller._ragdollingEndTimestamp = -float.MaxValue |  | protected | 
 
 
◆ _rigidbodies
  
  | 
        
          | Component [] MoreMountains.Tools.MMRagdoller._rigidbodies |  | protected | 
 
 
◆ _rigidbodiesTempList
  
  | 
        
          | List<Component> MoreMountains.Tools.MMRagdoller._rigidbodiesTempList |  | protected | 
 
 
◆ AllowBlending
      
        
          | bool MoreMountains.Tools.MMRagdoller.AllowBlending = true | 
      
 
whether or not blending will occur when going from ragdolling to animated 
 
 
◆ CurrentState
the current state of the ragdoll 
 
 
◆ ForceSleep
      
        
          | bool MoreMountains.Tools.MMRagdoller.ForceSleep = true | 
      
 
if this is true, all rigidbodies will be forced to sleep every frame 
 
 
◆ MainRigidbody
      
        
          | Rigidbody MoreMountains.Tools.MMRagdoller.MainRigidbody | 
      
 
The rigidbody attached to the main body part of the ragdoll (usually the Pelvis) 
 
 
◆ RagdollToMecanimBlendDuration
      
        
          | float MoreMountains.Tools.MMRagdoller.RagdollToMecanimBlendDuration = 0.5f | 
      
 
the duration in seconds it takes to blend from Ragdolling to Animated 
 
 
◆ Ragdolling
  
  | 
        
          | bool MoreMountains.Tools.MMRagdoller.Ragdolling |  | getset | 
 
Use this to get the current state of the ragdoll or to set a new one. 
 
 
The documentation for this class was generated from the following file:
- H:/Code/MoreMountains/InventoryEngineStore/Assets/InventoryEngine/MMTools/Foundation/MMAnimation/MMRagdoller.cs