Mod:Creation Kit/GetActorOwner - ObjectReference

Member of: Mod:Creation Kit/ObjectReference Script

Gets the ActorBase that owns this object. Will return None if the object isn't owned by an actor.

Caution! If the owner of this object is a specific Actor (a reference rather than an ActorBase), this function will still return the ActorBase for that Actor. To determine whether this object is owned by a specific actor or an ActorBase, check GetActorRefOwner first. If that returns None, only then should you check this function.

Syntax
ActorBase Function GetActorOwner native

Parameters
None.

Return Value
The ActorBase that owns this object.

Examples
bool playerOwnsSword = (SwordProperty.GetActorOwner == Game.GetPlayer.GetActorBase)
 * Does the player own the sword?