FMath::VRandCone

Syntax

static FVector VRandCone
(
    FVector const & Dir,
    float ConeHalfAngleRad
)

Remarks

Returns a random unit vector, uniformly distributed, within the specified cone ConeHalfAngleRad is the half-angle of cone, in radians. Returns a normalized vector.

References

Module

Core

Header

Runtime/Core/Public/Math/UnrealMathUtility.h

Source

Runtime/Core/Private/Math/UnrealMath.cpp