Download

PathFollowingComponent bug?

My character has a reach point. I am using MoveToLocation (of AIController).
This character needs to avoid other characters, so I have created AIController and set the constructor to:


AVikingController::AVikingController(const FObjectInitializer& ObjectInitializer) : 
	Super(ObjectInitializer.SetDefaultSubobjectClass<UCrowdFollowingComponent>(TEXT("PathFollowingComponent")))
{
}

To connect the character and the new controller - on the constructor of the character:



AIControllerClass = AVikingController::StaticClass();
AutoPossessPlayer = EAutoReceiveInput::Disabled;
AutoPossessAI = EAutoPossessAI::PlacedInWorldOrSpawned;


And when I need to move the character:



AAIController* AIController = Cast<AAIController>(GetController());

if (AIController)
	AIController->MoveToLocation(pos, acceptanceRadius);


When I put 1 character in his way, he avoids it. But when I put 2 characters, well he avoids it but in a really weird way. I can not explain it so I have uploaded a video to describe it:

He wrap to the other characters and slows down instead of walking from the side and NOT slowing down.

Moreover look at this:

As you can see when the a static object blocks its way, the character always looks at the target point and not at the path direction.
This is not happans when I remove from the controller the UCrowdFollowingComponent.

Why is that happening? Is it a bug?

UP…

I recommend posting this on answerhub as Epic’s AI programmers don’t really read the forums.

Already did. No one answers:
https://answers.unrealengine.com/questions/225316/pathfollowingcomponent-bug.html

UP…