bounce(s)
if(ball.x + ball.radius > right)
{
ball.x = right - ball.radius;
vx *= -1;
}
else if(ball.x - ball.radius < left)
{
ball.x = left + ball.radius;
vx *= -1;
}
if(ball.y + ball.radius > bottom)
{
ball.y = bottom - ball.radius;
vy *= -1;
}
else if(ball.y - ball.radius < top)
{
ball.y = top + ball.radius;
vy *= -1;
}
}
}
}