SetAnimAdditive

From GECK
Jump to: navigation, search


A function added by the kNVSE Plugin.

Description

Sets an additive animation for an actor, providing a reference pose animation and an optional time point for blending. This function is used to apply a secondary animation on top of an actor's base animation. Returns 1 if the additive animation is successfully applied, and 0 otherwise.

  • The argument first person controls whether the animation should apply to the first-person model (if applicable). If not specified and the actor is the player, the player's current perspective is used.
  • The argument reference pose anim path allows specifying a reference pose animation to blend from. If not provided, a default idle animation will be used.
  • reference pose time point specifies a time point within the reference pose animation to blend from, allowing fine control over the blending process. Defaults to 0.0 if not specified.

To play the anim use ActivateAnim or any other of kNVSE's low level animation functions.

Syntax

[help]
actor.SetAnimAdditive additive anim path:string
  first person:0/1
  reference pose anim path:string
  reference pose time point:float

Example

Player.SetAnimAdditive "Characters\HitReact.kf" 1 "Characters\IdlePose.kf" 0.5

See Also