aircraft.livery and aircraft.livery_update are now only wrappers for more generic classes, which one can also use directly instead. They allow to manage more than just livery XML files. One could allow users to choose a livery, seat covers, flight attendant uniforms, ... :-) each of them separately and like liveries are handled now.
Instead of aircraft.livery.init, one writes something like this: var foo_dialog = gui.OverlaySelector.new( "Select Foo", # title of selection dialog "Aircraft/xy/Models/Foo", # directory with XML files "sim/model/foo/name"); # property for name entries In bindings one can then use xy.foo_dialog.open(); # for the menu xy.foo_dialog.toggle(); # for key bindings xy.foo_dialog.close(); # for ... no idea :-) If one wants to send the choice over MP, then one has to assign an MP property (which needs to get created in the *-set.xml file -- otherwise MP won't send it): var foo_dialog = gui.OverlaySelector.new( "Select Foo", # title of selection dialog "Aircraft/xy/Models/Foo", # directory with XML files "sim/model/foo/name", # property for name entries nil, # (sort dialog entries by name) "sim/multiplay/generic/string");# use this property for MP In the model XML file one uses instead of aircraft.livery_update: <load> var update = aircraft.overlay_update.new(); update.add("Aircraft/xy/Models/Liveries", "sim/model/livery/file"); update.add("Aircraft/xy/Models/Foo", "sim/multiplay/generic/string"); </load> <unload> update.stop(); </unload> Each of the update.add() does also take an optional callback function as third argument. This is then called whenever that property got changed. Maybe we should throw out aircraft.livery(_update) and convert everything to the generic method now. Don't know yet ... m. ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Flightgear-devel mailing list Flightgear-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flightgear-devel