Getting the orientation of Hit triangle?

i would like to know an economic way to get the orientation of the Hit mesh triangle , which can be acquired by casting physics.Raycast ?

i want to use this information to make the playing character match the rotation of the hit mesh triangle.

thanks

Use a Raycast method that takes a RaycastHit parameter. The hit info includes the normal, which gives you the orientation of the surface at the hit point. You can also get the triangle index if you really want to dig deep.

The normal IS the orientation, so if you want to set the player to face this direction use:

player.transform.forward = hitInfo.normal;