|
From: PlayeRom R. L. <rom...@pl...> - 2023-07-25 13:21:54
|
OK, I updated merge requests: https://sourceforge.net/p/flightgear/fgdata/merge-requests/311/ https://sourceforge.net/p/flightgear/flightgear/merge-requests/320/ W dniu 25.07.2023 o 14:27, James Turner pisze: > > >> On 25 Jul 2023, at 13:23, PlayeRom Roman Ludwicki >> <rom...@pl...> wrote: >> >> If we want to get rid of `fgGetBool` when creating `FGEnvironment >> dummy;`, I see the following solution: >> >> 1. set the `is-isa` flag in the `/environament/climate/is-isa` property. >> 2. In the function `FGClimate::bind()` bind the flag >> `_tiedProperties.Tie( "is-isa", &_is_isa);`. >> 3. In the `FGClimate::update` function, call `set_is_isa`: >> >> FGEnvironment dummy; >> dummy.set_is_isa(_is_isa); >> ... >> >> >> This means that `_tiedProperties.Tie` for `is_isa` in >> `FGEnvironment::Tie` is redundant and should be removed. >> >> If this is a more appropriate solution, I can implement it. >> > > Yes, that’s better, if you don’t mind. > > Thank you for digging into this, I knew there was some copying / > re-creating of FGEnvironment but did not realise it had gotten this > complicated … not very easy to hack on :( > >> There is another call of `FGEnvironment dummy;` in >> `MetarProperties::setMetar`, but I wouldn't change anything there, >> because as far as I can see it is only run for the `Live data` >> weather scenario, where `is_isa` must be `false` anyway. >> > Sure, no problem. > > Kind regards, > James > > > > > _______________________________________________ > Flightgear-devel mailing list > Fli...@li... > https://lists.sourceforge.net/lists/listinfo/flightgear-devel -- Pozdrawiam Roman Ludwicki |