|
From: James T. <ja...@fl...> - 2023-06-05 14:25:03
|
> On 5 Jun 2023, at 12:20, mer...@al... wrote: > > So it wouldn't break compatibility? *confused* Right, this is not actually a change in what we allow, although it might need some clarification in the UI in some places. Indeed, in some places (like cross-aircraft path imports in a model.xml) we actually *require* the Aircraft/ prefix, eg to find stuff in FGData/Aircraft/Instrument (or Instruments-3D). As I said, this area is a bit of a mess, but the key point is we can add in other directory names besides Aircraft and it won’t break (There is actually code to fake the ‘Aircraft’ prefix if it’s not present on disk, that’s why it works without such a directory right now) >> You mean like the hangar file for aircraft? >> Technically it’s an (XML) catalogue of packages, right now the only >> package type is ‘aircraft’ but there is nothing preventing >> different types, or mixing aircraft and livery packages in a single >> catalogue. >> To support this we’d likely extend the python scripts in FGMeta >> which currently scan an Aircraft/ tree for -set.xml files, to also >> scan the Livery/** dirs for their XMLs: probably called >> livery-metadata.xml to be consistent with the naming scheme Florent >> used for add-ons. > > Can't we just scan for the normal livery xmls? So we don't add another thing to look for? Well, then we need to extend them with whatever meta-data is necessary to make packages: which I can guess is: - human readable name - description - author - tags (for searching) - list of compatible aircraft variants - etc, etc Because this information is orthogonal (I think) to what’s in the XML right now, I’d propose a new livery-meta-data.xml is simpler (I probably should have done this for aircraft, but the existing -set.xml was …. close enough) But, if you think you can fit the required meta-data into the existing XML, then sure, we can do that. Looking at the Python code that scans the aircraft -set.xmls to build the current packages might give you some idea which option is easier: https://sourceforge.net/p/flightgear/fgmeta/ci/next/tree/python3-flightgear/flightgear/meta/aircraft_catalogs/catalog.py#l46 Kind regards, James |