How to get the surface type, and physical material with a projectile in C++?(No Linetraces)

If there is a better way to get the surface type please share if possible.