Background for Skyrim SE
Member of the Actor script
eventOnPackageEnd(PackageakOldPackage)

Description

Wiki Description

Event called when the actor finishes a package.

Documentation Comment

Event received when this actor's package ends


Caveats

CK Wiki - Notes

  • This event only occurs for packages that have completion conditions, and it does not mean the actor is no longer running the package. For example, an actor running a package based on the Travel template will receive this event upon reaching the package's destination, but the actor will continue running the package for as long as it is the highest priority package whose conditions are met. To find out when an actor is no longer running the package, use Actor.OnPackageChange(...).
  • This can be used in a ReferenceAlias script attached to the player that is currently controlled via Game.SetPlayerAIDriven(...), and has finished a package.

Parameters

  1. PackageakOldPackage

    CK Wiki Description

    The Package that just completed.


Examples

Event OnPackageEnd(Package akOldPackage)
  Debug.Trace("We just completed the " + akOldPackage + " package")
endEvent

Auto-Generated Example

Scriptname MyCoolScript extends Actor

event OnPackageEnd(Package akOldPackage)
    Debug.trace("Event received - OnPackageEnd: akOldPackage = " + akOldPackage)
endEvent

Related Pages


Additional References

View this event’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.