Jump to: navigation, search

Talk:Nasal Initialization

1,862 bytes added, 8 January
== FGNasalSys init ==
Referring to your addition at [], the FlightGear portion of the patch you can find at [[Initializing Nasal early]] is trivial, but it can be used to expose FlightGear's initialization to the property tree by using a so called [[Howto:Use Property Tree Objects|Property Object]]. That is exactly how the init sequence of fgfs has been documented on the article's talk page: [[Talk:Initializing_Nasal_early#Subsystem_Creation]]. To look at some of the original work, see the commits at [;a=commitdiff;h=c48b7aeb50765f38c589c544380eb9cd8e89a107]. In particular, you may want to take a look at the mechanism used to automatically dump the init sequence to a hash for inspection purposes [;a=commitdiff;h=cac82867615b03daaafd8f201ead6bde8eb06f6d]. In other words, if you'd like to understand parts of the current init sequence (nasal or not), this is a really straightforward approach - i.e. expose things via properties sg::PropertyObject<std::string> and then use a Nasal space listener to track all updates - at that point, you can automatically populate your wiki article, and don't need to manually do any reverse engineering, all you need to do is register a callback to track all loading of Nasal sources in sequential order, you can then use the CPP macros __FILE__ and __LINE__ respectively to add useful information/pointers. That way, you end up with a self-documenting init sequence, which should also come in handy for stuff that bugman has been working on (regression testing and Python support). --[[User:Hooray|Hooray]] ([[User talk:Hooray|talk]]) 13:34, 8 January 2020 (EST)

Navigation menu