enderalse/source/scripts/_00e_applyimodareasc.psc

41 lines
1.2 KiB
Plaintext
Raw Normal View History

2024-01-16 01:56:39 +00:00
ScriptName _00E_ApplyImodAreaSC Extends ObjectReference
;-- Variables ---------------------------------------
Bool bHasFired
;-- Properties --------------------------------------
ImageSpaceModifier Property HoldIMOD Auto
ImageSpaceModifier Property IntroIMOD Auto
ImageSpaceModifier Property OutroIMOD Auto
Bool Property __Config_bHasIntro = False Auto
{ Should an intro IMOD be applied before the HOLD Imod? }
Float Property __Config_fIntroDuration = 2.0 Auto
{ After how many seconds the HOLD imod should be transitioned. Default = 2.0 }
;-- Functions ---------------------------------------
; Skipped compiler generated GetState
; Skipped compiler generated GotoState
Event OnTriggerEnter(ObjectReference akActionRef)
If akActionRef == Game.GetPlayer() as ObjectReference
If __Config_bHasIntro
IntroIMOD.Apply(1.0)
HoldIMOD.ApplyCrossFade(__Config_fIntroDuration)
ElseIf !bHasFired
HoldIMOD.Apply(1.0)
ElseIf bHasFired
HoldIMOD.ApplyCrossFade(3.0)
EndIf
EndIf
EndEvent
Event OnTriggerLeave(ObjectReference akActionRef)
If OutroIMOD
OutroIMOD.ApplyCrossFade(3.0)
Else
ImageSpaceModifier.RemoveCrossFade(3.0)
EndIf
EndEvent