When calculating the new velocity, preserve the y movement.