Vector3.bounce vs Vector3.reflect

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By fuck

The online documentation of Vector3 says

Vector3 bounce (Vector3 n):
Returns the vector “bounced off” from a plane defined by the given normal.

Vector3 reflect ( Vector3 n ):
Returns this vector reflected from a plane defined by the given normal.

What is the difference between these two methods?

I’m guessing the difference is in the magnitude of the returned vectors. With reflect(), it returns the mirror of the input vector, but the magnitude (i.e. the length) is the same. With the bounce() function, it takes into account the momentum of the object, and so the returned vector has a smaller length.

Ertain | 2020-08-07 06:36

:bust_in_silhouette: Reply From: Drogrant

I think an image is better in this case. The concept is the same in 3D but more difficult to draw.