]> git.mxchange.org Git - flightgear.git/commitdiff
Update the model manager after the event manager, so that model
authormfranz <mfranz>
Wed, 19 Nov 2008 07:46:10 +0000 (07:46 +0000)
committermfranz <mfranz>
Wed, 19 Nov 2008 07:46:10 +0000 (07:46 +0000)
coordinates that were set relative to the aircraft's position
are picked up before the view update rather than the next cycle.
This avoids ugly fluttering of "passengers" at higher speed.

src/Main/main.cxx

index 8d1baa707cb01db5ac1332157e3c02cc36668d15..adf44f2420d73594f767f3568a1a96633c3f747e 100644 (file)
@@ -177,7 +177,6 @@ void fgUpdateTimeDepCalcs() {
         // do nothing, fdm isn't inited yet
     }
 
-    globals->get_model_mgr()->update(delta_time_sec);
     globals->get_aircraft_model()->update(delta_time_sec);
 
     // Update solar system
@@ -538,6 +537,10 @@ static void fgMainLoop( void ) {
     // run Nasal's settimer() loops right before the view manager
     globals->get_event_mgr()->update(delta_time_sec);
 
+    // pick up model coordidnates that Nasal code may have set relative to the
+    // aircraft's
+    globals->get_model_mgr()->update(delta_time_sec);
+
     // update the view angle as late as possible, but before sound calculations
     globals->get_viewmgr()->update(delta_time_sec);