i was trying your code, for what i got from your code the function that check the collision between two polygons is the testPolygonVsPolygon, but everytime it returned null, so i checked and in the CheckPolygons method during the for( i ) cycle you do other 2 cycle for( j ), the check for that cycle was i<verts.count and then it was i++ opposed to j++ , so that basically the value checked by the j value was always the same, and the second for(j) wasn't even considered because the i value was alredy too high, so it started working better, but the result of that operation was allways null even for a rectangle inside another one, so i checked more and i found at the end method that it was returning null value because the last operation before the return result was setting the result to null. did i not understand your code or it was a refactoring problem?
i was trying your code, for what i got from your code the function that check the collision between two polygons is the testPolygonVsPolygon, but everytime it returned null, so i checked and in the CheckPolygons method during the for( i ) cycle you do other 2 cycle for( j ), the check for that cycle was i<verts.count and then it was i++ opposed to j++ , so that basically the value checked by the j value was always the same, and the second for(j) wasn't even considered because the i value was alredy too high, so it started working better, but the result of that operation was allways null even for a rectangle inside another one, so i checked more and i found at the end method that it was returning null value because the last operation before the return result was setting the result to null. did i not understand your code or it was a refactoring problem?