Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How to detect what face a ray hit?

Asked by 10 years ago

So I have a script that casts a ray, and want to know how I would be able to tell what face of an object the ray hit? Like if the ray hit the front of a brick, how would I edit the script so that the script will know that the ray hit the front?

1 answer

Log in to vote
0
Answered by 10 years ago

It depends on what shape that ray hit. It's pretty advanced, thought here is someone else's script: http://pastebin.com/sXZ9FTNz

Try to understand how it works, and you will be able to make it.

Ad

Answer this question