Ray Trace

Blitz3D Forums/Blitz3D Programming/Ray Trace

I've looked through the code archive, and there's almost what I need, but not exactly...

I want to do a raytrace, and find out the entity hit, and the world-space coordinates where it's hit.

LinePick command is your man.
;picked will be 0 or the entity the ray hits
picked = LinePick(x,y,z,dx,dy,dz)

Lets find out where? PickedX(),PickedY() and PickedZ() tells us! How about the normals of the surface we picked? (bullet richochets, angles and more) PickedNX(), Y and Z!

Right! Didn't know about the Picked functions. I feel silly again. Thanks dude!

Then you can get your PickedX#(), PickedY#() PickedZ#(), PickedNX#(), PickedNY#() PickedNZ#(), etc etc. :)

Didn't I say that?

He's talking about the hashes maybe?