UAbilitySystemComponent::GetGameplayEffectCount

Get the count of the specified source effect on the ability system component.

Windows
MacOS
Linux

References

Module

GameplayAbilities

Header

/Engine/Plugins/Runtime/GameplayAbilities/Source/GameplayAbilities/Public/AbilitySystemComponent.h

Include

#include "AbilitySystemComponent.h"

Source

/Engine/Plugins/Runtime/GameplayAbilities/Source/GameplayAbilities/Private/AbilitySystemComponent.cpp

Syntax

[UFUNCTION](Programming/UnrealArchitecture/Reference/Functions)(BlueprintCallable, BlueprintPure, Category=GameplayEffects)
int32 GetGameplayEffectCount
(
    TSubclassOf< UGameplayEffect > SourceGameplayEffect,
    UAbilitySystemComponent * OptionalInstigatorFilterComponent,
    bool bEnforceOnGoingCheck
)

Remarks

Get the count of the specified source effect on the ability system component. For non-stacking effects, this is the sum of all active instances. For stacking effects, this is the sum of all valid stack counts. If an instigator is specified, only effects from that instigator are counted.

Returns

Count of the specified source effect

Parameters

Parameter

Description

SourceGameplayEffect

Effect to get the count of

OptionalInstigatorFilterComponent

If specified, only count effects applied by this ability system component

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss