With a Task, you can get an AI Controller that is assigned to an AI Pawn or Character and using get controlled Pawn. However, as a Character is a class that inherits from Pawn, Pawn itself doesn’t have a CharacterMovementComponent that a Character does have. How then, would one obtain an AI driven Pawn’s maxWalkSpeed from the MovementComponent, which determines how fast they are walking. This is for changing the speed into a run like pattern(which we’ll change using a running animation in the character blueprint too) and vice versa.
For the record, this is for a project where the AI pawn will “run” to a random target point away from the player should they get close, and after they are far away enough and reached the point, they return to walking speed.