Quote:
Then I'm pretty glad I can do you favor. :-) You can use pXent_raycast for that purpose.
I appreciate it, but USE_BOX is the main thing missing, and as far as I can tell that function is just a ray.
Quote:
Last time I checked c_trace with use_box it worked just fine. If it really does return messed up normals, you should probably post it in the bug hunt?
The problem is the normal returned is not the normal of the surface; it's the normal of the projected ellipsoid colliding with that surface. This is normally fine, except when we encounter an edge. Consider stairs: the normal returned by a c_trace without USE_BOX would be (1, 0, 0) or (0, 0, 1). Now try again with USE_BOX, where the box is bigger than a single stair, and you'll get a sloped normal (like (0.7, 0, 0.7)).

USE_BOX is great for a collision detection (that normal is ideal for ellipsoid collision detection), but really annoying when you actually care about the normal.

Jibb


Formerly known as JulzMighty.
I made KarBOOM!