public PathCoordinate GetClosest(PathCoordinate pathCoord1, PathCoordinate pathCoord2) { return((Coordinate.DistanceToSquared(pathCoord1.Coordinate) <= Coordinate.DistanceToSquared(pathCoord2.Coordinate)) ? pathCoord1 : pathCoord2); }