]> git.mxchange.org Git - flightgear.git/blobdiff - src/AIModel/AIGroundVehicle.hxx
NavDisplay: fix update lag when switching range or centre.
[flightgear.git] / src / AIModel / AIGroundVehicle.hxx
index f1f4085a9ef19e7df956285beb3ecc150e89bfc0..08491bad6825a4901fbe1939d956b33791e5746f 100644 (file)
@@ -37,17 +37,17 @@ public:
     virtual ~FGAIGroundVehicle();
 
     virtual void readFromScenario(SGPropertyNode* scFileNode);
+
+    bool init(bool search_in_AI_path=false);
     virtual void bind();
     virtual void unbind();
-    virtual const char* getTypeString(void) const { return "groundvehicle"; }
+    virtual void reinit();
+    virtual void update (double dt);
 
-    bool init(bool search_in_AI_path=false);
+    virtual const char* getTypeString(void) const { return "groundvehicle"; }
 
 private:
 
-    virtual void reinit() { init(); }
-    virtual void update (double dt);
-
     void setNoRoll(bool nr);
     void setContactX1offset(double x1);
     void setContactX2offset(double x2);
@@ -62,7 +62,6 @@ private:
     void setElevation(double _elevation, double dt, double _elevation_coeff);
     void setPitch(double _pitch, double dt, double _pitch_coeff);
     void setTowAngle(double _relbrg, double dt, double _towangle_coeff);
-    void setParentName(const string& p);
     void setTrainSpeed(double s, double dt, double coeff);
     void setParent();
     void AdvanceFP();
@@ -76,7 +75,6 @@ private:
 
     void calcRangeBearing(double lat, double lon, double lat2, double lon2,
         double &range, double &bearing) const;
-    double calcRelBearingDeg(double bearing, double heading);
 
     SGGeod _selectedpos;
 
@@ -93,12 +91,10 @@ private:
     double _range_ft;
     double _relbrg;
     double _parent_speed, _parent_x_offset, _parent_y_offset, _parent_z_offset;
+    double _hitch_x_offset_m, _hitch_y_offset_m, _hitch_z_offset_m;
     double _dt_count, _next_run, _break_count;
 
     const SGMaterial* _material;
-    const SGPropertyNode *_selected_ac;
-
-    string _parent;
 
 };