MIST writeTypes

From DCS World Wiki - Hoggitworld.com
Revision as of 07:19, 23 August 2021 by Grimes (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)


Added with: Mist 4.5
Writes a table of data from your mission file. Contains entries for unit type names, countries, livery names, and CLSIDs. The table that is written is returned in the function.
table mist.debug.writeTypes(string fileName )
Valid Input Values:
Return value:
Return example:
The following is a rough outline of the table format:
    countries = {
       [countryName] = {
          [categoryName] = {
              [unitTypeName] = number of that type for that country,
   units = {
      [unitTypeName] = {
          count = total number of this type in the mission,
          pylons = {
              [pylonIndex] = {
                  [CLSID value] = number of times it is used on that pylon
          CLSID = {
             [CLSID value] = number of times it is used on that aircraft,
          livery_id = {
             [countryName] =
                 [liveryName] = number of times livery is used for that country,
Usage Examples:
The following would output the data to the pass filename.
For this debug function you must (temporarily!) unprotect the Lua environment and enable the io and lfs libraries. You do this by commenting out the sanitizeModule calls in <DCS main directory>/Scripts/MissionScripting.lua. Just be sure to re-protect yourself later when you run missions from untrusted sources.
Related Functions
writeData, dumpDBs, dump_G, writeGroup, writeTypes, changeSetting

Scripting Engine

MIST Root Page