zhaowenyu
2026-02-11 81ee4f2a3fd0e0b57880b378025f4bbfd84745fc
ard-work/src/main/java/com/ard/work/component/websocket/handler/NoFlyDistanceManager.java
@@ -54,13 +54,10 @@
            List<Vertex> polygon = zone.getVertices();
            if (polygon == null || polygon.size() < 3) continue;
            double distanceDeg = NoFlyZoneUtils.pointToPolygonDistance(current, polygon);
            double distance = NoFlyZoneUtils.pointToPolygonDistance(current, polygon);
            // ⭐ 转成米
            double distanceMeter = NoFlyZoneUtils.degDistanceToMeter(distanceDeg, current.y);
            if (distanceMeter < minDistance) {
                minDistance = distanceMeter;
            if (distance < minDistance) {
                minDistance = distance;
                nearestZone = zone;
            }
        }