## CREATING A LIVERY PACKAGE

This short tutorial is for those users that want to make livery packages for aircraft and is a compliment to the LiveryAircraft sample project that comes with the SDK. This tutorial briefly covers the process of creating a new package specifically for liveries that can be distributed to other users.IMPORTANT! Currently any projects that have livery packages must also include the aircraft the livery is for. This is due to the way package dependencies currently work and may be changed in the future.

### Creating A Livery Package

The first thing you'll need to do before anything else is create a new project so you can save the package data for the livery. For that you need to go to the [DevMode] menu and select the New Project option, which will open the following window:

You need to select a location to save the project to at this point and also give the project a name, in this case TestLivery (you should also have filled in the default company and creator names in The Project editor before doing this). Once that's done click the button. This will take you to the package creation wizard, where you should select the Custom package type and fill in the relevant details. It is important to note that you should be choosing the LIVERY content type, as shown in the image below:

Once that's done you will be prompted to create your first Asset Group for the package. Here you should give the asset group a name (generally formatted as <aircraft>-livery-<liveryname>) and select SimObject as the asset type:

With that filled in you can go ahead and click on to create the new package and asset group. This will close the wizard and take you back to the Prohejt Editor where you can check the package and asset group details in the Inspector window (if it isn't open then you can open it from the Project Editor View menu):

With that done, go to the Project menu in the project editor and Save your progress.

As there is no tool to edit liveries built in to the Developer Mode UI currently, and so the content of the livery package will have to be added manually to the project. For that, you'll need to open an explorer window (outside the simulation) and browse to the location that you saved the project in the steps outlined above. For the test project we made for this tutorial, the path would be:

The contents of this folder should be something like this:

IMPORTANT! If the PackageSources folder - or any folders mentioned below within PackageSources - does not exist, then it will need to be created manually using the exact naming convention shown in this tutorial.The PackageSources folder is the one we are interested in as that is where we'll be storing the information for our livery. The actual structure of this folder is as follows:

|---+ PackageSources
|---+ SimObjects
|---+ Airplanes
|---+ <PackageName>

And here is the image of the folder structure using the name of the test package that this tutorial is making:

The <PackageName> folder will need to contain the following two items:

• an aircraft.cfg file to redefine which part of the target aircraft will be modified
• a texture folder where the textures used to replace the original aircraft textures will be stored.

### The aircraft.cfg File

The aircraft.cfg file is what tells Microsoft Flight Simulator what aircraft the livery is a "variation" of, and as such should always initially be a copy of the original aircraft.cfg file. We use a copy since any values specified here will over-write the values in the base aircraft and we don't want to change anything other than the livery. So, we use a copy of the base aircraft file and only change a few details related to the livery we are creating the package of.

The first thing you'll need to do is add a new section to the file for the variation. This section tells the simulation what aircraft package this is a variation of and would look something like this:

[VARIATION]
base_container = "..\<Aircraft_Package_Name>"

The path given here is based on the path to the base aircraft within the VFS when the simulation is running. Basically, all aircraft (and their variations) will be placed in an "aircraft" folder within the VFS, so you only need the relative path to the aircraft the livery is for - which is up one folder level - then the name of the aircraft package. This tutorial was based on the SimpleAircraft example, so the path we would use is:

[VARIATION]
base_container = "..\MyCompany_Simple_Aircraft"

With that done, you then need to edit the following entries in the [FLTSIM.N] section (where N is usually 0):

• title
• texture
• ui_variation

Optionally you may also edit the following entries (although this is not required):

• description
• ui_type
• ui_createdby
• ui_thumbnailfile

It is important to note that the name you give the texture parameter is a name that is appended onto the end of the texture folder, not the full or relative path to the folder itself. This is explained in more detail below.

Here is a full example of the [FLTSIM.0] section for a variation based off of the SimpleAircraft sample:

[FLTSIM.0]
title = "My Aircraft Matte Blue Variant" ; Variation name
model = ""
panel = ""
sound = ""
texture = "blue_matte" ; the name appended onto the "texture" folder for checking
kb_checklists = ""
kb_reference = ""
description = "Matte blue paint variation of the Sample Aircraft" ; Variation description.
ui_manufacturer = "My Manufacturer"
ui_type = "Simple Aircraft Variant" ; Variation type
ui_variation = "Matte Blue" ; Variation name
ui_typerole = "Single Engine Prop"
ui_createdby = "MyCompany"
ui_thumbnailfile = ""
ui_certified_ceiling = -1
ui_max_range = -1
ui_autonomy = -1
ui_fuel_burn_rate = -1
atc_id = "G-BAFM"
atc_id_enable = 1
atc_airline = ""
atc_flight_number = ""
atc_heavy = 0
atc_parking_types = "ANY" ; "ANY" / "RAMP" / "CARGO" / "MIL_CARGO" / "MIL_COMBAT" / "GATE" / "DOCK"
atc_parking_codes = ""
atc_id_color = ""
atc_id_font = ""
isAirTraffic = 1
isUserSelectable = 0

You can see here that we've set the path for the texture folder to be "blue_matte". This means that the variation will look in the folder "texture.blue_matte" for the textures to use for the livery.

### The panel.cfg File

When creating the livery or aircraft variation, by default it will "inherit" the values from the panel.cfg file of the base aircraft. However, your livery can include it's own panel.cfg file too, in which case you can choose to either have this file completely overwrite the contents of the base aircraft, or simply add/modify specific parts of the base aircraft file.

When you include a panel.cfg file, the default behaviour is to overwrite everything in the base file, however you can add in the following to the file to then selectively add/overwrite information:

[VARIATION]
override_base_container = 0

This parameter is telling Microsoft Flight Simulator that the panel.cfg file should inherit the base file settings and then to them (or overwrite them) using any additional settings in the current panel.cfg file. For example:

[VARIATION]
override_base_container = 0
[VPainting02]
size_mm = 1024,256
texture = RegistrationNumber
location = exterior
painting00 = Registration/Registration.html?font_color=white, 0, 0, 1024, 256

This is the total contents of the panel.cfg file for the variation, and all it's doing is flagging the base file to not be overwritten, and then supplying a change to the [VPainting02] section. If that section exists in the base, then it will be ignored in favour of the values used here, and if it doesn't exist then the values here will be added to the base panel.cfg.

You should note that this CFG file would go in a folder labelled appropriately - similar to the way the textures folder works, eg: "panel.blue_matte" - beside the livery aircraft.cfg file. The name of this folder is always "panel.<name>", where <name> is the panel name given in the aircraft.cfg file (under the [FLTSIM.N] section using the parameter "panel").

Once you have added the aircraft.cfg file to the livery package folder in PackageSources, you then need to add the textures that are to be used for the livery. These textures would be placed in the "texture.<name>" folder, beside the aircraft.cfg file. The name of this folder is always "texture.<name>", where <name> is the texture name given in the aircraft.cfg file (as explained above).

The contents of this folder would look something like this:

You'll notice that in the image above there is an additional texture.cfg file included along with the texture and thumbnail images. This file provides Microsoft Flight Simulator with fallback folders that will be used should there be any issues, or should the specified variation folder not hold complete texture data. In this file you would write the different folders to fallback to, using the [fltsim] header. Inside this section, fallbacks are defined via the following syntax:

fallback.<index>=<path>

Here the index must be incremented by 1 for each fallback path and must start at 1, for example:

[fltsim]
fallback.1 = ..\..\Mycompany_Livery_Aircraft\texture
fallback.2 = ..\..\Mycompany_Livery_Aircraft\texture.base

You should always include this file in the textures folder to give at least 1 fallback texture for the aircraft variation.

#### Thumbnails

You should also always include the two thumbnail images in the texture folder. These are authored as follows:

• thumbnail.jpg: 1618x582 pixels
• thumbnail_small.jpg: 600x216 pixels

You can use The Aircraft Thumbnail Capture Tool to create these images, and they will be used in the Microsoft Flight Simulator UI to show the livery being used. The images below highlight where the small and regular thumbnail images are actually used:

Note that you don't have to use the name "thumbnail" for these images, nor do you have to save them in the same folder. However if don't use these default names you will have to set the ui_thumbnailfile parameter in the panel.cfg file to reflect the change in name or path. Also note that the _small suffix is required for the small thumbnail, so the naming would be:

• <custom_thumbnail_name>.jpg
• <custom_thumbnail_name>_small.jpg

And in the panel.cfg file you'd have:

ui_thumbnailfile = "<custom_thumbnail_name>.jpg"

### Building The Package

With the folders, CFG file and textures now part of the package folder structure, you need to go back to Microsoft Flight Simulator and set up the AssetDir and OutputDir for the package. For that you need to select the package in the Project Editor, and then in the Inspector window set the relative paths, something like this:

Note that the OutputDir is a relative path within the Packages folder, which will be created automatically for you when you build the package. As such this path needs to be entered manually and then validated by pressing .

Once you have done that you can then go ahead and build the package, by selecting it in the Project Editor and then clicking the button:

This will build the package and - assuming the aircraft that you are creating a livery for is already added to Microsoft Flight Simulator - the new livery should be available from the main menu of the simulation.