]> git.mxchange.org Git - flightgear.git/commitdiff
Set the motion transform id in the collection step.
authorfrohlich <frohlich>
Thu, 5 Mar 2009 06:07:08 +0000 (06:07 +0000)
committerTim Moore <timoore@redhat.com>
Thu, 5 Mar 2009 09:52:03 +0000 (10:52 +0100)
Modified Files:
src/FDM/groundcache.cxx

src/FDM/groundcache.cxx

index 6818577f0751a789f1ed40f3f5b987f03b833de1..9932aa681f163ad203660f3f60fb3536a80720f1 100644 (file)
@@ -143,11 +143,7 @@ public:
 
         // Look for a velocity note
         const SGSceneUserData::Velocity* velocity = getVelocity(transform);
-        // ... no velocity of there is only zero velocity
-        if (velocity && velocity->linear == SGVec3d::zeros() &&
-            velocity->angular == SGVec3d::zeros())
-            velocity = 0;
-        
+
         SGVec3d center = _center;
         _center = SGVec3d(inverseMatrix.preMult(_center.osg()));
         double radius = _radius;
@@ -169,6 +165,7 @@ public:
                 bvhTransform->setAngularVelocity(velocity->angular);
                 bvhTransform->setReferenceTime(_startTime);
                 bvhTransform->setEndTime(_endTime);
+                bvhTransform->setId(velocity->id);
 
                 mSubTreeCollector.popNodeList(parentNodeList, bvhTransform);
             } else {