Background for Starfield
Member of the ObjectReference script
eventOnOpen(ObjectReferenceakActionRef)

Description

Wiki Description

Event called when the object has finished opening. (Like a door that has finished animating open)

Documentation Comment

Event received when this object is opened


Parameters

  1. ObjectReferenceakActionRef

    CK Wiki Description

    The reference that caused us to open.


Examples

Event OnOpen(ObjectReference akActionRef)
  if (akActionRef == Game.GetPlayer())
    Debug.Trace("We were opened by the player")
  else
    Debug.Trace("Someone (or something) else opened us")
  endIf
endEvent

Auto-Generated Example

Scriptname MyCoolScript extends ObjectReference

event OnOpen(ObjectReference akActionRef)
    Debug.trace("Event received - OnOpen: akActionRef = " + akActionRef)
endEvent

Related Pages


Additional References

View this event’s page on the Fallout 4 Creation Kit Wiki

Some data provided by the Fallout 4 Creation Kit Wiki. Licensed under the Creative Commons Attribution-Share Alike 4.0 license.