Table of Contents

Interface IAnimationEvents

Namespace
SkyrimForge.Events
Assembly
SkyrimForge.dll

An actor's animation events, which are the annotations on its animations.

public interface IAnimationEvents

Remarks

These correspond to Papyrus's OnAnimationEvent. A handler runs on the worker thread that updates the actor's animation, not on the game's thread, and handlers for different actors run at the same time. A subscription to the player's events continues through a move to another cell and through a load. A handler that throws, or whose task faults, is dropped, and the exception is written to the log of the plugin that subscribed it.

Methods

Subscribe<TActor>(TActor, AsyncGameEventHandler<AnimationEventArgs>)

Subscribes handler to the animation events of actor.

ISubscription? Subscribe<TActor>(TActor actor, AsyncGameEventHandler<AnimationEventArgs> handler) where TActor : IActor

Parameters

actor TActor
handler AsyncGameEventHandler<AnimationEventArgs>

Returns

ISubscription

Null for an actor with no animation graph, such as one outside the loaded area.

Type Parameters

TActor

Exceptions

ArgumentNullException

handler is null.

Subscribe<TActor>(TActor, GameEventHandler<AnimationEventArgs>)

Subscribes handler to the animation events of actor.

ISubscription? Subscribe<TActor>(TActor actor, GameEventHandler<AnimationEventArgs> handler) where TActor : IActor

Parameters

actor TActor
handler GameEventHandler<AnimationEventArgs>

Returns

ISubscription

Null for an actor with no animation graph, such as one outside the loaded area.

Type Parameters

TActor

Exceptions

ArgumentNullException

handler is null.