Sign in to follow this  

Collisions with many objects

This topic is 3588 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, (sorry for mistakes, I'm Polish :P) I'm trying to make a physics engine for my game, but I can't manage collision detection. I'm doing some simple AABB between a character and a box. It works fine until I try to load an object (.x file) containing two boxes (ex. buildings). I'm using D3DXComputeBoundingBox function, so it calculates the AABB's vertexes, but it treats a space between each box as a part of an object (so I can't move the camera there). My question is: do I really have to load each object from separate .x file? I read few articles about CD and I came across a method using "ray". Do you know anything about it? Or do you know any tutorials describing this method?

Share this post


Link to post
Share on other sites
Your problem is that you're using bounding boxes for such models. Bounding boxes are fine, but for such objects, they're clearly not the right choice. You may want to go for per-polygon collision checks - though keeping an early bounding box test is a good idea: if the camera doesn't collide with that, then it surely won't collide with any of the polygons, which saves some time.

Share this post


Link to post
Share on other sites

This topic is 3588 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this