]> git.mxchange.org Git - flightgear.git/blobdiff - src/Autopilot/xmlauto.hxx
Fix altitude units error loading plans, spotted by Csaba Halasz (Jester).
[flightgear.git] / src / Autopilot / xmlauto.hxx
index 41946fb25244d79fe8111ac1090a73e99ab51aa8..bbe122631d4f1532fe48e624288064fe1db47ba3 100644 (file)
@@ -52,6 +52,7 @@ using std::deque;
 class FGXMLAutoInput : public SGReferenced {
 private:
      double             value;    // The value as a constant or initializer for the property
+     bool               abs;      // return absolute value
      SGPropertyNode_ptr property; // The name of the property containing the value
      SGSharedPtr<FGXMLAutoInput> offset;   // A fixed offset, defaults to zero
      SGSharedPtr<FGXMLAutoInput> scale;    // A constant scaling factor defaults to one
@@ -61,8 +62,9 @@ private:
 
 public:
     FGXMLAutoInput( SGPropertyNode_ptr node = NULL, double value = 0.0, double offset = 0.0, double scale = 1.0 ) :
-      property(NULL),
       value(0.0),
+      abs(false),
+      property(NULL),
       offset(NULL),
       scale(NULL),
       min(NULL),
@@ -295,6 +297,7 @@ class FGPredictor : public FGXMLAutoComponent {
 
 private:
     double last_value;
+    double average;
     FGXMLAutoInputList seconds;
     FGXMLAutoInputList filter_gain;