]> git.mxchange.org Git - flightgear.git/commitdiff
Fixed bug in timed update cycling.
authordavid <david>
Wed, 6 Nov 2002 16:04:04 +0000 (16:04 +0000)
committerdavid <david>
Wed, 6 Nov 2002 16:04:04 +0000 (16:04 +0000)
src/Model/model.cxx

index b32d054ee9c20ae103ba45633db5cc5daa5fddde..895923bf9648da906cd103a856d84e40c10876d9 100644 (file)
@@ -507,10 +507,9 @@ TimedAnimation::update ()
     float sim_time_sec = globals->get_sim_time_sec();
     if ((sim_time_sec - _last_time_sec) >= _duration_sec) {
         _last_time_sec = sim_time_sec;
+        _step++;
         if (_step >= getBranch()->getNumKids())
             _step = 0;
-        else
-            _step++;
         ((ssgSelector *)getBranch())->selectStep(_step);
     }
 }