Background for Skyrim SE
Member of the Form script
voidfunctionRegisterForActorAction(intactionType)Native

Description

Wiki Description

Registers the calling form to listen for the specified actor action via Form.OnActorAction(...).

Syntax

Function RegisterForActorAction(int actionType) Native

Parameters

  • actionType - The following integers are valid:

    • 0 - Weapon Swing (Melee weapons that are swung including Hand to Hand.)
    • 1 - Spell Cast (Spells and staves).
    • 2 - Spell Fire (Spells and staves).
    • 3 - Voice Cast.
    • 4 - Voice Fire.
    • 5 - Bow Draw.
    • 6 - Bow Release.
    • 7 - Draw Begin.
    • 8 - Draw End.
    • 9 - Sheathe Begin.
    • 10 - Sheathe End.

Examples

RegisterforActorAction(0) ; Registers the form for Weapon Swings

Caveats

CK Wiki - Notes

  • This function only registers for actions performed by the player's actor, while it can be used on any form it will always be the player's actor's actions that are being registered.
  • Weapons will trigger Draw Begin & Draw End when drawn - but spells will only trigger Draw End. Similarly, weapons will trigger Sheathe Begin & Sheathe End when sheathed, but spells will only trigger Sheathe End.

Parameters

  1. intactionType


Examples

No human-generated examples found for this function.

Auto-Generated Example

int myInt__actionType

myForm__toCallFunctionOn.RegisterForActorAction(myInt__actionType)

Related Pages


Additional References

View this function’s page on the Skyrim Creation Kit Wiki

Some data provided by the Skyrim Creation Kit Wiki. Licensed under the Creative Commons Attribution-ShareAlike license.