Script Mods (Replace script data)

Updated for version 3.38.

Module Definition

The module is inherited from ModuleBase. So base parameters can be found there.

Module name

The name of the module you use as the meta of the module definition is 'ScriptMods' or 'ScriptReplacementsModule' if _force_search is set to true in the module definition.

XML Structure

There are two ways of modding scriptdata:

File

<ScriptMods directory>
    <mod file type target_path target_type .../>
</ScriptMods>

Direct

<ScriptMods directory>
    <mod target_path target_type ...>
        <tbl>
        </tbl>
    </mod>
</ScriptMods>

<ScriptMods directory>

<mod file type target_path target_type, ...>

Options / Additional parameters

Examples

In both examples is what you would put inside your main node within your mod config

File

For this example your script mod would be like this: mods/MyMod/scriptdata/start_menu.xml. If you are using this module in a BLT mod.

<ScriptMods directory="scriptdata">
    <mod file="start_menu.xml" type="custom_xml" target_path="gamedata/menus/start_menu" target_type="menu"/>
<ScriptMods/>

Direct

<ScriptMods>
    <mod target_file="units/payday2/characters/ragdoll" target_type="sequence_manager" merge_mode="script_merge">
        <tbl>
            <table search="unit">
                <table mode="remove" search="sequence;name='\'freeze_ragdoll\''"/>
            </table>
        </tbl>
    </mod>
</ScriptMods>

Last updated