Collisions and Lists

Posted by user50635 on Game Development See other posts from Game Development or by user50635
Published on 2014-08-16T07:23:14Z Indexed on 2014/08/21 10:31 UTC
Read the original article Hit count: 155

Filed under:
|
|

I've run into an issue that breaks my collisions. Here's my method:

  • Gather Input
  • Project Rectangle
  • Check for intersection and ispassable
  • Update

The update method is built on object_position * seconds_passed * velocity * speed. Input changes velocity and is normalized if > 1.

This method works well with just one object comparison, however I pass a list or a for loop to the collision detector and velocity gets changed back to a non zero when the list hits an object that passes the test and the object can pass through.

Any solutions would be much appreciated. Side note is there a more proper way to simulate movement?

© Game Development or respective owner

Related posts about XNA

Related posts about c#