Difference between revisions of "Utility Script"

2,950 bytes added ,  08:26, 23 June 2023
imported>CraftySentinel
m (Reverted to List)
 
(2 intermediate revisions by 2 users not shown)
Line 53: Line 53:
:'''[[WaitMenuMode - Utility|WaitMenuMode]](Float ''afSeconds'')'''
:'''[[WaitMenuMode - Utility|WaitMenuMode]](Float ''afSeconds'')'''
:*Pauses the script for at least the specified time (latent). ''Does'' count time spent in a menu.
:*Pauses the script for at least the specified time (latent). ''Does'' count time spent in a menu.
:'''String [[CaptureFrameRate - Utility|CaptureFrameRate]](Int ''numFrames'')'''*
:*Gets a string describing the frame rate for a certain number of frames, the string returned will never be longer then 1,000 characters and is separated by commas.
:'''[[StartFrameRateCapture - Utility|StartFrameRateCapture]]()'''*
:*Starts a frame rate capture.
:'''[[EndFrameRateCapture - Utility|EndFrameRateCapture]]()'''*
:*Ends a frame rate capture.
:'''[[GetAverageFrameRate - Utility|GetAverageFrameRate]]()'''*
:*Returns the average frame rate during the capture.
:'''[[GetMinFrameRate - Utility|GetMinFrameRate]]()'''*
:*Returns the minimum frame rate during the capture.
:'''[[GetMaxFrameRate - Utility|GetMaxFrameRate]]()'''*
:*Returns the maximum frame rate during the capture.


:'''Int [[GetCurrentMemory - Utility|GetCurrentMemory]]()'''
:'''Int [[GetCurrentMemory - Utility|GetCurrentMemory]]()'''
Line 86: Line 68:
:'''String [[GetBudgetName- Utility|GetBudgetName]](Int ''aiBudgetNumber'')'''
:'''String [[GetBudgetName- Utility|GetBudgetName]](Int ''aiBudgetNumber'')'''
:*
:*
<nowiki>*</nowiki> Frame Rate Capture functions were only available during beta versions, and are added here for completeness.


=== Global Functions Only Available in Beta ===
Frame Rate Capture functions were only available during beta versions, and are added here for completeness.
:'''String [[CaptureFrameRate - Utility|CaptureFrameRate]](Int ''numFrames'')'''
:*Gets a string describing the frame rate for a certain number of frames, the string returned will never be longer then 1,000 characters and is separated by commas.
:'''[[StartFrameRateCapture - Utility|StartFrameRateCapture]]()'''
:*Starts a frame rate capture.
:'''[[EndFrameRateCapture - Utility|EndFrameRateCapture]]()'''
:*Ends a frame rate capture.
:'''[[GetAverageFrameRate - Utility|GetAverageFrameRate]]()'''
:*Returns the average frame rate during the capture.
:'''[[GetMinFrameRate - Utility|GetMinFrameRate]]()'''
:*Returns the minimum frame rate during the capture.
:'''[[GetMaxFrameRate - Utility|GetMaxFrameRate]]()'''
:*Returns the maximum frame rate during the capture.


== SKSE Global Functions ==
== SKSE Global Functions ==
Line 104: Line 104:




== Events ==
'''Be careful when using the functions below.''' It is possible to create arrays longer than 128 elements, and ''size'' is treated as an unsigned integer. Negative numbers will produce extremely large values, which can cause major issues.
 
:'''Float[] [[CreateFloatArray - Utility|CreateFloatArray]](Int ''size'', Float ''fill'' = 0.0)'''
:*Creates and returns a Float array with length ''size'', with each element initialized to ''fill''.
 
:'''Int[] [[CreateIntArray - Utility|CreateIntArray]](Int ''size'', Int ''fill'' = 0)'''
:*Creates and returns an Int array with length ''size'', with each element initialized to ''fill''.
 
:'''Bool[] [[CreateBoolArray - Utility|CreateBoolArray]](Int ''size'', Bool ''fill'' = False)'''
:*Creates and returns a Bool array with length ''size'', with each element initialized to ''fill''.
 
:'''String[] [[CreateStringArray - Utility|CreateStringArray]](Int ''size'', String ''fill'' = "")'''
:*Creates and returns a String array with length ''size'', with each element initialized to ''fill''.
 
:'''Form[] [[CreateFormArray - Utility|CreateFormArray]](Int ''size'', Form ''fill'' = None)'''
:*Creates and returns a String array with length ''size'', with each element initialized to ''fill''.
 
:'''Alias[] [[CreateAliasArray - Utility|CreateAliasArray]](Int ''size'', Alias ''fill'' = None)'''
:*Creates and returns an Alias array with length ''size'', with each element initialized to ''fill''.
 
:'''float[] [[ResizeFloatArray - Utility|ResizeFloatArray]](float[] ''source'', int ''size'', float ''fill'' = 0.0)'''
:*Resizes the ''source'' Float Array to be of length ''size'', in case it is grown, initializes uninitialized elements to ''fill''.
 
:'''int[] [[ResizeIntArray - Utility|ResizeIntArray]](int[] ''source'', int ''size'', int ''fill'' = 0)'''
:*Resizes the ''source'' Int Array to be of length ''size'', in case it is grown, initializes uninitialized elements to ''fill''.
 
:'''bool[] [[ResizeBoolArray - Utility|ResizeBoolArray]](bool[] ''source'', int ''size'', bool ''fill'' = false)'''
:*Resizes the ''source'' Bool Array to be of length ''size'', in case it is grown, initializes uninitialized elements to ''fill''.
 
:'''string[] [[ResizeStringArray - Utility|ResizeStringArray]](string[] ''source'', int ''size'', string ''fill'' = "")'''
:*Resizes the ''source'' String Array to be of length ''size'', in case it is grown, initializes uninitialized elements to ''fill''.
 
:'''Form[] [[ResizeFormArray - Utility|ResizeFormArray]](Form[] ''source'', int ''size'', Form ''fill'' = None)'''
:*Resizes the ''source'' Form Array to be of length ''size'', in case it is grown, initializes uninitialized elements to ''fill''.
 
:'''Alias[] [[ResizeFormArray - Utility|ResizeAliasArray]](Alias[] ''source'', int ''size'', Alias ''fill'' = None)'''
:*Resizes the ''source'' Alias Array to be of length ''size'', in case it is grown, initializes uninitialized elements to ''fill''.
 
 
==Events==
None
None


[[Category:Scripting]]
[[Category:Scripting]]
16

edits