Struct GaitPose.LimbTarget

Namespace
CodeSmile.AnyMotion.AnimateYourself.Gait
/
Assembly
ApiSource.dll

Target for one extremity, for the IK-target space.

public struct GaitPose.LimbTarget
Expand Details ...

Fields

ContactWeight

1 when the extremity is planted and must not move through geometry, 0 while it is swinging freely. R10's geometry avoidance scales its correction by this value.

public float ContactWeight

Field Value

float

Euler

Orientation offset for the foot or hand, in degrees, relative to the bind pose.

public Vector3 Euler

Field Value

Vector3

GroundBlend

L05: 0..1, how much of the ground raycast's height correction to apply this frame — see CodeSmile.AnyMotion.AnimateYourself.Gait.GaitMath.GroundBlend(bool, float, in CodeSmile.AnyMotion.AnimateYourself.Gait.GaitMath.SwingShape) for why this cannot simply be 1 throughout swing. Unused by hands.

public float GroundBlend

Field Value

float

IsStance

True while this leg is in the stance half of its own cycle, and while the character is standing. Always false for a hand.

public bool IsStance

Field Value

bool

Remarks

Separate from ContactWeight on purpose. That value ramps through the beginning and end of swing so a correction can fade in and out, which makes it a weight and not a state; reading "stance" out of it means comparing it against 1, and that would silently change meaning the next time the ramp is retuned. The sole-height compensation in IkTargetSpaceDriver needs the state: it corrects a planted foot and must leave a swinging one alone.

NeutralPosition

Position this limb would hold if the character were standing still, in metres.

public Vector3 NeutralPosition

Field Value

Vector3

PlantTarget

L05 (foot planting on uneven ground): where a ground raycast should sample, in metres. During stance this matches Position's clean (pre-noise) value — the same root-motion-cancelling sweep, so the world-space query stays pinned at the planted foot instead of drifting forward with the root for the whole stance. Deliberately excludes the small per-frame irregularity jitter Position carries: a raycast sampled at a jittering point would read terrain noise that is not there. During swing it is the predicted touchdown point instead of the animating swing arc in Position: a forward lookahead from MoveSpeed and the remaining swing time, so the raycast lands ahead of the foot instead of tracking it in mid-air (locomotion-catalog.md §3, spec correction). Unused by hands.

public Vector3 PlantTarget

Field Value

Vector3

PoleAngle

Direction the knee points, in degrees around the limb's root-to-tip axis. Positive is outward. Feeds the pole vector of the leg IK solve. Unused for hands (L11): the elbow's pole direction is computed dynamically by IkTargetSpaceDriver.ResolveArmPoleDirection from the reach target itself, since a fixed angle cannot track a target that can be anywhere around the body, unlike a foot's target which stays roughly in front.

public float PoleAngle

Field Value

float

Position

Local-space position in metres for the ankle or wrist bone, not the sole or the fingertip. For feet, AnkleHeight is already included, so a foot flat on the ground at Y=0 has this position at Y=AnkleHeight.

public Vector3 Position

Field Value

Vector3