]> git.mxchange.org Git - flightgear.git/commitdiff
A couple fixes so the nav/ils heading hold will work again.
authorcurt <curt>
Mon, 7 Jul 2003 21:19:46 +0000 (21:19 +0000)
committercurt <curt>
Mon, 7 Jul 2003 21:19:46 +0000 (21:19 +0000)
src/Autopilot/newauto.cxx
src/Cockpit/navcom.cxx

index b18b0042382533676af092961bee004743b19ed4..610d7ded10e828bf431b51d3ab263ce92cbe2c99 100644 (file)
@@ -532,7 +532,8 @@ FGAutopilot::update (double dt)
            }
 
            // determine the target radial in "true" heading
-           double tgt_radial = current_radiostack->get_navcom1()->get_nav_radial();
+           double tgt_radial
+                = current_radiostack->get_navcom1()->get_nav_target_radial();
            if ( current_radiostack->get_navcom1()->get_nav_loc() ) {
                // ILS localizers radials are already "true" in our
                // database
index c74dce0fb136170504f4732392b15c19d28b0411..541dc2213079422a60874c6966c461852b6826de 100644 (file)
@@ -738,7 +738,8 @@ double
 FGNavCom::get_nav_reciprocal_radial () const
 {
     double recip = nav_radial + 180;
-    if (recip >= 360)
-        recip = 360;
+    if ( recip >= 360 ) {
+        recip -= 360;
+    }
     return recip;
 }