Original Post
I have done a very basic collision detection code in NeHe''s Lesson 23 which works like this:
First i find the normal to the walls.
Plane equation = Ax + By + Cz + d;
Then i find the distance between the camera and the walls by
dist=normal.DotProduct - d;
but when i try to do the collision detection i face a problem.
I have done the coll det such that when the dist is zero the object has touched a wall and must stop. But my camera stops half the way. Its like there are hidden walls between the distance. Plz help me out. And if you can tell me of a site which provides basic collision detection code.
Saqib