check bound(s)
if((bounds.right > right) || (bounds.left < left)) { vx *= bounce; ball.x += 5 * vx; } if((bounds.bottom > bottom) || (bounds.top < top)) { vy *= bounce; ball.y += 5 * vy; } avx[i] = vx; avy[i] = vy; } }