Cannot Cast to Actor Component from HUD Class in C++

I think I figured out how to pass both variables into one value.

FVector2D ACppRadarHUD::GetDotPosition(AActor* Actor)
{
	
	float FvectorX;
	float FvectorY;
	FVector2D Result = FvectorX + FvectorY;
    FvectorX = UKismetMathLibrary::InverseTransformLocation(UGameplayStatics::GetPlayerPawn(GetWorld(), 0)->GetActorTransform(), Actor->GetActorLocation()).X / ObjectDistanceScale;
    FvectorY = UKismetMathLibrary::InverseTransformLocation(UGameplayStatics::GetPlayerPawn(GetWorld(), 0)->GetActorTransform(), Actor->GetActorLocation()).Y / ObjectDistanceScale;
	return Result;
}