Tagged Questions
0
votes
3answers
83 views
Keeping raycast on the same level
I want my raycast to end at certain height(red line). But as the game is 3D and the camera rotates I can't use a fixed magnitude. What I thought was a stroke of genius, I figured I'd project the ...
5
votes
1answer
489 views
Why doesn't Unity's OnCollisionEnter give me surface normals, and what's the most reliable way to get them?
Unity's on collision event gives you a Collision object that gives you some information about the collision that happened (including a list of ContactPoints with hit normals).
But what you don't get ...
1
vote
1answer
805 views
Optimized algorithm for line-sphere intersection in GLSL
Well, hello then!
I need to find intersection between line and sphere in GLSL. Right now my solution is based on Paul Bourke's page and was ported to GLSL this way:
// The line passes through p1 and ...