Navigation
API > API/Plugins > API/Plugins/GameplayAbilities
Active GameplayEffects Container -Bucket of ActiveGameplayEffects -Needed for FFastArraySerialization
This should only be used by UAbilitySystemComponent. All of this could just live in UAbilitySystemComponent except that we need a distinct USTRUCT to implement FFastArraySerializer.
The preferred way to iterate through the ActiveGameplayEffectContainer is with CreateConstIterator/CreateIterator or stl style range iteration:
for (const FActiveGameplayEffect& Effect : this) {} for (auto It = CreateConstIterator(); It; ++It) {}
| Name | FActiveGameplayEffectsContainer |
| Type | struct |
| Header File | /Engine/Plugins/Runtime/GameplayAbilities/Source/GameplayAbilities/Public/GameplayEffect.h |
| Include Path | #include "GameplayEffect.h" |
Syntax
USTRUCT ()
struct FActiveGameplayEffectsContainer : public FFastArraySerializer
Inheritance Hierarchy
- FFastArraySerializer → FActiveGameplayEffectsContainer
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FActiveGameplayEffectsContainer() |
GameplayEffect.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
~FActiveGameplayEffectsContainer() |
GameplayEffect.h |
Structs
| Name | Remarks |
|---|---|
| DebugExecutedGameplayEffectData |
Typedefs
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| ConstIterator | FActiveGameplayEffectIterator< const FActiveGameplayEffect, FActiveGameplayEffectsContainer > | GameplayEffect.h | |
| Iterator | FActiveGameplayEffectIterator< FActiveGameplayEffect, FActiveGameplayEffectsContainer > | GameplayEffect.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| DebugExecutedGameplayEffects | TArray< DebugExecutedGameplayEffectData > | Stores a record of gameplay effects that have executed and their results. Useful for debugging | GameplayEffect.h | |
| OnActiveGameplayEffectRemovedDelegate | FOnGivenActiveGameplayEffectRemoved | GameplayEffect.h | ||
| Owner | UAbilitySystemComponent * | GameplayEffect.h | ||
| OwnerIsNetAuthority | bool | GameplayEffect.h |
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| AttributeAggregatorMap | TMap< FGameplayAttribute, FAggregatorRef > | GameplayEffect.h | ||
| AttributeChangeDelegates | TMap< FGameplayAttribute, FOnGameplayAttributeChange > | DEPRECATED: use AttributeValueChangeDelegates. | GameplayEffect.h | |
| AttributeValueChangeDelegates | TMap< FGameplayAttribute, FOnGameplayAttributeValueChange > | GameplayEffect.h | ||
| bIsUsingReplicationCondition | uint8 | GameplayEffect.h | ||
| CurrentModcallbackData | const FGameplayEffectModCallbackData * | Cached pointer to current mod data needed for callbacks. | GameplayEffect.h | |
| CustomMagnitudeClassDependencies | TMap< FObjectKey, FCustomModifierDependencyHandle > | Mapping of custom gameplay modifier magnitude calculation class to dependency handles for triggering updates on external delegates firing | GameplayEffect.h | |
| GameplayEffects_Internal | TArray< FActiveGameplayEffect > | Our active list of Effects. | GameplayEffect.h | |
| NumConsecutiveUnmappedReferencesDebug | uint32 | GameplayEffect.h | ||
| PendingGameplayEffectHead | FActiveGameplayEffect * | GameplayEffect.h | ||
| PendingGameplayEffectNext | FActiveGameplayEffect ** | GameplayEffect.h | ||
| PendingRemoves | int32 | GameplayEffect.h | ||
| ScopedLockCount | int32 | GameplayEffect.h | ||
| SourceStackingMap | TMap< TWeakObjectPtr< UGameplayEffect >, TArray< FActiveGameplayEffectHandle > > | A map to manage stacking while we are the source | GameplayEffect.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FActiveGameplayEffect * ApplyGameplayEffectSpec
(
const FGameplayEffectSpec& Spec, |
GameplayEffect.h | ||
void ApplyModToAttribute
(
const FGameplayAttribute& Attribute, |
Actually applies given mod to the attribute | GameplayEffect.h | |
void AttemptRemoveActiveEffectsOnEffectApplication
(
const FGameplayEffectSpec& InSpec, |
Method called during effect application to process if any active effects should be removed from this effects application | GameplayEffect.h | |
bool CanApplyAttributeModifiers
(
const UGameplayEffect* GameplayEffect, |
GameplayEffect.h | ||
void CaptureAttributeForGameplayEffect
(
FGameplayEffectAttributeCaptureSpec& OutCaptureSpec |
Populate the specified capture spec with the data necessary to capture an attribute from the container | GameplayEffect.h | |
void CheckDuration
(
FActiveGameplayEffectHandle Handle |
GameplayEffect.h | ||
void CloneFrom
(
const FActiveGameplayEffectsContainer& Source |
Performs a deep copy on the source container, duplicating all gameplay effects and reconstructing the attribute aggregator map to match the passed in source. | GameplayEffect.h | |
ConstIterator CreateConstIterator() |
GameplayEffect.h | ||
Iterator CreateIterator() |
GameplayEffect.h | ||
void DebugCyclicAggregatorBroadcasts
(
FAggregator* Aggregator |
GameplayEffect.h | ||
void DecrementLock() |
GameplayEffect.h | ||
void DescribeSelfToVisLog
(
FVisualLogEntry* Snapshot |
Report our current state to the VisLog | GameplayEffect.h | |
void ExecuteActiveEffectsFrom
(
FGameplayEffectSpec& Spec, |
This is the main function that executes a GameplayEffect on Attributes and ActiveGameplayEffects | GameplayEffect.h | |
void ExecutePeriodicGameplayEffect
(
FActiveGameplayEffectHandle Handle |
GameplayEffect.h | ||
int32 GetActiveEffectCount
(
const FGameplayEffectQuery& Query, |
Get the count of the effects matching the specified query (including stack count) | GameplayEffect.h | |
TArray< FActiveGameplayEffectHandle > GetActiveEffects
(
const FGameplayEffectQuery& Query |
GameplayEffect.h | ||
TArray< float > GetActiveEffectsDuration
(
const FGameplayEffectQuery& Query |
GameplayEffect.h | ||
float GetActiveEffectsEndTime
(
const FGameplayEffectQuery& Query, |
GameplayEffect.h | ||
bool GetActiveEffectsEndTimeAndDuration
(
const FGameplayEffectQuery& Query, |
GameplayEffect.h | ||
TArray< float > GetActiveEffectsTimeRemaining
(
const FGameplayEffectQuery& Query |
GameplayEffect.h | ||
TArray< TPair< float, float > > GetActiveEffectsTimeRemainingAndDuration
(
const FGameplayEffectQuery& Query |
GameplayEffect.h | ||
const FActiveGameplayEffect * GetActiveGameplayEffect
(
const FActiveGameplayEffectHandle Handle |
GameplayEffect.h | ||
FActiveGameplayEffect * GetActiveGameplayEffect
(
const FActiveGameplayEffectHandle Handle |
GameplayEffect.h | ||
void GetActiveGameplayEffectDataByAttribute
(
TMultiMap< FGameplayAttribute, FActiveGameplayEffectsContainer::DebugExecutedGameplayEffectData >& ... |
GameplayEffect.h | ||
TArray< FActiveGameplayEffectHandle > GetAllActiveEffectHandles() |
Returns an array of all of the active gameplay effect handles | GameplayEffect.h | |
void GetAllActiveGameplayEffectSpecs
(
TArray< FGameplayEffectSpec >& OutSpecCopies |
GameplayEffect.h | ||
float GetAttributeBaseValue
(
FGameplayAttribute Attribute |
GameplayEffect.h | ||
float GetEffectContribution
(
const FAggregatorEvaluateParameters& Parameters, |
GameplayEffect.h | ||
FOnGameplayAttributeValueChange & GetGameplayAttributeValueChangeDelegate
(
FGameplayAttribute Attribute |
GameplayEffect.h | ||
float GetGameplayEffectMagnitude
(
FActiveGameplayEffectHandle Handle, |
GameplayEffect.h | ||
const FGameplayTagContainer * GetGameplayEffectSourceTagsFromHandle
(
FActiveGameplayEffectHandle Handle |
Get the source tags from the gameplay spec represented by the specified handle, if possible | GameplayEffect.h | |
void GetGameplayEffectStartTimeAndDuration
(
FActiveGameplayEffectHandle Handle, |
GameplayEffect.h | ||
const FGameplayTagContainer * GetGameplayEffectTargetTagsFromHandle
(
FActiveGameplayEffectHandle Handle |
Get the target tags from the gameplay spec represented by the specified handle, if possible | GameplayEffect.h | |
int32 GetNumGameplayEffects () |
Returns the total number of gameplay effects. | GameplayEffect.h | |
| Returns which ELifetimeCondition can be used for this instance to replicate to relevant connections. | GameplayEffect.h | ||
float GetServerWorldTime() |
GameplayEffect.h | ||
float GetWorldTime() |
GameplayEffect.h | ||
bool HasApplicationImmunityToSpec
(
const FGameplayEffectSpec& SpecToApply, |
GameplayEffect.h | ||
bool HasPredictedEffectWithPredictedKey
(
FPredictionKey PredictionKey |
GameplayEffect.h | ||
bool HasReceivedEffectWithPredictedKey
(
FPredictionKey PredictionKey |
GameplayEffect.h | ||
void IncrementLock() |
GameplayEffect.h | ||
bool IsNetAuthority() |
GameplayEffect.h | ||
bool IsServerWorldTimeAvailable() |
GameplayEffect.h | ||
bool IsUsingReplicationCondition() |
Return whether the container is using COND_Dynamic and setting the proper condition at runtime. | GameplayEffect.h | |
void ModifyActiveEffectStartTime
(
FActiveGameplayEffectHandle Handle, |
GameplayEffect.h | ||
bool NetDeltaSerialize
(
FNetDeltaSerializeInfo& DeltaParms |
GameplayEffect.h | ||
void PostReplicatedReceive
(
const FFastArraySerializer::FPostReplicatedReceiveParameters& Parameters |
Called every time data has been modified by the FastArraySerializer | GameplayEffect.h | |
void PredictivelyExecuteEffectSpec
(
FGameplayEffectSpec& Spec, |
Predictively execute a given effect spec. | GameplayEffect.h | |
void PrintAllGameplayEffects() |
GameplayEffect.h | ||
void RecomputeStartWorldTimes
(
const float WorldTime, |
Recomputes the start time for all active abilities | GameplayEffect.h | |
FOnGameplayAttributeChange & RegisterGameplayAttributeEvent
(
FGameplayAttribute Attribute |
GameplayEffect.h | ||
void RegisterWithOwner
(
UAbilitySystemComponent* Owner |
GameplayEffect.h | ||
int32 RemoveActiveEffects
(
const FGameplayEffectQuery& Query, |
GameplayEffect.h | ||
bool RemoveActiveGameplayEffect
(
FActiveGameplayEffectHandle Handle, |
Called on server to remove a GameplayEffect and on owning client for Post-Prediction cleanup | GameplayEffect.h | |
void SetActiveGameplayEffectLevel
(
FActiveGameplayEffectHandle ActiveHandle, |
GameplayEffect.h | ||
void SetAttributeBaseValue
(
FGameplayAttribute Attribute, |
GameplayEffect.h | ||
void SetBaseAttributeValueFromReplication
(
const FGameplayAttribute& Attribute, |
GameplayEffect.h | ||
void SetIsUsingReplicationCondition
(
bool bInIsUsingReplicationCondition |
Set whether the container is using COND_Dynamic and setting the proper condition at runtime. | GameplayEffect.h | |
void Uninitialize() |
GameplayEffect.h | ||
void UpdateActiveGameplayEffectSetByCallerMagnitude
(
FActiveGameplayEffectHandle ActiveHandle, |
Update a set-by-caller magnitude for the active effect to match the new value, if possible | GameplayEffect.h | |
void UpdateActiveGameplayEffectSetByCallerMagnitudes
(
FActiveGameplayEffectHandle ActiveHandle, |
Update set-by-caller magnitudes for the active effect to match the new values, if possible; Replaces existing values | GameplayEffect.h |