I did this a bit different using a flag if it passed the end and then flipped if I was adding or subtracting the vector to the Location.
if (HasAuthority()) {
FVector Location = GetActorLocation();
FVector Direction = (GlobalTargetLocation - Location).GetSafeNormal();
float Length = (GlobalTargetLocation - GlobalStartLocation).GetSafeNormal().Size();
float DistanceFromStart = (Location - GlobalStartLocation).Size();
float DistanceFromEnd = (Location - GlobalTargetLocation).Size();
if (Length > DistanceFromStart) {
MoveTo = false;
}
else if (Length > DistanceFromEnd) {
MoveTo = true;
}
Location = (MoveTo) ? Location - (MovementSpeed * DeltaTime * Direction) : Location + (MovementSpeed * DeltaTime * Direction);
SetActorLocation(Location);
}
Wish I my brain would have thought to simply swap the variable out lmao nevermind