In my project, I have my player which is of type Pawn, and an enemy, also of type Pawn. Both actors have a visible static mesh and are constantly moving, and I am trying to use the GetDistanceTo function so I can gauge if the player is close enough to the enemy for the enemy to take an action. However, after the initial call, GetDistanceTo never changes. The value is ALWAYS the same.
Just as a test, I placed a short call to it in the tick event of my enemy, with a PrintString call. I couldn’t think of anything more basic to try, but it never updates there either.
I had the same problem. The problem was that I was calculating the difference between the controller (because GetDistanceTo defaulted to self) and the OtherActor. But I should use the ControlledPawn instead of the controller obviously to measure the distance.