Angle between vectors not working c++

Most people say this should do it:

angle = RadiansToDegrees (acosf(dotproduct (vector a normalized, vector b normalized)))

So i tried it:

FVector tankDirection = tankLocation + tank->GetActorForwardVector() * 600
FVector bulletImpactReverseDirection = outHit.ImpactPoint + activeBullets[i]->GetActorForwardVector().RotateAngleAxis(180, FVector(0, 0, 1)) * 1000

FMath::RadiansToDegrees(acosf(FVector::DotProduct(tankDirection .GetSafeNormal(), bulletImpactReverseDirection .GetSafeNormal())));

But it just returns a random number, looks like it.

295777-untitled.png

Both vectors are pointing away from the tank. I want the angle between a green one and the blue one, but in this situation, it printed something like 4 , or 9.

What am i doing wrong?

Is it because they are not starting in the same point or something?

A normalized vector is a vector with a length of one. You already have access to those vectors, no need to normalize.

The bullet impact point is what seems funny to me. It draws a vector from the world origin to the impact point, and then to the reverse direction of the bullet.

A reverse of a vector can be found by multiplying the vector by -1.

Try:

FMath::RadiansToDegrees(acosf(Tank->GetForwardVector(), ActiveBullets[i]->GetActorForwardVector()*-1);