What is the equivalent of Math.PI in the Unreal Engine API

There are many mathematical constants that are generally used while programming, currently I find myself creating constants manually.

Is there a float/double constant for Math.PI, Math.TwoPi and such in the API? Can anyone provide an example?

I’ve seen examples in blueprint but the documentation on the website only shows PI as a VectorRegister

Thank you for your time

PI is defined in UnrealMathUtility.h
#define PI (3.1415926535897932f)

5 Likes

Thank you!

#include “Math/UnrealMathUtility.h”

float mathPi = PI;

3 Likes