From: curt Date: Sat, 20 Sep 2003 03:33:06 +0000 (+0000) Subject: Another step towards making aircraft more self contained. YASim aircraft X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=7807a68fa387a5f4e5b30aa1fe30fb1452dd183a;p=flightgear.git Another step towards making aircraft more self contained. YASim aircraft now read the config file out of the individual aircraft directory rather than the collective Aircraft-yasim/ directory (which is now obsolete.) This requires a corresponding update of the base package cvs. --- diff --git a/src/FDM/YASim/YASim.cxx b/src/FDM/YASim/YASim.cxx index b2906f152..294ddfe35 100644 --- a/src/FDM/YASim/YASim.cxx +++ b/src/FDM/YASim/YASim.cxx @@ -146,8 +146,7 @@ void YASim::init() } // Build a filename and parse it - SGPath f(globals->get_fg_root()); - f.append("Aircraft-yasim"); + SGPath f(fgGetString("/sim/aircraft-dir")); f.append(fgGetString("/sim/aero")); f.concat(".xml"); readXML(f.str(), *_fdm); diff --git a/src/Main/fg_init.cxx b/src/Main/fg_init.cxx index cae81a4d4..80a9f868d 100644 --- a/src/Main/fg_init.cxx +++ b/src/Main/fg_init.cxx @@ -568,6 +568,7 @@ bool fgInitConfig ( int argc, char **argv ) { string result = fgFindAircraftPath( aircraft_search, aircraft_set ); if ( !result.empty() ) { + fgSetString( "/sim/aircraft-dir", result.c_str() ); SGPath full_name( result ); full_name.append( aircraft_set );