Fix CI into AF (DTMB ALTER SID into 07)

This commit is contained in:
2025-07-29 14:12:25 +02:00
parent 73373420d3
commit 048d5129aa
2 changed files with 8 additions and 3 deletions
@@ -1,3 +1,4 @@
import computeDestinationPoint from 'geolib/es/computeDestinationPoint';
import getGreatCircleBearing from 'geolib/es/getGreatCircleBearing';
/**
@@ -29,8 +30,12 @@ export const getCourseAndFixForIntercepts = (leg: TerminalEntry, origin: NavFix)
}
case 'AF': {
const _leg = leg as AFTerminalEntry;
const fix = { latitude: _leg.WptLat, longitude: _leg.WptLon };
return [_leg.Course.reciprocalCourse().toTrue(fix), fix];
const navAid = { latitude: _leg.NavLat, longitude: _leg.NavLon };
const fix = {
...computeDestinationPoint(navAid, _leg.NavDist.toMetre(), _leg.Course.toTrue(navAid)),
isIntersection: true,
};
return [_leg.Course.toTrue(fix), fix];
}
case 'DF': {
const _leg = leg as DFTerminalEntry;