added the function to move points into the array