I have a class called BOX that has a List of ints as the corner point. So each int array holds 2 points an x and y, 1 array for each corner of a box. Next I have a list that stores each box, at this point I want to compare all the points of each box from each list of class BOX. If a match is made I want to make sure that the matching box is not checked again.
class BOX {
bool matched = false;
int[] points1 = { 1, 2 };
int[] points2 = { 1, 3 };
int[] points3 = { 2, 3 };
int[] points4 = { 2, 2 };
public List<int[]> boxPoints = new List<int[]>() { points1, points2, points3, points4 };
}
void Main() {
List<BOX> newBoxes = new List<BOX>();
List<BOX> oldBoxes = new List<BOX>();
int matchedPoints;
foreach (BOX boxes in oldBoxes)
{
//Something here, but I'm not sure what...
}
}