Ball gains height with "Bounciness" set to 1. Why?

I set Bounciness to 1 and pressed play. After a while, I noticed that the ball had gained some height.
I thought that by setting it to 1, it would reach exactly the same height after a collision.
This will cause the ball to accelerate, which could be cool but not what I expected.

By the way, I’m running Unity 2018.2.8f1 if that matters.

/Gubbaset

Hi,

Your collisions are not being detected accurately, so each time the ball bounces it has travelled slightly further down on the Y axis, as such, it has gained more energy, when it bounces, it goes a little further up. The next time it comes down, it now has further to fall, gains more energy, doesn’t have it’s collision detected accurate, gains a little more distance, bounces… Repeat.

Set your Collision Detection mode to Continuous on the Rigidbody2D component and you’ll detect the collisions more accurately, this should resolve this issue.

Hope this helps :slight_smile:

3 Likes

Yes it did.
Thanks! :+1:

1 Like

You’re very welcome :slight_smile:

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms