Unrecognized type 'AAIController' - type must be a UCLASS, USTRUCT or UENUM

Hi,

I’m doing a project using both c++ and blueprints.

I made a type through c++ and I wanted to operate it through blueprints.

However, when I try to export some functions, it gives the error in the title.

I have seen various solutions but they do not fit into my problem.

The idea is for that function, execute, to be callable from the blueprint.

The definition is in a parent class “Order” and the implementation is in a child class.
The error is in the definition.

125882-functionimplementation.png

125883-functiondefinition.png

That means UHT tool that generates code for UFUNCTION does not recognize AAIController, check if you added “AIModule” dependency in build script (*.cs files). If you have it already try adding class AAIController; before UCLASS() of you class.