From c90d7e96c262645349cd075fdb2765760f47321a Mon Sep 17 00:00:00 2001 From: david Date: Sun, 2 Mar 2003 01:43:00 +0000 Subject: [PATCH] Make sure the atmosphere is updated before the flight model. --- src/Main/main.cxx | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/Main/main.cxx b/src/Main/main.cxx index 2f050852a..7a4241257 100644 --- a/src/Main/main.cxx +++ b/src/Main/main.cxx @@ -903,7 +903,6 @@ void fgUpdateTimeDepCalcs() { globals->get_scenery()->get_cur_elev() > -9990 ) { SG_LOG(SG_FLIGHT,SG_INFO, "Finally initializing fdm"); - cur_fdm_state->init(); if ( cur_fdm_state->get_bound() ) { cur_fdm_state->unbind(); @@ -911,6 +910,10 @@ void fgUpdateTimeDepCalcs() { cur_fdm_state->bind(); } +#ifndef FG_WEATHERCM + globals->get_environment_mgr()->update(delta_time_sec); +#endif + // conceptually, the following block could be done for each fdm // instance ... if ( !cur_fdm_state->get_inited() ) { @@ -1023,10 +1026,6 @@ static void fgMainLoop( void ) { // init routine and we don't have to worry about it again. #endif -#ifndef FG_WEATHERCM - globals->get_environment_mgr()->update(delta_time_sec); -#endif - // Fix elevation. I'm just sticking this here for now, it should // probably move eventually -- 2.39.5