FNiagaraEditorUtilities::AddParameter

Adds a new Parameter to a target ParameterStore with an undo/redo transaction and name collision handling.

Choose your operating system:

Windows

macOS

Linux

References

Module

NiagaraEditor

Header

/Engine/Plugins/FX/Niagara/Source/NiagaraEditor/Public/NiagaraEditorUtilities.h

Include

#include "NiagaraEditorUtilities.h"

Source

/Engine/Plugins/FX/Niagara/Source/NiagaraEditor/Private/NiagaraEditorUtilities.cpp

Syntax

namespace FNiagaraEditorUtilities
{
    bool FNiagaraEditorUtilities::AddParameter
    (
        FNiagaraVariable & NewParameterVariable,
        FNiagaraParameterStore & TargetParameterStore,
        UObject & ParameterStoreOwner,
        UNiagaraStackEditorData * StackEditorData
    )
}

Remarks

Adds a new Parameter to a target ParameterStore with an undo/redo transaction and name collision handling.

Returns

Bool for whether adding the parameter succeeded.

Parameters

Parameter

Description

NewParameterVariable

The FNiagaraVariable to be added to TargetParameterStore. MUST be a unique object, do not pass an existing reference.

TargetParameterStore

The ParameterStore to receive NewVariable.

ParameterStoreOwner

The UObject to call Modify() on for the undo/redo transaction of adding NewVariable.

StackEditorData

The editor data used to mark the newly added FNiagaraVariable in the Stack for renaming.