How do I declare gameplay tag? Or how do I EQS test for variable value of object?

Hi there,

Not sure you’re still looking for this, but in case someone else stumbles unto this page like me, I think I have figured at least a way to do it, if not THE way to do it.

To declare gameplay tags, add the following:

[GameplayTags]

ImportTagsFromConfig=true

To DefaultEngine.ini

Then, in editor, you will have a new category GamePlayTags in Edit/Project Settings/Project and there you can declare your gameplay tags.

To use it in EQS then, it is necessary that the objects you’re looking for implement the interface IGameplayTagAssetInterface.

To my knowledge, it is only possible to do it in C++ at this time.

Don’t forget to add GameplayTags to the PublicDependencyModuleNames in your project build.cs file for your project to compile.

For example, I wanted to use this for my characters, so I needed to create a MyCharacter class implementing this interface and have my character BP classes deriving from it. In the class implementation, there are 4 functions to override and that’s it. It’s not difficult to do, just a little difficult to find what to do since there is not much information about it.

Feel free to ask if this is not clear and you need more explanation about how to do it. If anyone has more information or if I’ve missed something, feel free to correct me too :slight_smile:

Hope this helps.