2024-01-09 22:00:18 +00:00
|
|
|
Scriptname _00E_Func_ReferenceFormList Hidden
|
|
|
|
|
|
|
|
Function Enable(FormList referenceList) Global
|
|
|
|
|
|
|
|
Int nItems = referenceList.GetSize()
|
|
|
|
Int i = 0
|
|
|
|
|
2024-02-07 15:20:32 +00:00
|
|
|
If nItems < 128 && nItems > 1 && SKSE.GetVersion() > 0
|
2024-01-09 22:00:18 +00:00
|
|
|
Form[] refArray = referenceList.ToArray()
|
|
|
|
While i < nItems
|
|
|
|
(refArray[i] as ObjectReference).EnableNoWait()
|
|
|
|
i += 1
|
|
|
|
EndWhile
|
|
|
|
Else
|
|
|
|
While i < nItems
|
|
|
|
(referenceList.GetAt(i) as ObjectReference).EnableNoWait()
|
|
|
|
i += 1
|
|
|
|
EndWhile
|
|
|
|
EndIf
|
|
|
|
|
|
|
|
EndFunction
|
|
|
|
|
|
|
|
Function Disable(FormList referenceList) Global
|
|
|
|
|
|
|
|
Int nItems = referenceList.GetSize()
|
|
|
|
Int i = 0
|
|
|
|
|
2024-02-07 15:20:32 +00:00
|
|
|
If nItems < 128 && nItems > 1 && SKSE.GetVersion() > 0
|
2024-01-09 22:00:18 +00:00
|
|
|
Form[] refArray = referenceList.ToArray()
|
|
|
|
While i < nItems
|
|
|
|
(refArray[i] as ObjectReference).DisableNoWait()
|
|
|
|
i += 1
|
|
|
|
EndWhile
|
|
|
|
Else
|
|
|
|
While i < nItems
|
|
|
|
(referenceList.GetAt(i) as ObjectReference).DisableNoWait()
|
|
|
|
i += 1
|
|
|
|
EndWhile
|
|
|
|
EndIf
|
|
|
|
|
|
|
|
EndFunction
|