diff --git a/js/kiri-print.js b/js/kiri-print.js index 7be852b0..4f4f6273 100644 --- a/js/kiri-print.js +++ b/js/kiri-print.js @@ -872,8 +872,9 @@ var gs_kiri_print = exports; } return; } + let area = poly.area(); poly.forEachPoint(function(point, index) { - dist = startPoint.distTo3D(point); + dist = startPoint.distTo3D(point) * area * area; if (dist < mindist) { found = {poly:poly, index:index, point:point}; mindist = dist; diff --git a/js/license.js b/js/license.js index 86518d2a..e0dbed36 100644 --- a/js/license.js +++ b/js/license.js @@ -1,7 +1,7 @@ var exports = { COPYRIGHT:"Copyright (C) 2014-2019 Stewart Allen - All Rights Reserved", LICENSE:"See the license.md file included with the source distribution", - VERSION:"1.5.4" + VERSION:"1.5.5" }; if (!module) var module = {}; module.exports = exports;