Click or drag to resize
RagdollPart Class
Inheritance Hierarchy

Namespace: Candlelight.Physics
Assembly: Assembly-CSharp-firstpass (in Assembly-CSharp-firstpass.dll) Version: 0.0.0.0
Syntax
C#
public class RagdollPart : PhysicalBody

The RagdollPart type exposes the following members.

Methods
  NameDescription
Protected methodAwake
Store Joint's bindpose and frame.
Public methodCacheChild
Adds the specified RagdollPart to the list of cached children. It will only be returned as an actual child if its ParentBody property is this PhysicalBody.
(Inherited from PhysicalBody.)
Public methodCacheCurrentAngularLimits
Caches the current angular limits. The cached value will be used as the extent of the angular limits when they are blended in and out. This method is automatically called when this instance is deserialized.
Public methodCacheImpactTransmissionPercentages
Caches the impact transmission percentages in the hierarchy. You should only need to call this method manually if you change the topology of a ragdoll hierarchy by e.g., changing ParentBody or if parts can translate far away from one another.
Protected methodFixedUpdate
Recovery from impact strength reduction as needed.
Public methodGetAngularDampingProfile
Gets the profile of damping the Joint should use at different normalized strength values when achieving its target angular position on all axes, if applicable.
Public methodGetAngularPositionForceProfile
Gets the profile of force the Joint should use at different normalized strength values when achieving its target angular position on all axes, if applicable.
Public methodGetAngularVelocityForceProfile
Gets the profile of force the Joint should use at different normalized strength values when achieving its target angular velocity on all axes, if applicable.
Public methodGetChildParts
Gets the child parts. These parts will include only RagdollPart objects registered with CacheChild(RagdollPart) and whose ParentBody is this PhysicalBody.
(Inherited from PhysicalBody.)
Public methodGetImpactLayerStrengths
Gets the environment layers that will cause strength reduction upon impact, as well as the factor by which collision impulses will be multiplied when calculating strength reduction.
Public methodGetImpactRecoverySpeedProfile
Gets the impact recovery speed profile.
Public methodGetImpactStrengthReductionProfile
Gets the impact strength reduction profile.
Public methodGetImpactTransmissionProfile
Gets the impact transmission profile.
Public methodGetLinearDampingProfile
Gets the profile of damping the Joint should use at different normalized strength values when achieving its target linear position on all axes, if applicable.
Public methodGetLinearPositionForceProfile
Gets the profile of force the Joint should use at different normalized strength values when achieving its target linear position on all axes, if applicable.
Public methodGetLinearVelocityForceProfile
Gets the profile of force the Joint should use at different normalized strength values when achieving its target linear velocity on all axes, if applicable.
Public methodGetPhysicalHierarchy
Gets the physical hierarchy. These parts will include this PhysicalBody as well as RagdollPart objects registered with CacheChild(RagdollPart) whose ParentBody is this PhysicalBody, as well as their hierarchies.
(Inherited from PhysicalBody.)
Public methodGetPinningForceProfile
Gets the profile of the ratio of pinning-force-to-joint-angular-limits to apply at different normalized strength values to try to maintain target position.
Protected methodOnCollisionEnter
Raises the collision enter event.
(Overrides FlexibleColliderOnCollisionEnter(Collision).)
Protected methodOnCollisionExit
Raises the collision exit event.
(Inherited from FlexibleCollider.)
Protected methodOnCollisionStay
Raises the collision stay event.
(Overrides FlexibleColliderOnCollisionStay(Collision).)
Protected methodOnDisable
Raises the disable event.
(Inherited from PhysicalBody.)
Protected methodOnEnable
Raises the enable event.
(Overrides PhysicalBodyOnEnable.)
Protected methodOnJointBreak
Set the HasJointBroken flag.
Public methodOnModifySymmetricalProperty
Raises the modify symmetrical property event. This method is called when a property is set that needs to be pushed to the corresponding FlexibleCollider. You can invoke it manually if you need to push settings that are not managed on this object directly, such as Joint limits.
(Inherited from FlexibleCollider.)
Protected methodOnSynchronizeSymmetricalProperties
Raises the synchronize symmetrical properties event.
(Overrides PhysicalBodyOnSynchronizeSymmetricalProperties.)
Public methodRecoverFromImpactImmediately
Immediately resets the impact recovery timer.
Protected methodReduceStrength
Tries to reduce the strength of this part using the specified impulse.
Protected methodReset
Reset this instance.
Public methodResetBindpose
Resets Joint's bindpose in the current configuration.
Public methodSetAngularDampingProfile
Sets the profile of damping the Joint should use at different normalized strength values when achieving its target angular position on all axes, if applicable.
Public methodSetAngularPositionForceProfile
Sets the profile of force the Joint should use at different normalized strength values when achieving its target angular position on all axes, if applicable.
Public methodSetAngularVelocityForceProfile
Sets the profile of force the Joint should use at different normalized strength values when achieving its target angular velocity on all axes, if applicable.
Public methodSetImpactLayerStrengths
Sets the environment layers that will cause strength reduction upon impact, as well as the factor by which collision impulses will be multiplied when calculating strength reduction.
Public methodSetImpactRecoverySpeedProfile
Sets the impact recovery speed profile.
Public methodSetImpactStrengthReductionProfile
Sets the impact strength reduction profile.
Public methodSetImpactTransmissionProfile
Sets the impact transmission profile.
Public methodSetJointTargetRotation
Sets the ConfigurableJoint.targetRotation property by transforming the supplied local rotation.
Public methodSetLinearDampingProfile
Sets the profile of damping the Joint should use at different normalized strength values when achieving its target linear position on all axes, if applicable.
Public methodSetLinearPositionForceProfile
Sets the profile of force the Joint should use at different normalized strength values when achieving its target linear position on all axes, if applicable.
Public methodSetLinearVelocityForceProfile
Sets the profile of force the Joint should use at different normalized strength values when achieving its target linear velocity on all axes, if applicable.
Public methodSetPinningForceProfile
Sets the profile of the ratio of pinning-force-to-joint-angular-limits to apply at different normalized strength values to try to maintain target position.
Public methodSetStrength
Sets the strength of this part.
Protected methodStart
Cache the angular limits on Joint.
(Overrides PhysicalBodyStart.)
Public methodTryAddImpactAtPoint
Tries to add an impact at the specified point that will cause this part and neighboring ones to reduce their strength.
Protected methodTryImpactCollision
Tries to reduce the strength of this part and neighboring ones using the specified collision data.
Public methodUseExplicitCenterOfMassWhenLoaded

Makes the Rigidbody.centerOfMass property on Rigidbody use the explicit value serialized in the backing field for CenterOfMass when this objet is first loaded. Neither it nor Rigidbody.inertiaTensor will be automatically/continuously calculated anymore.

This method only exists for enabling explicit center of mass before this object is loaded (e.g., in the editor). Setting CenterOfMass at run-time will cause the explicitly specified value to be used whether or not this method has been called.

(Inherited from PhysicalBody.)
Top
Extension Methods
  NameDescription
Public Extension MethodGetPrefabName
Gets the name of the prefab associated with the supplied instance.
(Defined by ObjectX.)
Public Extension MethodOpenReferencePage
Opens a reference web page generated for the specified object.
(Defined by ObjectX.)
Top
Properties
  NameDescription
Public propertyAreAngularLimitsCached
Gets a value indicating whether angular limits have been cached on this instance.
Public propertyBlendTime
Gets or sets the number of seconds this part takes to blend out of non-kinematic motion. This value is just a convenience for other scripts that might want to use it.
(Inherited from PhysicalBody.)
Public propertyCenter
Gets or sets the center of the Collider in this object's space.
(Inherited from FlexibleCollider.)
Public propertyCenterOfMass

Gets or sets the center of mass on Rigidbody.

As with Rigidbody.centerOfMass, setting a value for this property at run-time will set IsCenterOfMassExplicit to .

