Dependencies: lib_2da, lib_anon, lib_array, lib_fn, lib_ini, lib_sfo, lib_struct, lib_sugar, lib_tools
add_to_statdesc(start_row:i=190, string:i="-1", bam:s="****")=(stat_num:s) action
add_to_statdesc_helper(start_row:i, rowcount:i)=(stat_num:s, row:s) patch
ext(uppercase:b)=(ext:s, version:s) patch
Returns the extension of the currently-being-patched file, if we can tell. (we can tell for 2da, are, chr, cre, dlg, gam, itm, pro, spl, sto, vef, vvc, wed, and wmp) Also return its version
By default we return lowercase; if you want it in uppercase, set uppercase=1.
insert_script(script_array:s, script:s, arguments:s, loc:s)=(script_array:a) dimorphic
Given a numbered-from-0 array of scripts 'script_array', and a new script 'script' (synonym: 'arguments'), insert the new script in position 'loc'. Insert position can be 'high', 'low', 'after x' (defaults to 'high' if x isn't present), or 'before x' (defaults to 'low' if x isn't present). If there isn't space, merge the two lowest scripts to make space.
install(overwrite:b=1, arguments:s, files:s, file:s, location:s, locbase:s, path:s)=() action
'arguments' (synonym: 'files'; synonym:'file') is a list of files (including extensions) located at the location given by path/location/locbase. Each is copied over to the override; if any are BAF/D, they are COMPILE EVALUATE_BUFFERred. If none of 'location', 'locbase', and 'path' are set, set location=resource. If overwrite=0, don't overwrite already-present files. (Does not affect scripts.)
merge_scripts(top:s, bottom:s, script:s)=(script:s) dimorphic
If both 'top' and 'bottom' exist, merge them into a new script, and give it a guaranteed-unique name unless a name is specified. In any case, return the name. If one doesn't exist, return the name of the other.
resolve_splprot_entry(stat:i, val:i, value:i, relation_number:i, relation:s)=(value:s) dimorphic
Given 'stat', 'val' (legacy synonym: 'value'), and either 'relation_number' or 'relation', return an appropriate entry in splprot.2da, adding it if necessary. (see IESDP opcode documentation for opcode 324).
'Relation' can be:
resolve_statdesc(check_first:i="-1", strref:i="-1", string:s, bam:s, bam_name:s, path:s, location:s, locbase:s)=(stat_num:s) dimorphic