Add velocity relative to ground?

Let’s say our player is on a flat surface. If we want to move the player, we add to the x and z components of the velocity. Now, what if the player is on a sloped surface? How would I transform the acceleration vector to be parallel with the plane that is the surface below? Thanks.

Good day.

You should use Vector3.Project in order to progect a vector over another.

But can i ask why you need this? Is for player movement? Why dont use NavMeshSystem?

Bye!