Background for Skyrim SE

JsonUtil


Inheritance Tree

No indexed scripts extend this script.

Properties
Events
Functions
boolfunctionLoad(stringFileName)NativeGlobal
boolfunctionSave(stringFileName, boolminify=false)NativeGlobal
boolfunctionUnload(stringFileName, boolsaveChanges=true, boolminify=false)NativeGlobal
boolfunctionIsPendingSave(stringFileName)NativeGlobal

Check if given file has had any changes to it they haven't yet been saved

boolfunctionIsGood(stringFileName)NativeGlobal

Check if the given file was succesfully loaded and has no json parser errors

stringfunctionGetErrors(stringFileName)NativeGlobal

Get a formatted error string of any json parser errors on a file, returns as empty string if no errors.

string[]functionJsonInFolder(stringfolderPath)NativeGlobal

Returns a list of all filenames in a given folder that end in .json

boolfunctionJsonExists(stringFileName)Global

Check if a json file exists or not

intfunctionSetIntValue(stringFileName, stringKeyName, intvalue)NativeGlobal

See StorageUtil.psc for equivalent function usage instructions

floatfunctionSetFloatValue(stringFileName, stringKeyName, floatvalue)NativeGlobal
stringfunctionSetStringValue(stringFileName, stringKeyName, stringvalue)NativeGlobal
FormfunctionSetFormValue(stringFileName, stringKeyName, Formvalue)NativeGlobal
intfunctionGetIntValue(stringFileName, stringKeyName, intmissing=0)NativeGlobal
floatfunctionGetFloatValue(stringFileName, stringKeyName, floatmissing=0.0)NativeGlobal
stringfunctionGetStringValue(stringFileName, stringKeyName, stringmissing="")NativeGlobal
FormfunctionGetFormValue(stringFileName, stringKeyName, Formmissing=NONE)NativeGlobal
boolfunctionUnsetIntValue(stringFileName, stringKeyName)NativeGlobal
boolfunctionUnsetFloatValue(stringFileName, stringKeyName)NativeGlobal
boolfunctionUnsetStringValue(stringFileName, stringKeyName)NativeGlobal
boolfunctionUnsetFormValue(stringFileName, stringKeyName)NativeGlobal
boolfunctionHasIntValue(stringFileName, stringKeyName)NativeGlobal
boolfunctionHasFloatValue(stringFileName, stringKeyName)NativeGlobal
boolfunctionHasStringValue(stringFileName, stringKeyName)NativeGlobal
boolfunctionHasFormValue(stringFileName, stringKeyName)NativeGlobal
intfunctionIntListAdd(stringFileName, stringKeyName, intvalue, boolallowDuplicate=true)NativeGlobal
intfunctionFloatListAdd(stringFileName, stringKeyName, floatvalue, boolallowDuplicate=true)NativeGlobal
intfunctionStringListAdd(stringFileName, stringKeyName, stringvalue, boolallowDuplicate=true)NativeGlobal
intfunctionFormListAdd(stringFileName, stringKeyName, Formvalue, boolallowDuplicate=true)NativeGlobal
intfunctionIntListGet(stringFileName, stringKeyName, intindex)NativeGlobal
floatfunctionFloatListGet(stringFileName, stringKeyName, intindex)NativeGlobal
stringfunctionStringListGet(stringFileName, stringKeyName, intindex)NativeGlobal
FormfunctionFormListGet(stringFileName, stringKeyName, intindex)NativeGlobal
intfunctionIntListSet(stringFileName, stringKeyName, intindex, intvalue)NativeGlobal
floatfunctionFloatListSet(stringFileName, stringKeyName, intindex, floatvalue)NativeGlobal
stringfunctionStringListSet(stringFileName, stringKeyName, intindex, stringvalue)NativeGlobal
FormfunctionFormListSet(stringFileName, stringKeyName, intindex, Formvalue)NativeGlobal
intfunctionIntListRemove(stringFileName, stringKeyName, intvalue, boolallInstances=true)NativeGlobal
intfunctionFloatListRemove(stringFileName, stringKeyName, floatvalue, boolallInstances=true)NativeGlobal
intfunctionStringListRemove(stringFileName, stringKeyName, stringvalue, boolallInstances=true)NativeGlobal
intfunctionFormListRemove(stringFileName, stringKeyName, Formvalue, boolallInstances=true)NativeGlobal
boolfunctionIntListInsertAt(stringFileName, stringKeyName, intindex, intvalue)NativeGlobal
boolfunctionFloatListInsertAt(stringFileName, stringKeyName, intindex, floatvalue)NativeGlobal
boolfunctionStringListInsertAt(stringFileName, stringKeyName, intindex, stringvalue)NativeGlobal
boolfunctionFormListInsertAt(stringFileName, stringKeyName, intindex, Formvalue)NativeGlobal
boolfunctionIntListRemoveAt(stringFileName, stringKeyName, intindex)NativeGlobal
boolfunctionFloatListRemoveAt(stringFileName, stringKeyName, intindex)NativeGlobal
boolfunctionStringListRemoveAt(stringFileName, stringKeyName, intindex)NativeGlobal
boolfunctionFormListRemoveAt(stringFileName, stringKeyName, intindex)NativeGlobal
intfunctionIntListClear(stringFileName, stringKeyName)NativeGlobal
intfunctionFloatListClear(stringFileName, stringKeyName)NativeGlobal
intfunctionStringListClear(stringFileName, stringKeyName)NativeGlobal
intfunctionFormListClear(stringFileName, stringKeyName)NativeGlobal
intfunctionIntListCount(stringFileName, stringKeyName)NativeGlobal
intfunctionFloatListCount(stringFileName, stringKeyName)NativeGlobal
intfunctionStringListCount(stringFileName, stringKeyName)NativeGlobal
intfunctionFormListCount(stringFileName, stringKeyName)NativeGlobal
intfunctionIntListCountValue(stringFileName, stringKeyName, intvalue, boolexclude=false)NativeGlobal
intfunctionFloatListCountValue(stringFileName, stringKeyName, floatvalue, boolexclude=false)NativeGlobal
intfunctionStringListCountValue(stringFileName, stringKeyName, stringvalue, boolexclude=false)NativeGlobal
intfunctionFormListCountValue(stringFileName, stringKeyName, Formvalue, boolexclude=false)NativeGlobal
intfunctionIntListFind(stringFileName, stringKeyName, intvalue)NativeGlobal
intfunctionFloatListFind(stringFileName, stringKeyName, floatvalue)NativeGlobal
intfunctionStringListFind(stringFileName, stringKeyName, stringvalue)NativeGlobal
intfunctionFormListFind(stringFileName, stringKeyName, Formvalue)NativeGlobal
boolfunctionIntListHas(stringFileName, stringKeyName, intvalue)NativeGlobal
boolfunctionFloatListHas(stringFileName, stringKeyName, floatvalue)NativeGlobal
boolfunctionStringListHas(stringFileName, stringKeyName, stringvalue)NativeGlobal
boolfunctionFormListHas(stringFileName, stringKeyName, Formvalue)NativeGlobal
voidfunctionIntListSlice(stringFileName, stringKeyName, int[]slice, intstartIndex=0)NativeGlobal
voidfunctionFloatListSlice(stringFileName, stringKeyName, float[]slice, intstartIndex=0)NativeGlobal
voidfunctionStringListSlice(stringFileName, stringKeyName, string[]slice, intstartIndex=0)NativeGlobal
voidfunctionFormListSlice(stringFileName, stringKeyName, Form[]slice, intstartIndex=0)NativeGlobal
intfunctionIntListResize(stringFileName, stringKeyName, inttoLength, intfiller=0)NativeGlobal
intfunctionFloatListResize(stringFileName, stringKeyName, inttoLength, floatfiller=0.0)NativeGlobal
intfunctionStringListResize(stringFileName, stringKeyName, inttoLength, stringfiller="")NativeGlobal
intfunctionFormListResize(stringFileName, stringKeyName, inttoLength, Formfiller=NONE)NativeGlobal
boolfunctionIntListCopy(stringFileName, stringKeyName, int[]copy)NativeGlobal
boolfunctionFloatListCopy(stringFileName, stringKeyName, float[]copy)NativeGlobal
boolfunctionStringListCopy(stringFileName, stringKeyName, string[]copy)NativeGlobal
boolfunctionFormListCopy(stringFileName, stringKeyName, Form[]copy)NativeGlobal
int[]functionIntListToArray(stringFileName, stringKeyName)NativeGlobal
float[]functionFloatListToArray(stringFileName, stringKeyName)NativeGlobal
string[]functionStringListToArray(stringFileName, stringKeyName)NativeGlobal
Form[]functionFormListToArray(stringFileName, stringKeyName)NativeGlobal
intfunctionAdjustIntValue(stringFileName, stringKeyName, intamount)NativeGlobal
floatfunctionAdjustFloatValue(stringFileName, stringKeyName, floatamount)NativeGlobal
intfunctionIntListAdjust(stringFileName, stringKeyName, intindex, intamount)NativeGlobal
floatfunctionFloatListAdjust(stringFileName, stringKeyName, intindex, floatamount)NativeGlobal
intfunctionIntListRandom(stringFileName, stringKeyName)NativeGlobal
floatfunctionFloatListRandom(stringFileName, stringKeyName)NativeGlobal
stringfunctionStringListRandom(stringFileName, stringKeyName)NativeGlobal
FormfunctionFormListRandom(stringFileName, stringKeyName)NativeGlobal
intfunctionCountIntValuePrefix(stringFileName, stringPrefixKey)NativeGlobal
intfunctionCountFloatValuePrefix(stringFileName, stringPrefixKey)NativeGlobal
intfunctionCountStringValuePrefix(stringFileName, stringPrefixKey)NativeGlobal
intfunctionCountFormValuePrefix(stringFileName, stringPrefixKey)NativeGlobal
intfunctionCountIntListPrefix(stringFileName, stringPrefixKey)NativeGlobal
intfunctionCountFloatListPrefix(stringFileName, stringPrefixKey)NativeGlobal
intfunctionCountStringListPrefix(stringFileName, stringPrefixKey)NativeGlobal
intfunctionCountFormListPrefix(stringFileName, stringPrefixKey)NativeGlobal
intfunctionCountAllPrefix(stringFileName, stringPrefixKey)NativeGlobal
voidfunctionSetPathIntValue(stringFileName, stringPath, intvalue)NativeGlobal
voidfunctionSetPathFloatValue(stringFileName, stringPath, floatvalue)NativeGlobal
voidfunctionSetPathStringValue(stringFileName, stringPath, stringvalue)NativeGlobal
voidfunctionSetPathFormValue(stringFileName, stringPath, Formvalue)NativeGlobal
boolfunctionSetRawPathValue(stringFileName, stringPath, stringRawJSON)NativeGlobal
intfunctionGetPathIntValue(stringFileName, stringPath, intmissing=0)NativeGlobal
floatfunctionGetPathFloatValue(stringFileName, stringPath, floatmissing=0.0)NativeGlobal
stringfunctionGetPathStringValue(stringFileName, stringPath, stringmissing="")NativeGlobal
FormfunctionGetPathFormValue(stringFileName, stringPath, Formmissing=NONE)NativeGlobal
boolfunctionGetPathBoolValue(stringFileName, stringPath, boolmissing=false)Global
int[]functionPathIntElements(stringFileName, stringPath, intinvalidType=0)NativeGlobal
float[]functionPathFloatElements(stringFileName, stringPath, floatinvalidType=0.0)NativeGlobal
string[]functionPathStringElements(stringFileName, stringPath, stringinvalidType="")NativeGlobal
Form[]functionPathFormElements(stringFileName, stringPath, ForminvalidType=NONE)NativeGlobal
intfunctionFindPathIntElement(stringFileName, stringPath, inttoFind)NativeGlobal
intfunctionFindPathFloatElement(stringFileName, stringPath, floattoFind)NativeGlobal
intfunctionFindPathStringElement(stringFileName, stringPath, stringtoFind)NativeGlobal
intfunctionFindPathFormElement(stringFileName, stringPath, FormtoFind)NativeGlobal
intfunctionPathCount(stringFileName, stringPath)NativeGlobal
string[]functionPathMembers(stringFileName, stringPath)NativeGlobal
boolfunctionCanResolvePath(stringFileName, stringPath)NativeGlobal
boolfunctionIsPathString(stringFileName, stringPath)NativeGlobal
boolfunctionIsPathNumber(stringFileName, stringPath)NativeGlobal
boolfunctionIsPathForm(stringFileName, stringPath)NativeGlobal
boolfunctionIsPathBool(stringFileName, stringPath)NativeGlobal
boolfunctionIsPathArray(stringFileName, stringPath)NativeGlobal
boolfunctionIsPathObject(stringFileName, stringPath)NativeGlobal
voidfunctionSetPathIntArray(stringFileName, stringPath, int[]arr, boolappend=false)NativeGlobal
voidfunctionSetPathFloatArray(stringFileName, stringPath, float[]arr, boolappend=false)NativeGlobal
voidfunctionSetPathStringArray(stringFileName, stringPath, string[]arr, boolappend=false)NativeGlobal
voidfunctionSetPathFormArray(stringFileName, stringPath, Form[]arr, boolappend=false)NativeGlobal
voidfunctionClearPath(stringFileName, stringPath)NativeGlobal
voidfunctionClearPathIndex(stringFileName, stringPath, intIndex)NativeGlobal
voidfunctionClearAll(stringFileName)NativeGlobal

Debug use

Some data provided by the Skyrim Creation Kit Wiki. Licensed under the Creative Commons Attribution-ShareAlike license.