Unresolved external Symbol when implementing DetourCrowds

Hi,

I have created an AIController class called MyAIControllerCrowds in order to implement DetourCrowds and wrote this short code in its cpp file:

#include "RTSGame.h"
#include "MyAIControllerCrowds.h"
#include "Navigation/CrowdFollowingComponent.h"

AMyAIControllerCrowds::AMyAIControllerCrowds(const FPostConstructInitializeProperties& PCIP)
: Super(PCIP.SetDefaultSubobjectClass<UCrowdFollowingComponent>(TEXT("PathFollowingComponent")))
{

}

I tried to build the project but I got these errors: Pastebin Link

1 Like

Make sure you include ‘AIModule’ as your project’s dependency.

Cheers,

–mieszko

That would be adding:

PublicDependencyModuleNames.AddRange(new string[] { “Core”, “CoreUObject”, “Engine”, “InputCore”, “AIModule” });

Inside of your “ProjectName”.Build.cs

1 Like

It worked. Thanks :slight_smile: