This project has moved and is read-only. For the latest updates, please go here.

unexpected circle bounce

Mar 9, 2009 at 5:05 AM
When I create a scene with four walls, no gravity, and a ball with an initial impulse, I expect it to bounce around in a very predictable way.  For the most part, it does.  However, every once in a while it takes an odd bounce, like the ball didn't see the correct normal on the wall.  Is this a known issue or can I tweak a setting to prevent it?  I'm new to Farseer, but I saw a thread that listed "real circles" as a feature for v2.2.  Is this problem I'm seeing related to the circle geometry?
Mar 9, 2009 at 10:02 AM
Edited Mar 9, 2009 at 10:03 AM
Sort of. See, circles are just a geometry approximation (which means that they are really just many-sided blocks) in farseer, at least currently. So, when your ball hits the wall wrong (it might be catching a flat surface or a corner on the geometry), it gets an impulse applied to it wrong. It will get fixed in 2.2, but theres nothing that can be done until then (except maybe increasing the number of vertices in a circle, but that makes farseer run slower if there are a lot). by the way, Welcome!
Mar 9, 2009 at 10:20 PM
this may be related to my thread:
Mar 10, 2009 at 1:29 AM
Yeah, it doesn't really. In a (few) word(s), the circle geometry is inaccurate and nothing can be done till 2.2 (except increasing the vertices as i said before).
Mar 10, 2009 at 9:53 PM
Thanks for the info guys.  I was looking into using farseer for pong or breakout types of games.  People expect the bounce to be very predictable there, and I've found that circle-rectangle collisions are pretty simple.  So I'm going to use my own (very) simple physics for now, but I do really like the ease of use with this engine and I'm sure I'll come back to it for other projects.
Mar 11, 2009 at 8:46 AM
Yup... I'm working on a physics engine of my own which, if i can get a feature (or two) implemented, will let me completely abandon farseer for use in my projects... Dont worry though, i'll still be around!