Navigation
API > API/Runtime > API/Runtime/GameplayTags
A single gameplay tag, which represents a hierarchical name of the form x.y that is registered in the GameplayTagsManager You can filter the gameplay tags displayed in the editor using, meta = (Categories = "Tag1.Tag2.Tag3"))
| Name | FGameplayTag |
| Type | struct |
| Header File | /Engine/Source/Runtime/GameplayTags/Classes/GameplayTagContainer.h |
| Include Path | #include "GameplayTagContainer.h" |
Syntax
USTRUCT (BlueprintType ,
Meta=(HasNativeMake="/Script/GameplayTags.BlueprintGameplayTagLibrary.MakeLiteralGameplayTag", HasNativeBreak="/Script/GameplayTags.BlueprintGameplayTagLibrary.GetTagName", DisableSplitPin))
struct FGameplayTag
Derived Classes
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FGameplayTag
(
const FName& InTagName |
Intentionally private so only the tag manager can use | GameplayTagContainer.h | |
FGameplayTag () |
Constructors | GameplayTagContainer.h |
Constants
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| EmptyTag | const FGameplayTag | An empty Gameplay Tag | GameplayTagContainer.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void FromExportString
(
const FString& ExportString, |
Sets from a ImportText string, used in asset registry | GameplayTagContainer.h | |
| Returns a new tag container that includes this tag and all parent tags as explicitly added tags. | GameplayTagContainer.h | ||
FGameplayTagContainer GetSingleTagContainer() |
Returns a GameplayTagContainer containing only this tag | GameplayTagContainer.h | |
| Parses the tag name and returns the name of the leaf. | GameplayTagContainer.h | ||
FName GetTagName() |
Get the tag represented as a name | GameplayTagContainer.h | |
bool ImportTextItem
(
const TCHAR*& Buffer, |
Handles importing tag strings without (TagName=) in it | GameplayTagContainer.h | |
bool IsValid() |
Returns whether the tag is valid or not; Invalid tags are set to NAME_None and do not exist in the game-specific global dictionary | GameplayTagContainer.h | |
bool MatchesAny
(
const FGameplayTagContainer& ContainerToCheck |
Checks if this tag matches ANY of the tags in the specified container, also checks against our parent tags "A.1".MatchesAny({"A","B"}) will return True, "A".MatchesAny({"A.1","B"}) will return False If ContainerToCheck is empty/invalid it will always return False | GameplayTagContainer.h | |
bool MatchesAnyExact
(
const FGameplayTagContainer& ContainerToCheck |
Checks if this tag matches ANY of the tags in the specified container, only allowing exact matches "A.1".MatchesAny({"A","B"}) will return False If ContainerToCheck is empty/invalid it will always return False | GameplayTagContainer.h | |
bool MatchesTag
(
const FGameplayTag& TagToCheck |
Determine if this tag matches TagToCheck, expanding out parent tags "A.1".MatchesTag("A") will return True, "A".MatchesTag("A.1") will return False If TagToCheck is not Valid it will always return False | GameplayTagContainer.h | |
int32 MatchesTagDepth
(
const FGameplayTag& TagToCheck |
Check to see how closely two FGameplayTags match. | GameplayTagContainer.h | |
bool MatchesTagExact
(
const FGameplayTag& TagToCheck |
Determine if TagToCheck is valid and exactly matches this tag "A.1".MatchesTagExact("A") will return False If TagToCheck is not Valid it will always return False | GameplayTagContainer.h | |
bool NetSerialize
(
FArchive& Ar, |
Overridden for fast serialize | GameplayTagContainer.h | |
bool NetSerialize_Packed
(
FArchive& Ar, |
GameplayTagContainer.h | ||
void ParseParentTags
(
TArray< FGameplayTag >& UniqueParentTags |
Parses the tag name and fills in UniqueParentTags with raw parent tags, without validating with the tag manager. | GameplayTagContainer.h | |
void PostSerialize
(
const FArchive& Ar |
Handles fixup and errors. | GameplayTagContainer.h | |
FGameplayTag RequestDirectParent() |
Returns direct parent GameplayTag of this GameplayTag, calling on x.y will return x | GameplayTagContainer.h | |
bool SerializeFromMismatchedTag
(
const FPropertyTag& Tag, |
Used to upgrade a Name property to a GameplayTag struct property | GameplayTagContainer.h | |
FString ToString() |
Displays gameplay tag as a string for blueprint graph usage | GameplayTagContainer.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
bool NetSerialize_ForReplayUsingFastReplication
(
FArchive& Ar, |
GameplayTagContainer.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
| Returns true if this is a valid gameplay tag string (foo.bar.baz). If false, it will fill | GameplayTagContainer.h | ||
static FGameplayTag RequestGameplayTag
(
const FName& TagName, |
Gets the FGameplayTag that corresponds to the TagName | GameplayTagContainer.h |
Operators
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
bool operator!=
(
FGameplayTag const& Other |
GameplayTagContainer.h | ||
bool operator==
(
FGameplayTag const& Other |
Operators | GameplayTagContainer.h |