UInterfaces are pairs of classes that work together to enable classes to exhibit polymorphic behavior among multiple class hierarchies. This recipe shows you the basic steps involved in creating a UInterface purely in code.
Creating a UInterface
How to do it...
- From the Content Browser, go to Add New | New C++ Class. From the menu that pops up, scroll down all the way until you see the Unreal Interface selection and select it. Afterward, click on the Next button:

- From there, verify that the Name of the class is MyInterface and then click on the Create Class button:

- Add the following code to the header file:
#pragma once
#include "CoreMinimal.h"
#include "UObject/Interface.h"
#include "MyInterface...