saving the bouncing ball