(Inherited from PhysicalBody.)
Public propertyChildCentroid
Gets the average position of all child bodies in this body's space.
(Inherited from PhysicalBody.)
Public propertyCollider
Gets the collider.
(Inherited from FlexibleCollider.)
Public propertyCorrespondingObject

Gets the corresponding FlexibleCollider across a plane of symmetry.

It will be the FlexibleCollider component on the CorrespondingTransform of the SymmetryMapper assigned to this instance.

(Inherited from FlexibleCollider.)
Public propertyHasJointBroken
Gets a value indicating whether Joint has broken.
Public propertyIsCenterOfMassExplicit

Gets a value indicating whether this object has already explicitly applied its CenterOfMass property to Rigidbody or should when it is loaded. If it returns , then Unity is assumed to be automatically/continuously calculating Rigidbody.centerOfMass and Rigidbody.inertiaTensor.

(Inherited from PhysicalBody.)
Public propertyIsRecoveringFromImpact
Gets a value indicating whether this instance is recovering from an environmental impact or an impulse manually applied via TryAddImpactAtPoint(Vector3, Vector3).
Public propertyStatic memberIsSilent
Gets or sets a value indicating whether instances of this class should emit debug messages. This value should only be set to when performing automated tests.
Public propertyJoint
Gets or sets the ConfigurableJoint on this object.
Public propertyLocalRotation
Gets or sets the Collider's local rotation in this object's space.
(Inherited from FlexibleCollider.)
Public propertyMaxStrength
Gets or sets the max strength of this part.
Public propertyOnCollisionEnterEvent
Gets the on collision enter event.
(Inherited from FlexibleCollider.)
Public propertyOnCollisionExitEvent
Gets the on collision exit event.
(Inherited from FlexibleCollider.)
Public propertyOnCollisionStayEvent
Gets the on collision stay event.
(Inherited from FlexibleCollider.)
Public propertyParentBody
Gets or sets the PhysicalBody to which Joint is attached.
Public propertyPinningStrength
Gets the pinning strength given the current Strength value.
Public propertyPrimaryJointAxisSymmetryMode
Gets or sets the symmetry mode for the primary axis on Joint.
Public propertyReciprocalBlendTime
Gets the reciprocal of BlendTime.
(Inherited from PhysicalBody.)
Public propertyRigidbody
Gets the Rigidbody on this object.
(Inherited from PhysicalBody.)
Public propertyRunTimeSync
Gets or sets a value describing whether or not this FlexibleCollider should continue to sync with its corresponding part at run-time.
(Inherited from FlexibleCollider.)
Public propertySecondaryJointAxisSymmetryMode
Gets or sets the symmetry mode for the secondary axis on Joint.
Public propertyShape
Gets or sets the shape of the Collider.
(Inherited from FlexibleCollider.)
Public propertySize
Gets or sets the size of the Collider.
(Inherited from FlexibleCollider.)
Public propertyStrength
Gets the current strength of the Joint on this part.
Public propertySymmetryMapper

Gets or sets a SymmetricalTransform component on this GameObject, which allows symmetrical property edits.

If it is not and its CorrespondingTransform is assigned and has a FlexibleCollider component of this object's type, then all changes made to properties on this object will be reflected across the plane of symmetry.

(Inherited from FlexibleCollider.)
Public propertyTransform
Gets this object's Transform.
(Inherited from FlexibleCollider.)
Top
Events
  NameDescription
Public eventOnExceededMaximumImpulse
Occurs when this part receives an impulse from the environment or from TryAddImpactAtPoint(Vector3, Vector3) whose square magnitude exceeds the maximum value of its impact strength reduction profile.
Public eventOnImpact
Occurs when this part receives an impulse from the environment or from TryAddImpactAtPoint(Vector3, Vector3).
Top
See Also