Multicollision resolution for colliding rigid bodies