Hey first of all tx alot for providing this nice engine :) But i'm struggling a bit…
Shortly what i'm up to: I've coded a content importer for quake 3 map's (the compiled version .bsp) and also ported the collition detection from the quake 3 source, all good so far. But it's not enough to just collide with the map mesh :p so i needed a physics engine. I used physics engines before (newton) but like to see whats under the hood so was happy to find JigLibX :)
After looking into the jig framework i gave it a quick go. I created a new primitive BSP to hold the bsp tree from quake and figured i needed to make a DetectFunctor so started with CollDetectSphereBSP and here my troubles started. Everything works fine and i get called when a test ball hits the bsp. I compared with CollDetectSpherePlane/CollDetectSphereStaticMesh to try to figure out what to return here. In the collition code i ported from the quake source i have 3 functions where i can trace a ray, sphere or box form a start point to a endpoint in the bsp-tree. so i just tried to trace the sphere in CollDetectSphereBSP from the old sphere pos to the new sphere pos and called CollisionNotify fith the result (the bsp is static). I actually worked :) but only half :( when the ball was comming to a hold it passed through the bsp-mesh. The problem is the trace from the quake collition return as soon it find a hit on the way from the start point.
If i understand it right i need to report back the collitions situation at the endpoint (in this case all the colliding planes from the bsp-tree) and the framework will take care of the rest?? Also i'm not sure i understand InitialPenetration in SmallCollPointInfo maybe someone can explain a little ;)
Hope someone can help or give me a hint how to do this right :)
…and it makes any sense!!!