So, I’m looking to utilise the IGenericTeamAgentInterface class.
I have my character class inherit from this interface like so…
UCLASS()
class SPACEAPEPROJECT_API ABasePaperCharacter : public APaperCharacter, public ISpriteObjectInterface, public IDamageableInterface, public IGenericTeamAgentInterface
{
As you can see - I’ve already successfully implemented two of my own custom interfaces, but try as I might I cannot seem to call the methods from Epic’s interface class.
Here is the code I’m attempting to use:
IGenericTeamAgentInterface* ObjectInterface = Cast<IGenericTeamAgentInterface>(GetPawn());
if (ObjectInterface) {
SetGenericTeamId(IGenericTeamAgentInterface::Execute_GetGenericTeamId(GetPawn()));
}
But I get the error “IGenericTeamAgentInterface has no method Execute_GetGenericTeamId”
I’ve also included the interface header in my class - which happens to inherit from AI controller
I must be missing something here, but I can’t seem to tell what it might be!