set_niagara_data_interface_asset
Assigns an asset to a Niagara user-parameter data interface property, verifying read-back and saving the recompiled system.
Instructions
Points an object property of a user-parameter data interface on a Niagara system at an asset (e.g. the mesh of a StaticMesh DI, the texture of a Texture DI), inside an undo transaction, reads it back, requests a system recompile and saves the system; success requires the read-back and the save. The DI must already exist (add_niagara_data_interface); property_name picks the property, else the first hard object property in reflection order. The asset must load and be of the property's class, else it is an error and nothing is written. For non-asset fields use set_niagara_data_interface_default.
Returns: { system_path: string, parameter_name: string, property_name: string, asset_path: string, set: bool (the property reads back the asset), saved: bool, save_error?: string }
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| asset_path | No | Asset path of the UObject to assign (must be the right subclass) | |
| system_path | Yes | Asset path of the Niagara System. | |
| property_name | No | Optional FObjectProperty name on the DI; defaults to the first FObjectProperty | |
| parameter_name | Yes | Short name of the user-parameter DI to mutate |