build Constructors 1

data_object Properties 20

AnimationGraph
AnimationGraph
Override animgraph, otherwise uses animgraph of the model.
BoneMergeTarget
SkinnedModelRenderer
BoneWorldTransforms
ReadOnlySpan`1
This frame's final world-space bone transforms, cached so repeated callers - and parallel readers - share a single skeleton read instead of each fetching bones one at a time. Rebuilt at most once per frame. The returned data is shared and must not be mutated. Empty if there's no valid model.
CreateBoneObjects
bool
Morphs
MorphAccessor
Access to the morphs for this model
OnAnimTagEvent
Action`1
Called when an anim tag event happens
OnFootstepEvent
Action`1
Called when a footstep event happens
OnGenericEvent
Action`1
Called when a generic animation event happens
OnSoundEvent
Action`1
Called when a sound event happens
Parameters
ParameterAccessor
Access to the animgraph parameters for this model
PlayAnimationsInEditorScene
bool
If true then animations will play while in an editor scene.
PlaybackRate
float
Control playback rate of animgraph or current sequence.
PreviousBoneWorldTransforms
ReadOnlySpan`1
Last frame's final world-space bone transforms - the counterpart to Sandbox.SkinnedModelRenderer.BoneWorldTransforms, so consumers can tell how each bone moved this frame without tracking it themselves.
RootMotion
Transform
SceneModel
SceneModel
Sequence
SequenceAccessor
Allows playback of sequences directly, rather than using an animation graph. Requires Sandbox.SkinnedModelRenderer.UseAnimGraph disabled if the scene model has one.
ShouldShowMorphsEditor
bool
ShouldShowParametersEditor
bool
ShouldShowSequenceEditor
bool
UseAnimGraph
bool
Usually used for turning off animation on ragdolls.

functions Methods 23

ClearIk (name)
This sets ik.{name}.enabled to false.
ClearParameters ()
Remove any stored parameters
ClearPhysicsBones ()
GetAttachment (name, worldSpace)
Nullable`1
GetBoneObject (index)
GameObject
Get the GameObject of a specific bone.
GetBoneTransforms (world)
Transform[]
Allocate an array of bone transforms in either world space or parent space.
GetBoneVelocities ()
BoneVelocity[]
Allocate an array of bone velocities in world space
GetBoneVelocity (boneIndex)
BoneVelocity
Retrieve the bone's velocities based on previous and current position
GetBool (v)
bool
GetClosestBone (worldPoint)
Bone
The bone closest to a world position, or null when there's no model. Resolved natively in one call - nothing is allocated or copied. Use for sticking things to the nearest bone (impact decals, gibs).
GetFloat (v)
float
GetInt (v)
int
GetRotation (v)
Rotation
GetVector (v)
Vector3
PostAnimationUpdate ()
obsolete
Set (v, value)
SetBoneTransform (bone, transform)
SetIk (name, tx)
Sets an IK parameter. This sets 3 variables that should be set in the animgraph: 1. ik.{name}.enabled 2. ik.{name}.position 3. ik.{name}.rotation
SetLookDirection (name, eyeDirectionWorld)
Converts value to vector local to this entity's eyepos and passes it to SetAnimVector
SpeakSound (sound, mouth)
SoundHandle
Play a sound as this model's voice. On top of regular sound playback, the model will lipsync to it - if the sound has a viseme track (authored in the sound editor) we play that back, otherwise the audio is analyzed as it plays. Either way the mouth moves, assuming the model has viseme morphs.
TryGetBoneTransform (boneName, tx)
bool
Try to get the final worldspace bone transform.
TryGetBoneTransformAnimation (bone, tx)
bool
Try to get the worldspace bone transform after animation but before physics and procedural bones.
TryGetBoneTransformLocal (boneName, tx)
bool

Inheritance

people
Log in to reply
You can't reply if you're not logged in. That would be crazy.