Skip to content

EventControlledSelectorClipData

Class Documentation

Edit documentation

A clip that plays one child, chosen by a state event. A state event is an id that is raised on the animation graph of a unit. Two things raise one:

  • A StateLogicEventData animation event, with the id in its StateLogicEventSignalId.
  • In a state graph (AnimationGraphData.AnimStateGraphEntryClips), every request of the game to play an animation by name. The id is the hash of the requested name, for example the hash of attack1.

Each child is tied to one event id. When that event is raised, the child becomes the choice of this clip, and it stays the choice until another listed event is raised. The clip does not go back to its default.

It runs like every condition clip, see ConditionBoolClipData: one child at a time, and a switch to a new choice while a child plays only with ChangeAnimationMidPlay.

Properties

ChangeAnimationMidPlay

Bool = false
Edit documentation

Lets the clip switch to a new choice while a child plays. When false, an event that arrives while a child plays changes the choice but not the child, and the clip ends with that child.

ChildAnimDelaySwitchTime

F32 = 0
Edit documentation

How long the new choice must hold before the clip switches, in seconds. Same as ConditionBoolClipData.mChildAnimDelaySwitchTime.

DefaultClipName

Hash = "0x0"
Edit documentation

The child that plays when the clip starts and none of the listed events was raised in that frame. Empty, or a name that is not in the graph, starts nothing: the clip then waits for a listed event.

It is used only at the start.

DontStompTransitionClip

Bool = false
Edit documentation

Keeps a transition clip that already plays. Same as ConditionBoolClipData.DontStompTransitionClip.

PlayAnimChangeFromBeginning

Bool = false
Edit documentation

Starts the new child at its beginning on a switch. Same as ConditionBoolClipData.mPlayAnimChangeFromBeginning.

SyncFrameOnChangeAnim

Bool = false
Edit documentation

Changes the start position that a switch takes from the old child. Same as ConditionBoolClipData.SyncFrameOnChangeAnim.