Navigation
API > API/Plugins > API/Plugins/GameplayAbilities
Describes a FGameplayAttributeData or float property inside an attribute set. Using this provides editor UI and helper functions
| Name | FGameplayAttribute |
| Type | struct |
| Header File | /Engine/Plugins/Runtime/GameplayAbilities/Source/GameplayAbilities/Public/AttributeSet.h |
| Include Path | #include "AttributeSet.h" |
Syntax
USTRUCT (BlueprintType )
struct FGameplayAttribute
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FGameplayAttribute
(
FProperty* NewProperty |
AttributeSet.h | ||
| AttributeSet.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| AttributeName | FString | Name of the attribute, usually the same as property name | AttributeSet.h |
|
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| Attribute | TFieldPath< FProperty > | AttributeSet.h |
|
|
| AttributeOwner | TObjectPtr< UStruct > | AttributeSet.h |
|
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
UClass * GetAttributeSetClass() |
Returns the AttributeSet subclass holding this attribute | AttributeSet.h | |
FGameplayAttributeData * GetGameplayAttributeData
(
UAttributeSet* Src |
AttributeSet.h | ||
const FGameplayAttributeData * GetGameplayAttributeData
(
const UAttributeSet* Src |
Returns the AttributeData, will fail if this is a float attribute | AttributeSet.h | |
const FGameplayAttributeData * GetGameplayAttributeDataChecked
(
const UAttributeSet* Src |
AttributeSet.h | ||
FGameplayAttributeData * GetGameplayAttributeDataChecked
(
UAttributeSet* Src |
AttributeSet.h | ||
FString GetName() |
Returns name of attribute, usually the same as the property | AttributeSet.h | |
float GetNumericValue
(
const UAttributeSet* Src |
Returns the current value of an attribute | AttributeSet.h | |
float GetNumericValueChecked
(
const UAttributeSet* Src |
AttributeSet.h | ||
FProperty * GetUProperty() |
Returns raw property | AttributeSet.h | |
bool IsSystemAttribute() |
Returns true if this is one of the special attributes defined on the AbilitySystemComponent itself | AttributeSet.h | |
bool IsValid() |
Returns true if our Attribute has a valid resolved Field | AttributeSet.h | |
void PostSerialize
(
const FArchive& Ar |
Custom serialization | AttributeSet.h | |
void SetNumericValueChecked
(
float& NewValue, |
Modifies the current value of an attribute, will not modify base value if that is supported | AttributeSet.h | |
void SetUProperty
(
FProperty* NewProperty |
Set up from a FProperty inside a set | AttributeSet.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static void GetAllAttributeProperties
(
TArray< FProperty* >& OutProperties, |
In editor, this will filter out properties with meta tag "HideInDetailsView" or equal to FilterMetaStr. | AttributeSet.h | |
static bool IsGameplayAttributeDataProperty
(
const FProperty* Property |
Returns true if the variable associated with Property is of type FGameplayAttributeData or one of its subclasses | AttributeSet.h |
Operators
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
bool operator!=
(
const FGameplayAttribute& Other |
AttributeSet.h | ||
bool operator==
(
const FGameplayAttribute& Other |
Equality/Inequality operators | AttributeSet.h |