My modified version takes any amount of points from an array, each with a matching handle position