Raycast in reverse
Posted: Wed Jun 16, 2010 3:30 pm
I have a statictrianglegroup, I'm using it as a terrain and I'm doing raycast to get terrain height. So, I'm doing it from downwards
triangleStaticGroup.RayCast (new Vector3 (1000, -1, 1000), Vector.UnitY, 10000.0f ..)
instead of the usual top down.
triangleStaticGroup.RayCast (new Vector3 (1000, 10000, 1000), -Vector.UnitY, 10000.0f ..)
I find that it works on the edges (0,-1,0), but within the map, it returns 0. Would this be a bug?
triangleStaticGroup.RayCast (new Vector3 (1000, -1, 1000), Vector.UnitY, 10000.0f ..)
instead of the usual top down.
triangleStaticGroup.RayCast (new Vector3 (1000, 10000, 1000), -Vector.UnitY, 10000.0f ..)
I find that it works on the edges (0,-1,0), but within the map, it returns 0. Would this be a bug?