Advertisement

HL BSP Col-Det

Started by April 23, 2003 02:53 PM
2 comments, last by gwihlidal 21 years, 9 months ago
Hello, I''ve been playing around with that Half-Life BSP viewer Bart Sekura released a while back for OpenGL and it has really helped me understand the BSP format for it, one thing though is his collision detection is extremely buggy and inaccurate. He has a recursive algorithm that checks all visible faces and modifys a final 3D vector as the new position when you collide with walls and such. Many cases (very easy to duplicate) you can fall right through the floor (I added simple gravity). I can run around the map but I''ll eventually fall down. I tried modifying it to check EVERY face on the map which was obviously a lot slower, but was for testing purposes and same thing, so something obviously in the collisioning. Anyone out there looked at his example and got this working? I''m desperately trying to figure out what''s happening, I''ve tried a lot of different things and nothing has made it rarely produceable Thanks a lot ~Graham
Btw, here is my collisioning code

http://studentweb.nait.ab.ca/cst1766/Exodus/ColDet.cpp

~Graham
Advertisement
you are using sphere for collision

i hate spheres AABB will do the job
http://www.8ung.at/basiror/theironcross.html
It should work with sphere though shouldn't it? Or is sphere too "inaccurate" around complex objects unless you code a bunch of testing "hacks" in place?

I thought sphere was the best test object because the math around it is fast

Will Axis Aligned bounding boxes possibly solve this problem that's happening?

Thx,

~Graham

[edited by - gwihlidal on April 26, 2003 12:54:20 PM]

This topic is closed to new replies.

Advertisement