Question by
Radeg90 · Aug 08, 2019 at 10:24 PM ·
c#raycastraycasthitnormals
A cube, raycasthit and rotation
My question is really simple, I have a really basic script where LMB performs a raycast hit from camera to the camera's front and there are cubes with different rotation on the scene. If I hit anything I would like to get a Quaternion of the wall of cube I clicked.
I'm showing a pic what I mean. After throwing a brown raycast from the camera I want to update my green object position (which works) and rotate it as the wall front is.
Can a "normal" variable help there anyhow?
Comment