]> git.mxchange.org Git - flightgear.git/commitdiff
Fix jsbsim gear location in the property tree.
authorThomas Geymayer <tomgey@gmail.com>
Sun, 26 May 2013 18:56:17 +0000 (20:56 +0200)
committerThomas Geymayer <tomgey@gmail.com>
Sun, 26 May 2013 18:57:28 +0000 (20:57 +0200)
Need to convert from feet to inch.

src/FDM/JSBSim/JSBSim.cxx

index 2049453542676d1e8262888ddae5a3d6be8ee42c..b71d8700c18f86dd7fc0844b2ab4bb0482b7396a 100644 (file)
@@ -1215,9 +1215,9 @@ void FGJSBsim::init_gear(void )
     for (int i=0;i<Ngear;i++) {
       FGLGear *gear = gr->GetGearUnit(i);
       SGPropertyNode * node = fgGetNode("gear/gear", i, true);
-      node->setDoubleValue("xoffset-in", gear->GetBodyLocation()(1));
-      node->setDoubleValue("yoffset-in", gear->GetBodyLocation()(2));
-      node->setDoubleValue("zoffset-in", gear->GetBodyLocation()(3));
+      node->setDoubleValue("xoffset-in", gear->GetBodyLocation()(1) * 12);
+      node->setDoubleValue("yoffset-in", gear->GetBodyLocation()(2) * 12);
+      node->setDoubleValue("zoffset-in", gear->GetBodyLocation()(3) * 12);
       node->setBoolValue("wow", gear->GetWOW());
       node->setDoubleValue("rollspeed-ms", gear->GetWheelRollVel()*0.3043);
       node->setBoolValue("has-brake", gear->GetBrakeGroup() > 0);