enderalse/scripts/source/_00e_wishingwell_failsavesc.psc

37 lines
928 B
Plaintext
Raw Normal View History

Scriptname _00E_WishingWell_FailsaveSC extends ObjectReference
; Script on the wishing wells. This is not just a failsave (despite
; the name of the script).
Event OnInit()
Debug.SetGodMode(False)
Self.BlockActivation(True)
EndEvent
Event OnActivate(ObjectReference akActionRef)
if WishWellState.GetValue() == 2
; This means that the player has already collected the reward
; from this well.
return
endif
; Due to the difficulties of interrupting dialogue with a talking
; activator, we don't want the player to be able to talk with the
; well when the player is in combat.
if PlayerREF.IsInCombat()
_00E_WishingWell_InteractWhileInCombat.Show()
Else
Self.Activate(PlayerREF, True)
EndIf
EndEvent
Message Property _00E_WishingWell_InteractWhileInCombat Auto
Actor Property PlayerREF Auto
GlobalVariable Property WishWellState Auto