Hi!
I’m having three problems moving a pawn (unit) using an AIController. In a custom PlayerController I call GetHitResultUnderCursor(ECC_Pawn, false, Hit);
to raycast and extract the position the player clicked on. Then I use AAIController::MoveToLocation(location, 0.1f, false, true, false, false);
in the AIController to move the unit. The problems are that:
-
The player pawn is stopping a small distance before it reaches it’s final destination, even though I have set the acceptance radius to a small value and placed the mesh in the origo of the blueprint.
-
If I press close and intense in front of the pawn when still moving, the pawn often starts to move towards the origo of the world/map. I check that the raycast actually did hit something.
-
The RVO avoidance seems to function a bit strange and makes the pawns move very slowly in a wobbly strange path when near other pawns. You can also see some strafing even though strafing is supposed to be turned off and set to false in the move method call.
I have a video that shows problem 1 and 2 here video link.
I have a video that shows problem 3 here video link.
Issue 1 and 2 also exists in the Top Down template, both BP and CPP version. See demonstration here video link.
===================================================================================
Issue 1 is solved by setting the third parameter to false, kinda obvious when you actually read the parameter name.
AAIController::MoveToLocation(location, 0.1f, false, true, false, false);
Issue 2 and 3 (especially 2) looks like bugs in my opinion.