C# Class RootMotion.BipedReferences

Datei anzeigen Open project: Alx666/ProjectPhoenix Class Usage Examples

Public Properties

Property Type Description
eyes UnityEngine.Transform[]
head UnityEngine.Transform
leftCalf Transform
leftFoot Transform
leftForearm Transform
leftHand Transform
leftThigh Transform
leftUpperArm Transform
pelvis Transform
rightCalf Transform
rightFoot Transform
rightForearm Transform
rightHand Transform
rightThigh Transform
rightUpperArm Transform
root Transform
spine Transform[]

Public Methods

Method Description
AssignHumanoidReferences ( BipedReferences &references, Animator animator, AutoDetectParams autoDetectParams ) : void

Fills in BipedReferences using Animator.GetBoneTransform().

AutoDetectReferences ( BipedReferences &references, Transform root, AutoDetectParams autoDetectParams ) : bool

Automatically detects biped bones. Returns true if a valid biped has been referenced.

CheckSetupError ( BipedReferences references, bool log ) : bool

Checks the setup for definite problems.

CheckSetupWarning ( BipedReferences references, bool log ) : bool

Checks the setup for possible problems.

DetectReferencesByNaming ( BipedReferences &references, Transform root, AutoDetectParams autoDetectParams ) : void

Detects the references based on naming and hierarchy.

IsEmpty ( bool includeRoot ) : bool

Gets a value indicating whether this BipedReferences is empty. If includeRoot is false, returns true(is empty) even if root Transform has been assigned.

Private Methods

Method Description
AddBoneToEyes ( Transform bone, BipedReferences &references, AutoDetectParams autoDetectParams ) : bool
AddBoneToHierarchy ( Transform &bones, Transform transform ) : void
AddBoneToSpine ( Transform bone, BipedReferences &references, AutoDetectParams autoDetectParams ) : bool
CheckEyesError ( BipedReferences references, bool log ) : bool
CheckEyesWarning ( BipedReferences references, bool log ) : bool
CheckFacingAxisWarning ( BipedReferences references, bool log ) : bool
CheckLimbError ( Transform bone1, Transform bone2, Transform bone3, bool log ) : bool
CheckLimbWarning ( Transform bone1, Transform bone2, Transform bone3, bool log ) : bool
CheckRootHeightWarning ( BipedReferences references, bool log ) : bool
CheckSpineError ( BipedReferences references, bool log ) : bool
CheckSpineWarning ( BipedReferences references, bool log ) : bool
DetectLimb ( RootMotion.BipedNaming boneType, RootMotion.BipedNaming boneSide, Transform &firstBone, Transform &secondBone, Transform &lastBone, Transform transforms ) : void
GetVerticalOffset ( Vector3 p1, Vector3 p2, Quaternion rotation ) : float
IsNeckBone ( Transform bone, Transform leftUpperArm ) : bool

Method Details

AssignHumanoidReferences() public static method

Fills in BipedReferences using Animator.GetBoneTransform().
public static AssignHumanoidReferences ( BipedReferences &references, Animator animator, AutoDetectParams autoDetectParams ) : void
references BipedReferences
animator UnityEngine.Animator
autoDetectParams AutoDetectParams
return void

AutoDetectReferences() public static method

Automatically detects biped bones. Returns true if a valid biped has been referenced.
public static AutoDetectReferences ( BipedReferences &references, Transform root, AutoDetectParams autoDetectParams ) : bool
references BipedReferences
root UnityEngine.Transform
autoDetectParams AutoDetectParams
return bool

CheckSetupError() public static method

Checks the setup for definite problems.
public static CheckSetupError ( BipedReferences references, bool log ) : bool
references BipedReferences
log bool
return bool

CheckSetupWarning() public static method

Checks the setup for possible problems.
public static CheckSetupWarning ( BipedReferences references, bool log ) : bool
references BipedReferences
log bool
return bool

DetectReferencesByNaming() public static method

Detects the references based on naming and hierarchy.
public static DetectReferencesByNaming ( BipedReferences &references, Transform root, AutoDetectParams autoDetectParams ) : void
references BipedReferences
root UnityEngine.Transform
autoDetectParams AutoDetectParams
return void

IsEmpty() public method

Gets a value indicating whether this BipedReferences is empty. If includeRoot is false, returns true(is empty) even if root Transform has been assigned.
public IsEmpty ( bool includeRoot ) : bool
includeRoot bool
return bool

Property Details

eyes public_oe property

The eyes.
public Transform[],UnityEngine eyes
return UnityEngine.Transform[]

head public_oe property

The head.
public Transform,UnityEngine head
return UnityEngine.Transform

leftCalf public_oe property

The second bone of the left leg.
public Transform leftCalf
return Transform

leftFoot public_oe property

The third bone of the left leg.
public Transform leftFoot
return Transform

leftForearm public_oe property

The second bone of the left arm.
public Transform leftForearm
return Transform

leftHand public_oe property

The third bone of the left arm.
public Transform leftHand
return Transform

leftThigh public_oe property

The first bone of the left leg.
public Transform leftThigh
return Transform

leftUpperArm public_oe property

The first bone of the left arm.
public Transform leftUpperArm
return Transform

pelvis public_oe property

The pelvis (hip) bone.
public Transform pelvis
return Transform

rightCalf public_oe property

The second bone of the right leg.
public Transform rightCalf
return Transform

rightFoot public_oe property

The third bone of the right leg.
public Transform rightFoot
return Transform

rightForearm public_oe property

The second bone of the right arm.
public Transform rightForearm
return Transform

rightHand public_oe property

The third bone of the right arm.
public Transform rightHand
return Transform

rightThigh public_oe property

The first bone of the right leg.
public Transform rightThigh
return Transform

rightUpperArm public_oe property

The first bone of the right arm.
public Transform rightUpperArm
return Transform

root public_oe property

The root transform is the parent of all the biped's bones and should be located at ground level.
public Transform root
return Transform

spine public_oe property

The spine hierarchy. Should not contain any bone deeper in the hierarchy than the arms (neck or head).
public Transform[] spine
return Transform[]