enderalse/source/scripts/_00E_IntegrityCheckAlias.psc

38 lines
892 B
Plaintext

Scriptname _00E_IntegrityCheckAlias extends ReferenceAlias Hidden
Event OnInit()
; needs the IsInMenuMode() check to prevent stuck messages
While Utility.IsInMenuMode()
Utility.WaitMenuMode(0.1)
EndWhile
CheckForgottenStories()
_00E_Func_CheckSKSE.Run()
_00E_Func_CheckEnderalDLL.Run()
EndEvent
Event OnPlayerLoadGame()
CheckForgottenStories()
_00E_Func_CheckSKSE.Run()
_00E_Func_CheckEnderalDLL.Run()
EndEvent
function CheckForgottenStories()
; If Enderal - Forgotten Stories.esm is not loaded, kick the player back to main menu
if _00E_FS_IsForgottenStoriesActivated.GetValue() as Int != 1
Utility.wait(2.0)
Game.QuitToMainMenu()
Debug.MessageBox("Enderal - Forgotten Stories.esm is not loaded! The game will not run properly. Open Data Files and enable it.")
return
EndIf
endfunction
GlobalVariable Property _00E_FS_IsForgottenStoriesActivated Auto