]> git.mxchange.org Git - flightgear.git/commitdiff
Initial units confusion fixes.
authorcurt <curt>
Mon, 2 Apr 2001 03:39:43 +0000 (03:39 +0000)
committercurt <curt>
Mon, 2 Apr 2001 03:39:43 +0000 (03:39 +0000)
src/Main/fg_init.cxx

index 6b0a02b944fc960c7c9612f85c7246703296d236..599469dab5d06cffc8b77fd684e774b6d4e73cee 100644 (file)
@@ -425,10 +425,10 @@ bool fgInitPosition( void ) {
     }
 
     // if requested altitude is below ground level
-    if ( scenery.cur_elev >
-        fgGetDouble("/position/altitude") * METERS_TO_FEET - 1) {
-       fgSetDouble("/position/altitude",
-                   (scenery.cur_elev + 1) * METERS_TO_FEET );
+    if ( fgGetDouble( "/position/altitude" ) < (scenery.cur_elev + 1)
+        * METERS_TO_FEET ) {
+       fgSetDouble( "/position/altitude",
+                    (scenery.cur_elev + 1) * METERS_TO_FEET );
     }
 
     SG_LOG( SG_GENERAL, SG_INFO,