Understanding GetSafeNormal

hello :slight_smile:
can you please help me to understand what the GetSafeNormal function do?
i searched on the unreal web site, the only explanation on there is: Gets a normalized copy of the vector, checking it is safe to do so based on the length. Returns zero vector if vector length is too small to safely normalize. well, what if i dont come from the vector magic world? :wink:
thank you very much, this is a great course.


Normalizing a vector involves dividing each of its components by its magnitude. GetSafeNormal makes sure you don’t run into problems dividing by 0 even if the vector you’re trying to normalize has 0 magnitude.

thank you :slight_smile:
if i get it correct, when the platform move forward the magnitude is increased in the positive x, when it come back to the start positin the magnitude wont be zero. so why do we need this function?

thank you so much for the help :slight_smile:

To determine the direction its moving.

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.

Privacy & Terms