From a138761dd25987bc6495f1e93a4aecde66034442 Mon Sep 17 00:00:00 2001 From: Joshua Davidson Date: Sat, 16 Dec 2017 20:47:53 -0500 Subject: [PATCH] A3XX: Fix FMGC NAV mode bugs --- AircraftConfig/error-mismatch.xml | 2 +- Nasal/FMGC-b.nas | 5 ++++- Systems/fmgc.xml | 2 +- revision.txt | 2 +- 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/AircraftConfig/error-mismatch.xml b/AircraftConfig/error-mismatch.xml index f3e33019..b2bd8c4a 100644 --- a/AircraftConfig/error-mismatch.xml +++ b/AircraftConfig/error-mismatch.xml @@ -112,7 +112,7 @@ left - + diff --git a/Nasal/FMGC-b.nas b/Nasal/FMGC-b.nas index 3dc4f31d..57e34d2f 100644 --- a/Nasal/FMGC-b.nas +++ b/Nasal/FMGC-b.nas @@ -579,9 +579,12 @@ var ap_various = func { R = radius/math.sin(delta_angle_rad); dist_coeff = delta_angle * -0.011111 + 2; if (dist_coeff < 1) { - ist_coeff = 1; + dist_coeff = 1; } turn_dist = math.cos(delta_angle_rad) * R * dist_coeff / 1852; + if (getprop("/gear/gear[0]/wow") == 1 and turn_dist < 1) { + turn_dist = 1; + } setprop("/it-autoflight/internal/lnav-advance-nm", turn_dist); if (getprop("/sim/time/elapsed-sec")-getprop("/autopilot/internal/wp-change-time") > 60) { setprop("/autopilot/internal/wp-change-check-period", time); diff --git a/Systems/fmgc.xml b/Systems/fmgc.xml index 3f76fe73..e9dcdd92 100644 --- a/Systems/fmgc.xml +++ b/Systems/fmgc.xml @@ -6,7 +6,7 @@ ############################################## --> - + /FMGC/internal/greendot-kts diff --git a/revision.txt b/revision.txt index 169d1445..5af20608 100644 --- a/revision.txt +++ b/revision.txt @@ -1 +1 @@ -4071 \ No newline at end of file +4072 \ No newline at end of file