From 5d8e5f29e0fe880ddb94856460e1553869c6a576 Mon Sep 17 00:00:00 2001 From: mfranz Date: Sat, 3 Nov 2007 21:02:28 +0000 Subject: [PATCH] Csaba HALASZ: fix IVSI instrument problem "I have been investigating the Concorde IVSI problem. I came to the conclusion that the trouble is that the environment altitude and thus the pressure (which is calculated from that) is lagging by 1 frame. Normally that wouldn't be a problem, but the IVSI calculates rate of change and it will use the new dt with the old value difference, thereby arriving at bad results if dt changes (and it does)." --- src/Main/fg_init.cxx | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/src/Main/fg_init.cxx b/src/Main/fg_init.cxx index fc2fc7ec6..07effac56 100644 --- a/src/Main/fg_init.cxx +++ b/src/Main/fg_init.cxx @@ -1650,6 +1650,15 @@ bool fgInitSubsystems() { // model or control parameters are set fgAircraftInit(); // In the future this might not be the case. + + //////////////////////////////////////////////////////////////////// + // Initialize the weather subsystem. + //////////////////////////////////////////////////////////////////// + + // Initialize the weather modeling subsystem + globals->add_subsystem("environment", new FGEnvironmentMgr); + + //////////////////////////////////////////////////////////////////// // Initialize the aircraft systems and instrumentation (before the // autopilot.) @@ -1695,14 +1704,6 @@ bool fgInitSubsystems() { fgInitTimeOffset(); // the environment subsystem needs this - //////////////////////////////////////////////////////////////////// - // Initialize the weather subsystem. - //////////////////////////////////////////////////////////////////// - - // Initialize the weather modeling subsystem - globals->add_subsystem("environment", new FGEnvironmentMgr); - - //////////////////////////////////////////////////////////////////// // Initialize the lighting subsystem. //////////////////////////////////////////////////////////////////// -- 2.39.5