AIController.h in C++ (4.3)

Hey guys

So I am trying out the new 4.3 preview build. I see I had to change my included AIController.h from “/GameFramework/AIController.h” to just “AIController.h”. It now finds the file yet when I build I get the following error, which is very similar to a file thats not included ?? Any help anybody ??

AIPlayerController.cpp.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __cdecl AAIController::AAIController(class FPostConstructInitializeProperties const &)" (__imp_??0AAIController@@QEAA@AEBVFPostConstructInitializeProperties@@@Z) referenced in function "public: __cdecl AAIPlayerController::AAIPlayerController(class FPostConstructInitializeProperties const &)" (??0AAIPlayerController@@QEAA@AEBVFPostConstructInitializeProperties@@@Z)
1>AIPlayerController.cpp.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: virtual void __cdecl AAIController::Tick(float)" (__imp_?Tick@AAIController@@UEAAXM@Z) referenced in function "public: virtual void __cdecl AAIPlayerController::Tick(float)" (?Tick@AAIPlayerController@@UEAAXM@Z)
1>AIPlayerController.cpp.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: virtual void __cdecl AAIController::Possess(class APawn *)" (__imp_?Possess@AAIController@@UEAAXPEAVAPawn@@@Z) referenced in function "public: virtual void __cdecl AAIPlayerController::Possess(class APawn *)" (?Possess@AAIPlayerController@@UEAAXPEAVAPawn@@@Z)
1>AIPlayerController.cpp.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: virtual __cdecl AAIController::~AAIController(void)" (__imp_??1AAIController@@UEAA@XZ) referenced in function "int `public: __cdecl AAIPlayerController::AAIPlayerController(class FPostConstructInitializeProperties const &)'::`1'::dtor$0" (?dtor$0@?0???0AAIPlayerController@@QEAA@AEBVFPostConstructInitializeProperties@@@Z@4HA)
1>AIPlayerController.cpp.obj : error LNK2001: unresolved external symbol "public: virtual void __cdecl AAIController::ClearFocus(unsigned char)" (?ClearFocus@AAIController@@UEAAXE@Z)
1>AIPlayerController.cpp.obj : error LNK2001: unresolved external symbol "public: virtual void __cdecl AAIController::DisplayDebug(class UCanvas *,class FDebugDisplayInfo const &,float &,float &)" (?DisplayDebug@AAIController@@UEAAXPEAVUCanvas@@AEBVFDebugDisplayInfo@@AEAM2@Z)
1>AIPlayerController.cpp.obj : error LNK2001: unresolved external symbol "public: virtual class FString __cdecl AAIController::GetDebugIcon(void)const " (?GetDebugIcon@AAIController@@UEBA?AVFString@@XZ)
1>AIPlayerController.cpp.obj : error LNK2001: unresolved external symbol "public: virtual class FVector __cdecl AAIController::GetFoc....

Ok never mind, just figured it out. Have to include the “AIModule” now as one of the PublicDependencyModuleNames.

That’s right, whole of AI code (excluding Navigation code) has been moved to the AIModule. Sorry for not communicating that better!

–mieszko

Hey there. I see changes were also made to Behavior trees and blackboard. I can no longer use TsubClassof blablabla . Which should I use now ? Thanks. Anton

bump. Anybody ?

I’m not sure what you mean. Can you post a code snippet that doesn’t compile?

Kylawl actually told me on the forums that I had to

#include “BehaviorTree/BlackboardComponent.h”
#include “BehaviorTree/BehaviorTreeComponent.h”
#include “BehaviorTree/BehaviorTree.h”

now, so that solved it. Thanks anyway.

Just a heads up, when trying to follow your Jumping Nav tutorial (unreal-ai-tutorial.info) I ran into this issue when adding a new PathFollowingComponent.

If possible please update the tutorial!