enderalse/source/scripts/_00e_lisharidialogue_functions.psc

75 lines
2.3 KiB
Plaintext
Raw Normal View History

Scriptname _00E_LishariDialogue_Functions extends Quest
;=====================================================================================
; FUNCTIONS
;=====================================================================================
Function SetUp()
If _00E_MC_LishariREF.IsDisabled()
_00E_MC_LishariREF.Enable()
EndIf
_00E_MC_LishariREF.MoveTo(_00E_TeleportMarker_Suntemple)
EndFunction
Function MoveLishari()
; Move player and (indirectly) Lishari to tavern and start
; the dinner scene.
;
; This now includes an ugly overengineered trick to make Lishari
; stand up if she is sitting. The package for that is
; _00E_LishariDialogue_SandboxNoSitPkg.
; The global variable _00E_LishariDialogue_HeadingGlobal is needed
; to properly condition said package; the EvaluatePackages are
; there to ensure that it actually starts.
ModObjectiveGlobal(1, _00E_LishariDialogue_HeadingGlobal)
FadeToBlackIMOD.Apply()
FadeToBlackHoldIMOD.ApplyCrossFade(3)
_00E_MC_LishariREF.EvaluatePackage()
Utility.Wait(2)
if (_00E_MC_LishariREF.GetSitState() != 0)
_00E_MC_LishariREF.EvaluatePackage()
Utility.Wait(2)
endif
PlayerREF.MoveTo(LishariDialogue_SC01_PlayerChair)
LishariDialogue_SC01_LishariConversation.ForceStart()
EndFunction
Function LishariSit()
_00E_MC_LishariREF.Disable()
_00E_MC_LishariREF.MoveTo(LishariDialogue_SC01_Chair)
_00E_MC_LishariREF.Enable()
EndFunction
Function FadeBack()
FadeToBlackBackIMOD.ApplyCrossFade()
EndFunction
;=====================================================================================
; PROPERTIES
;=====================================================================================
Actor Property _00E_MC_LishariREF Auto
Actor Property PlayerREF Auto
ObjectReference Property LishariDialogue_SC01_Chair Auto
ObjectReference Property LishariDialogue_SC01_PlayerChair Auto
ObjectReference Property _00E_TeleportMarker_Suntemple Auto
Scene Property LishariDialogue_SC01_LishariConversation Auto
ImageSpaceModifier Property FadeToBlackIMOD Auto
ImageSpaceModifier Property FadeToBlackHoldIMOD Auto
ImageSpaceModifier Property FadeToBlackBackIMOD Auto
GlobalVariable Property _00E_LishariDialogue_HeadingGlobal Auto