OnSleepStop - Form

From the CreationKit Wiki
Jump to navigation Jump to search

Member of: ActiveMagicEffect Script, Alias Script, and Form Script

Event called when the player wakes up - if this active magic effect/alias/form is registered for it.

Syntax[edit | edit source]

Event OnSleepStop(bool abInterrupted)

Parameters[edit | edit source]

  • abInterrupted: Whether sleep was interrupted or not.

Example[edit | edit source]

Function SomeFunction()
  RegisterForSleep() ; Before we can use OnSleepStop we must register.
EndFunction

Event OnSleepStop(bool abInterrupted)
	if abInterrupted
	    Debug.Trace("Player was woken by something!")
	else
	    Debug.Trace("Player woke up naturally")
	endIf
endEvent

Notes[edit | edit source]

  • Aliases and quests will automatically unregister for this event when the quest stops. Active magic effects will automatically unregister when they are removed.
  • This event is not relayed to any aliases or magic effects attached to the form.

See Also[edit | edit source]