Navigation
API > API/Plugins > API/Plugins/Niagara > API/Plugins/Niagara/UNiagaraDataChannelLibrary
Description
LEGACY FUNCTION: Please use non-legacy version. Subscribes to a single data channel and calls a delegate every times new data is written to the data channel.
| Name | SubscribeToNiagaraDataChannel |
| Type | function |
| Header File | /Engine/Plugins/FX/Niagara/Source/Niagara/Public/NiagaraDataChannelFunctionLibrary.h |
| Include Path | #include "NiagaraDataChannelFunctionLibrary.h" |
| Source | /Engine/Plugins/FX/Niagara/Source/Niagara/Private/NiagaraDataChannelFunctionLibrary.cpp |
UFUNCTION (BlueprintCallable, Category=NiagaraDataChannel,
Meta=(DisplayName="Subscribe To Niagara Data Channel (Legacy)", Keywords="niagara DataChannel event reader subscription delegate listener updates", WorldContext="WorldContextObject", UnsafeDuringActorConstruction="true"))
static void SubscribeToNiagaraDataChannel
(
const UObject * WorldContextObject,
const UNiagaraDataChannelAsset * Channel,
FNiagaraDataChannelSearchParameters SearchParams,
const FOnNewNiagaraDataChannelPublish & UpdateDelegate,
int32 & UnsubscribeToken
)
Parameters
| Name | Remarks |
|---|---|
| WorldContextObject | World to execute in |
| Channel | The channel to subscribe to for updates |
| SearchParams | Parameters used when retrieving a specific set of Data Channel Data to read - only used by some types of data channels, like the island types. |
| UpdateDelegate | The delegate to be called when new data is available in the data channel. Can be called multiple times per tick. |
| UnsubscribeToken | This token can be used to unsubscribe from the data channel. |