]> git.mxchange.org Git - flightgear.git/blobdiff - src/FDM/UIUCModel/uiuc_engine.cpp
Updated to match changes in radiostack.[ch]xx
[flightgear.git] / src / FDM / UIUCModel / uiuc_engine.cpp
index 7511338d387269dacf078e6137d04159a7523681..b8a8e855d4c51bd2bfc669abac8fb63382cc7f6c 100644 (file)
 ----------------------------------------------------------------------
 
  HISTORY:      01/30/2000   initial release
+               06/18/2001   (RD) Added Throttle_pct_input.
 
 ----------------------------------------------------------------------
 
  AUTHOR(S):    Bipin Sehgal       <bsehgal@uiuc.edu>
                Jeff Scott         <jscott@mail.com>
+              Robert Deters      <rdeters@uiuc.edu>
                Michael Selig      <m-selig@uiuc.edu>
 
 ----------------------------------------------------------------------
 
 #include "uiuc_engine.h"
 
+#if !defined (SG_HAVE_NATIVE_SGI_COMPILERS)
 SG_USING_STD(cerr);
+#endif
 
 void uiuc_engine() 
 {
   stack command_list;
   string linetoken1;
   string linetoken2;
+
+  if (Throttle_pct_input)
+    {
+      double Throttle_pct_input_endTime = Throttle_pct_input_timeArray[Throttle_pct_input_ntime];
+      if (Simtime >= Throttle_pct_input_startTime && 
+          Simtime <= (Throttle_pct_input_startTime + Throttle_pct_input_endTime))
+        {
+          double time = Simtime - Throttle_pct_input_startTime;
+          Throttle_pct = uiuc_1Dinterpolation(Throttle_pct_input_timeArray,
+                         Throttle_pct_input_dTArray,
+                         Throttle_pct_input_ntime,
+                         time);
+        }
+    }
   
   Throttle[3] = Throttle_pct;