Addoninfo.txt: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (→‎Keys: Left 4 Dead 2-only.)
m (→‎Non-existent or deprecated keys: They may still be useful as metainformation)
 
(46 intermediate revisions by 9 users not shown)
Line 1: Line 1:
{{DISPLAYTITLE:Deadline and Deadline 2 AddonInfo Files}}
The AddonInfo.txt is a [[.txt|plain-text file]] which contains an [[VPK|addon]]’s metadata. It resides in the Root folder of addons. ''The folder containing "materials", "Models", "Sound", ect.''<br>
This file and its functionality were introduced with the {{l4dbranch|4|nt=4}}, and is written in the ''[[KeyValues|KeyValues 1]]'' structure.<br>
In case you upload the addon to the Steam Workshop, the workshop submission's metadata (name, version, author, and description) will be used instead, but the AddonContent flags will still be read from the addoninfo.txt.<br>


This is the addoninfo metadata file included with the sample Deadline campaign. Feel free to use this as a template for the metadata for your own [[Add-on|custom addons]]. The full add-on and source files can be downloaded off a website hosted by Steam:
Both the {{Source|4|nt=1}} and the deprecated external application [[addoninstaller.exe]] will parse this file, though with significant differences.<br>
* {{l4d}} [http://media.steampowered.com/apps/513/deadline.html Dead Line]
{{Source|4}} will parse this file from all addons listed in addonlist.txt when loading search paths from [[gameinfo.txt]] at startup and with subsequent calls to ''[[ConCommand]]'' {{Command|update_addon_paths}}.<br>
* {{l4d2}} [http://media.steampowered.com/apps/513/deadline2.html Dead Line 2]
Addoninstaller.exe only parses addoninfo.txt when staging addons during user-initialized installation.<br>


== Keys ==
{{warning|Avoid using addoninstaller.exe to install addons. As of at least client version 2.2.2.6 of {{L4D2|4}}, the addoninstaller no longer functions as intended and actually breaks the addons that it is supposed to install.}}
{| class=wikitable |
{{warning|You should {{Em|always}} ship your addons with addoninfo.txt, {{Em|even if you distribute through the Steam Workshop}}. Otherwise, your users will encounter the following undesirable behavior:
! Key !! Description
* Your addon will load before all other addons specified in addonlist.txt.
* Your addon will never appear in the Addons menu, stopping you from enabling/disabling the addon. Although this only happens when the user takes the mod from the "Addons/Workshop" folder and installs it into "Addons".}}
 
== Specification ==
AddonInfo.txt is a text files that determine the addon's name, version number, description and some content tags.<br>
You can copy this template into a text file, edit the data according to what you need and save it as "Addoninfo.txt" in the Root folder of your addon. ''The folder containing "materials", "Models", "Sound", ect.''
 
<source>
"AddonInfo"
{
addonversion "1.0" //Max 31 characters. Allows decimals.
addontitle "Addon_Name_Here" //Max 127 characters.
addonauthor "Author_Name_Here" //Max 119 characters.
addonDescription "Description_Here" //Max 1023 characters.
// These booleans act as content descriptors, showing up as tags ingame.
// Users can filter addons by these tags and see what's inside without reading the description.
// Set to 1 where applicable. You can use multiple, such as "Weapons" and "skins".
addonContent_Campaign 0 //Has multiple maps that string into a campaign. Represented ingame as: Campaigns
addonContent_Map 0 //Has at least one map. Represented ingame as: Campaigns
addonContent_Skin 0 //Modifies an existing model or texture. Represented ingame as: Skins
addonContent_weapon 0 //Modifies a weapon in some way. (or adds melee weapons) Represented ingame as: Weapons
addonContent_BossInfected 0 //Modifies the Tank or the Witch. Represented ingame as: Infected
addonContent_CommonInfected 0 //Modifies CI . Represented ingame as: Infected
addonContent_Survivor 0 //Modifies Survivors. Represented ingame as: Survivors
addonContent_Sound 0 //Modifies a sound. (not for when a map is shipped with sounds) Represented ingame as: Sounds
addonContent_Music 0 //Modifies specifically music. Represented ingame as: Sounds
addonContent_Script 0 //Modifies a script. Represented ingame as: Scripts
addonContent_prop 0 //Modifies a prop Represented ingame as: Items
}</source>
 
=== Non-existent or deprecated keys ===
 
The following keys either used to exist at one point or were never properly implemented in the first place.<br>
Some of these can still be seen in the [[#“DEADLINE”|“DEADLINE”]] and [[#“DEADLINE 2”|“DEADLINE 2”]] AddonInfo.txt files, which were supposed to be an example, but they aren't used in-game.
 
{| class="standard-table" style="width: 100%"
! style="text-align: left" | Key  
! style="text-align: left" | Description
|-
|-
| addonSteamAppID || Steam App ID: 500 for Left 4 Dead, 550 for Left 4 Dead 2
| addonSteamAppID
| The AppID of the addon’s target game. Only addoninstaller.exe uses this.
|-
|-
| addonTitle || Title of the addon, ~20 characters maximum
| addonTagline
| The addon’s subtitle or tagline. May have had a similar purpose to key poster/posterTagline in [[Mission Files|mission files]].
|-
|-
| addonVersion || Version number of the addon, <major>.<minor>
| addonAuthorSteamID
| The addon author’s [[SteamID]]. Supposedly used to construct a URL to the author’s Steam profile page.
|-
|-
| addonTagline || Tagline/wrap-up short description, ~100 characters maximum
| addonSteamGroupName
| The addon’s Steam group. Supposedly used to construct a URL to the addon’s Steam group page.
|-
|-
| addonAuthor || Name of the author
| addonURL0
| The addon’s homepage. May have had a similar purpose to key Website in [[Mission Files|mission files]].
|-
|-
| addonAuthorSteamID || (Optional) Steam ID of author. We use this to construct a URL to the author's page.
| addonContent_Survival<br>addonContent_Versus<br>addonContent_Scavenge
| If the addon provides custom campaigns supporting the Survival, Versus, or Scavenge game modes. This functionality is provided by [[Mission Files|mission files]].
|-
|-
| addonSteamGroupName || (Optional) Steam group related to the add-on. We use this to construct a URL to the group page.
| addonContent_Prefab
| If the addon provides custom {{Hammer|4}} {{lc:[[Prefabs]]}}.
|-
|-
| addonURL0 || Home page of addon with a download link
| addonContent_Spray
| If the addon provides custom logos.
|-
|-
| addonContent_Campaign || If the addon is a series of connected maps with a finale
| addonContent_BackgroundMovie
| If the addon provides custom background movies.
|-
|-
| addonContent_Survival || If the addon supports survival
| Content_Weapon
| If the addon provides custom weapons (e.g., “…a new weapon, i.e. guns, explosives, booby traps, hot tar, etc.”).
|-
|-
| addonContent_Scavenge || If the addon supports scavenge
| Content_WeaponModel
| If the addon provides custom weapon model.
|-
|-
| addonContent_Versus || If the addon supports versus
| addonDescription_{{Var|locale}}
|-
| The addon’s description localized for locale {{Var|locale}}, where {{Var|locale}} is an [[wp:List of ISO 639-1 codes|ISO 639-1 code]] in ALL CAPS.
| addonContent_Map || If the addon is a standalone map
|}
|-
 
| addonContent_Survivor || If the addon replaces a character model: 0=false, 1=true, String in quotes if replaces specific single character, i.e. "Coach"
== Content tag handling ==
|-
 
| addonContent_Skin || If the addon provides a new skin: 0 for no new skin(s), 1 for multiple skins, string for single skin (the latter only on Left 4 Dead 2)
An addon’s addoninfo [[#kv-addoninfo-keys|content keys]] provide an abstraction over {{Source|4}}’s implementation-specific content tags.<br>
|-
{{Source|4}} will convert all keys into an internal representation (typically, a bitfield).<br>
| addonContent_BossInfected || If the addon provides a new boss model
A content key {{Em|may}} correspond to its internal tag; some keys provide redundant meaning useful only to authors and distributors.<br>
|-
{{Source|4}} will use these content tags to describe and filter addons in the [[CBaseModFrame]] Addons.<br>
| addonContent_CommonInfected || If the addon provides a new common infected
 
|-
 
| addonContent_Music || If the addon has custom music
=== In {{L4D|4}} and {{AS|4}} ===
|-
 
| addonContent_Sound || If the addon has custom sounds
{{L4D|4}} maintains a one-to-one correspondance between content keys and content tags. The handler closely resembles that found in the {{AS|4}} SDK.<br>
|-
 
| addonContent_Prop || If the addon has custom props
{{Source|4}} will generate the content label by concatenating the VGUI localization strings corresponding to the given content tag followed into an array of 60 wide characters.<br>
|-
The right-most comma will always be replaced with a NULL terminator.<br>
| addonContent_Prefab || If the addon has custom prefabs
The effective length of the label is 59 characters since the last character will always be a NULL terminator.<br>
|-
 
| addonContent_Spray || If the addon provides new sprays
 
|-
 
| addonContent_Script || If the addon has scripts
=== In {{L4D2|4}} ===
|-
 
| addonContent_BackgroundMovie || If the addon replaces the background movie
{{L4D2|4}} stores the content keys for each addon as an [[integer|int16_t]] representing the following bitfield (assume little-endian):
|-
<div style="overflow:auto">
| Content_Weapon || If the addon provides a new weapon, i.e. guns, explosives, booby traps, hot tar, etc.
{|class="standard-table mw-collapsible" style="overflow: auto"
|-
|+ style="text-align: left" | {{L4D2|4}} content tag bitfield''
| Content_WeaponModel || If the addon overrides a weapon skin (for existing weapons)
|-
| addonDescription || Description of addon
|-
| addonDescription_DA || Danish description
|-
| addonDescription_NL || Dutch description
|-
| addonDescription_FI || Finnish description
|-
| addonDescription_FR || French description
|-
| addonDescription_DE || German description
|-
| addonDescription_IT || Italian description
|-
| addonDescription_JA || Japanese description
|-
| addonDescription_KO || Korean description
|-
| addonDescription_NO || Norwegian description
|-
| addonDescription_PL || Polish description
|-
| addonDescription_PT || Portuguese description
|-
|-
| addonDescription_RU || Russian  description
! style="text-align: right" scope="row" | Bit
| 15
| 14
| 13
| 12
| 11
| 10
| 9
| 8
| 7
| 6
| 5
| 4
| 3
| 2
| 1
| 0
|-
|-
| addonDescription_ZH || Chinese description
! style="text-align: right" scope="row" | Tag
| N/A
| N/A
| N/A
| N/A
| CONTENT_ITEM
| CONTENT_UI
| CONTENT_SCRIPT
| CONTENT_SOUND
| CONTENT_SURVIVOR
| CONTENT_INFECTED
| CONTENT_MUTATION
| CONTENT_WEAPON
| CONTENT_SKIN
| CONTENT_MISCELLANEOUS
| CONTENT_CAMPAIGN
| CONTENT_RESERVED
|-
|-
| addonDescription_ES || Spanish description
! style="text-align: right" scope="row" | [[#kv-addoninfo-keys|Key]]
|-
| N/A
| addonDescription_SV || Swedish description
| N/A
| N/A
| N/A
| addonContent_prop
| N/A
| addonContent_Script
| addonContent_Sound<br>addonContent_Music
| addonContent_Survivor
| addonContent_BossInfected<br>addonContent_CommonInfected
| N/A
| addonContent_Weapon
| addonContent_Skin
| N/A
| addonContent_Campaign<br>addonContent_Map
| N/A
|}
|}
</div>
The content tags CONTENT_MISCELLANEOUS, CONTENT_MUTATION, and CONTENT_UI can be set {{Em|only through the Steam Workshop}}.
{{Source|4}} will generate the content label by concatenating the VGUI localization strings corresponding to the given content tag followed into an array of 60 wide characters.
The right-most comma will always be replaced with a NULL terminator.
The effective length of the label is 59 characters since the last character will always be a NULL terminator.
== Examples ==
The following are outdated examples of old "Example campaigns". They hold now deprecated strings, but they're still useful as a basic example of what an addoninfo would look like.
Avoid using the [[#“DEADLINE”|“DEADLINE”]] or [[#“DEADLINE 2”|“DEADLINE 2”]] samples as templates. Use the one above.
=== “DEADLINE” ===
Download Valve’s “DEADLINE” campaign from [http://media.steampowered.com/apps/513/deadline.html here].
The following snippet matches the original exactly as of April 30, 2023.


== Left 4 Dead ==
<source>
<source lang=ini>
// The addoninfo.txt file is a metadata file that is required by all Left 4 Dead Add-ons.
"AddonInfo"
"AddonInfo"
{
{
"addonSteamAppID"                  "500"
addontitle "Dead Line"                                     // Add-on title that shows up in Add-ons list. ~20 chars max
"addonTitle"                      "Dead Line"
addonversion         1.3                                            // Add-on version.
"addonVersion"                    "1.0"
addontagline "Catch the last subway... out of hell."         // Add-on tagline or wrap-up- a short description. ~100 chars max
"addonTagline"                    "Catch the last subway... out of hell."
addonauthor "Valve"                                         // Name/alias of the author
"addonAuthor"                      "Valve"
addonauthorSteamID "http://steamcommunity.com/groups/Valve"        // Steam Profile URL of author or group
"addonAuthorSteamID"              "MikeDurand"
"addonSteamGroupName"              "deadlineadd-on"
"addonURL0"                        "http://media.steampowered.com/apps/513/deadline.html"
"addonContent_Campaign"            "1"
addonContent_Campaign 1                                 //This addon provides muliple connected maps with a finale
"addonContent_Survival"            "0"
"addonContent_Scavenge"            "0"
"addonContent_Versus"              "0"
"addonContent_Map"                "0"
"addonContent_Survivor"            "0"
addonURL0 "http://media.steampowered.com/apps/513/deadline.html" //An html home page for the add-on that includes a download link.
"addonContent_Skin"                "0"
"addonContent_BossInfected"        "0"
// short description that appears in the Add-on list screen...
"addonContent_CommonInfected"      "0"
addonDescription "Survivors must escape on a subway train in this short tutorial example campaign. Get source files and tools for creating your own campaigns by downloading the Left 4 Dead Authoring tools SDK, which is available under the 'Tools' tab in Steam."
"addonContent_Music"              "0"
"addonContent_Sound"              "0"
"addonContent_Prop"                "0"
"addonContent_Prefab"              "0"
"addonContent_Spray"              "0"
"addonContent_Script"              "0"
"addonContent_BackgroundMovie"    "0"
"Content_Weapon"                  "0"
// Authors can add localized descriptions here. (Not yet supported)
"Content_WeaponModel"              "0"
addonDescription_FR "Les survivants doivent s'échapper en métro dans cette carte du tutoriel. Obtenez les fichiers et les outils pour créer vos propres cartes en chargeant les outils de création SDK Left 4 Dead qui sont disponibles sous l'onglet "Outils" sur Steam."
}</source>
"addonDescription"                "Survivors must escape on a subway train in this short tutorial example campaign. Get source files and tools for creating your own campaigns by downloading the Left 4 Dead 2 Authoring tools SDK, which is available under the 'Tools' tab in Steam."
 
"addonDescription_DA"              "Overlevende skal undslippe et S-tog i denne korte tutorial eksempel kampagne. Få kildefiler og værktøjer til at skabe dine egne kampagner ved at downloade Left 4 Dead 2 Authoring værktøjer SDK, som er tilgængelig under 'Funktioner' fanen i Steam."
=== “DEADLINE 2” ===
"addonDescription_NL"              "Overlevenden moet ontsnappen op een metro in deze korte handleiding voorbeeld campagne. Krijg bronbestanden en tools voor het maken van uw eigen campagnes door het downloaden van de Left 4 Dead 2 Authoring gereedschappen SDK, die beschikbaar is op het tabblad 'Extra' in Steam."
 
"addonDescription_FI"              "Survivors on pelastautua metro tässä lyhyessä harjoitusesimerkit kampanja. Hanki lähdetiedostot ja työkalut luoda omia kampanjoita lataamalla Left 4 Dead 2 Authoring Tools SDK, joka on käytettävissä Työkalut-välilehti Steam."
Download Valve’s “DEADLINE 2” campaign from [http://media.steampowered.com/apps/513/deadline2.html here].
"addonDescription_FR"              "Les survivants doivent s'échapper en métro dans cette carte du tutoriel. Obtenez les fichiers et les outils pour créer vos propres cartes en chargeant les outils de création SDK Left 4 Dead 2 qui sont disponibles sous l'onglet 'Outils' sur Steam."
The following snippet matches the original exactly as of April 30, 2023.
"addonDescription_DE"              "Survivors muss auf einer U-Bahn in diesem kurzen Tutorial beispielsweise Kampagne entkommen. Holen Sie sich die Quelldateien und Werkzeuge für die Erstellung eigener Kampagnen, indem Sie die Left 4 Dead 2 Authoring Tools SDK, welches unter der Registerkarte 'Tools' in Steam."
"addonDescription_IT"              "I sopravvissuti devono sfuggire su un treno della metropolitana in questa breve campagna esempio tutorial. Ottenere file di origine e di strumenti per la creazione di campagne scaricando il Left 4 Dead 2 Authoring Tools SDK, che è disponibile sotto la scheda 'Strumenti' nel vapore."
"addonDescription_JA"              "生存者はこの短いチュートリアルの例のキャンペーンの地下鉄電車の中でエスケープする必要があります。スチームで[ツール]タブの下で利用可能ですレフト4デッドオーサリングツールのSDKをダウンロードすることにより、独自のキャンペーンを作成するためのソースファイルやツールを入手してください。"
"addonDescription_KO"              "생존자들은이 짧은 튜토리얼 예제 캠페인 지하철에서 탈출해야합니다. 증기의 '도구'탭에 따라 사용할 수 있습니다 레프트 4 데드 저작 도구 SDK를 다운로드하여 자신의 캠페인을 만들기위한 소스 파일과 도구를 얻을."
"addonDescription_NO"              "Overlevende må rømme på et tog i denne korte opplæringen eksempel kampanjen. Få kildefilene og verktøy for å lage dine egne kampanjer ved å laste ned Left 4 Dead 2 Authoring verktøy SDK, som er tilgjengelig under 'Verktøy'-fanen i Steam."
"addonDescription_PL"              "Ocaleni muszą uciekać na pociąg metra w tej krótkiej kampanii przykład samouczka. Pobierz pliki źródłowe i narzędzia do tworzenia własnych kampanii pobierając Left 4 Dead 2 Authoring narzędzi SDK, który jest dostępny w zakładce 'Narzędzia' w Steam."
"addonDescription_PT"              "Sobreviventes deve escapar em um trem do metrô nesta campanha exemplo curto tutorial. Obter arquivos de origem e ferramentas para criar suas próprias campanhas baixando o Left 4 Dead 2 Authoring ferramentas SDK, que está disponível na aba 'Ferramentas' no Steam."
"addonDescription_RU"              "Выжившие должны бежать на поезд метро, ​​в этой короткой кампании пример урока. Получить исходные файлы и инструменты для создания собственных кампаний, загрузив Left 4 Dead 2 Authoring инструментов SDK, который доступен на вкладке 'Инструменты' в Steam."
"addonDescription_ZH"              "幸存者必须逃离地铁列车在这个简短的教程示例活动。获取源文件和工具下载左4人死亡创作工具SDK,这是可以在“工具”选项卡下蒸汽用于创建您自己的运动。"
"addonDescription_ES"              "Los sobrevivientes deben escapar en un tren subterráneo en esta corta campaña de ejemplo del tutorial. Obtenga los archivos de origen y las herramientas para crear sus propias campañas por descargar el Left 4 Dead 2 Authoring herramientas SDK, que está disponible en la pestaña 'Herramientas' en Steam."
"addonDescription_SV"              "Överlevande måste fly på ett tunnelbanetåg i denna korta handledning exempel kampanjen. Få källfiler och verktyg för att skapa dina egna kampanjer genom att ladda ner Left 4 Dead 2 Authoring Tools SDK, som är tillgänglig under 'Verktyg' fliken i Steam."
}
</source>


== Left 4 Dead 2 ==
<source>
<source lang=ini>
// The addoninfo.txt file is a metadata file that is required by all Source Engine Add-ons.
"AddonInfo"
"AddonInfo"
{
{
"addonSteamAppID"                  "550"
addonSteamAppID         550                                                    // 500 is the app ID for Left 4 Dead, 550 for Left 4 Dead 2
"addonTitle"                      "Dead Line 2"
addontitle              "Dead Line 2"                                           // Add-on title that shows up in Add-ons list. ~20 chars max
"addonVersion"                    "1.0"
addonversion     1.0                                                     // Add-on version.
"addonTagline"                    "Catch the last subway... out of hell... Again!"
addontagline            "Catch the last subway... out of hell... Again!"     // Add-on tagline or wrap-up- a short description. ~100 chars max
"addonAuthor"                      "Valve"
addonauthor            "Valve"                                                 // Name/alias of the author
"addonAuthorSteamID"               "YasserMalaika"
addonSteamGroupName    "deadline2add-on"                                       // (Optional) Steam group related to the add-on. We use this to construct a URL to the group page.
"addonSteamGroupName"              "deadlineadd-on"
addonauthorSteamID      "YasserMalaika"                                         // (Optional) Steam ID of author. We use this to construct a URL to the author's page.
"addonURL0"                        "http://media.steampowered.com/apps/513/deadline2.html"
addonContent_Campaign  1                                                     //This addon provides muliple connected maps with a finale
addonURL0               "http://media.steampowered.com/apps/513/deadline2.html" //An html home page for the add-on that includes a download link.
"addonContent_Campaign"            "1"
// short description that appears in the Add-on list screen...
"addonContent_Survival"            "0"
addonDescription        "Survivors must escape on a subway train in this short tutorial example campaign. Get source files and tools for creating your own campaigns by downloading the Left 4 Dead 2 Authoring tools SDK, which is available under the 'Tools' tab in Steam."
"addonContent_Scavenge"            "0"
"addonContent_Versus"              "0"
"addonContent_Map"                "0"
"addonContent_Survivor"            "0"
// Authors can add localized descriptions here. (Not yet supported)
"addonContent_Skin"                "0"
addonDescription_FR     "Les survivants doivent s'échapper en métro dans cette carte du tutoriel. Obtenez les fichiers et les outils pour créer vos propres cartes en chargeant les outils de création SDK Left 4 Dead 2 qui sont disponibles sous l'onglet "Outils" sur Steam."
}</source>
"addonContent_BossInfected"        "0"
"addonContent_CommonInfected"      "0"
"addonContent_Music"              "0"
"addonContent_Sound"              "0"
"addonContent_Prop"                "0"
"addonContent_Prefab"              "0"
"addonContent_Spray"              "0"
"addonContent_Script"              "0"
"addonContent_BackgroundMovie"    "0"
"Content_Weapon"                  "0"
"Content_WeaponModel"              "0"
"addonDescription"                "Survivors must escape on a subway train in this short tutorial example campaign. Get source files and tools for creating your own campaigns by downloading the Left 4 Dead 2 Authoring tools SDK, which is available under the 'Tools' tab in Steam."
"addonDescription_DA"              "Overlevende skal undslippe et S-tog i denne korte tutorial eksempel kampagne. Få kildefiler og værktøjer til at skabe dine egne kampagner ved at downloade Left 4 Dead 2 Authoring værktøjer SDK, som er tilgængelig under 'Funktioner' fanen i Steam."
"addonDescription_NL"              "Overlevenden moet ontsnappen op een metro in deze korte handleiding voorbeeld campagne. Krijg bronbestanden en tools voor het maken van uw eigen campagnes door het downloaden van de Left 4 Dead 2 Authoring gereedschappen SDK, die beschikbaar is op het tabblad 'Extra' in Steam."
"addonDescription_FI"              "Survivors on pelastautua metro tässä lyhyessä harjoitusesimerkit kampanja. Hanki lähdetiedostot ja työkalut luoda omia kampanjoita lataamalla Left 4 Dead 2 Authoring Tools SDK, joka on käytettävissä Työkalut-välilehti Steam."
"addonDescription_FR"              "Les survivants doivent s'échapper en métro dans cette carte du tutoriel. Obtenez les fichiers et les outils pour créer vos propres cartes en chargeant les outils de création SDK Left 4 Dead 2 qui sont disponibles sous l'onglet 'Outils' sur Steam."
"addonDescription_DE"              "Survivors muss auf einer U-Bahn in diesem kurzen Tutorial beispielsweise Kampagne entkommen. Holen Sie sich die Quelldateien und Werkzeuge für die Erstellung eigener Kampagnen, indem Sie die Left 4 Dead 2 Authoring Tools SDK, welches unter der Registerkarte 'Tools' in Steam."
"addonDescription_IT"              "I sopravvissuti devono sfuggire su un treno della metropolitana in questa breve campagna esempio tutorial. Ottenere file di origine e di strumenti per la creazione di campagne scaricando il Left 4 Dead 2 Authoring Tools SDK, che è disponibile sotto la scheda 'Strumenti' nel vapore."
"addonDescription_JA"              "生存者はこの短いチュートリアルの例のキャンペーンの地下鉄電車の中でエスケープする必要があります。スチームで[ツール]タブの下で利用可能ですレフト4デッド2オーサリングツールのSDKをダウンロードすることにより、独自のキャンペーンを作成するためのソースファイルやツールを入手してください。"
"addonDescription_KO"              "생존자들은이 짧은 튜토리얼 예제 캠페인 지하철에서 탈출해야합니다. 증기의 '도구'탭에 따라 사용할 수 있습니다 레프트 4 데드 2 제작 도구 SDK를 다운로드하여 자신의 캠페인을 만들기위한 소스 파일과 도구를 얻을."
"addonDescription_NO"              "Overlevende må rømme på et tog i denne korte opplæringen eksempel kampanjen. Få kildefilene og verktøy for å lage dine egne kampanjer ved å laste ned Left 4 Dead 2 Authoring verktøy SDK, som er tilgjengelig under 'Verktøy'-fanen i Steam."
"addonDescription_PL"              "Ocaleni muszą uciekać na pociąg metra w tej krótkiej kampanii przykład samouczka. Pobierz pliki źródłowe i narzędzia do tworzenia własnych kampanii pobierając Left 4 Dead 2 Authoring narzędzi SDK, który jest dostępny w zakładce 'Narzędzia' w Steam."
"addonDescription_PT"              "Sobreviventes deve escapar em um trem do metrô nesta campanha exemplo curto tutorial. Obter arquivos de origem e ferramentas para criar suas próprias campanhas baixando o Left 4 Dead 2 Authoring ferramentas SDK, que está disponível na aba 'Ferramentas' no Steam."
"addonDescription_RU"              "Выжившие должны бежать на поезд метро, ​​в этой короткой кампании пример урока. Получить исходные файлы и инструменты для создания собственных кампаний, загрузив Left 4 Dead 2 Authoring инструментов SDK, который доступен на вкладке 'Инструменты' в Steam."
"addonDescription_ZH"              "幸存者必须逃离地铁列车在这个简短的教程示例活动。获取源文件和工具下载左4人死亡2制作工具SDK,这是可以在“工具”选项卡下蒸汽用于创建您自己的运动。"
"addonDescription_ES"              "Los sobrevivientes deben escapar en un tren subterráneo en esta corta campaña de ejemplo del tutorial. Obtenga los archivos de origen y las herramientas para crear sus propias campañas por descargar el Left 4 Dead 2 Authoring herramientas SDK, que está disponible en la pestaña 'Herramientas' en Steam."
"addonDescription_SV"              "Överlevande måste fly på ett tunnelbanetåg i denna korta handledning exempel kampanjen. Få källfiler och verktyg för att skapa dina egna kampanjer genom att ladda ner Left 4 Dead 2 Authoring Tools SDK, som är tillgänglig under 'Verktyg' fliken i Steam."
}
</source>


== See also ==
== See also ==
* [[L4D Campaign Add-on Tutorial]]
* [[L4D Campaign Add-on Tutorial]]
* [[L4D 2 Campaign Add-on Tutorial]]
* [[L4D 2 Campaign Add-on Tutorial]]
* [[Deadline Mission File]]
* [[Deadline Mission File]]


[[Category:Source]]
[[Category:Left 4 Dead]]
[[Category:Left 4 Dead]]
[[Category:Left 4 Dead 2]]
[[Category:Left 4 Dead 2]]
[[Category:Plain text files]]

Latest revision as of 14:15, 4 September 2025

The AddonInfo.txt is a plain-text file which contains an addon’s metadata. It resides in the Root folder of addons. The folder containing "materials", "Models", "Sound", ect.
This file and its functionality were introduced with the Left 4 Dead engine branch Left 4 Dead engine branch, and is written in the KeyValues 1 structure.
In case you upload the addon to the Steam Workshop, the workshop submission's metadata (name, version, author, and description) will be used instead, but the AddonContent flags will still be read from the addoninfo.txt.

Both the Source Source Engine and the deprecated external application addoninstaller.exe will parse this file, though with significant differences.
Source Source will parse this file from all addons listed in addonlist.txt when loading search paths from gameinfo.txt at startup and with subsequent calls to ConCommand update_addon_paths.
Addoninstaller.exe only parses addoninfo.txt when staging addons during user-initialized installation.

Warning.pngWarning:Avoid using addoninstaller.exe to install addons. As of at least client version 2.2.2.6 of Left 4 Dead 2 Left 4 Dead 2, the addoninstaller no longer functions as intended and actually breaks the addons that it is supposed to install.
Warning.pngWarning:You should always ship your addons with addoninfo.txt, even if you distribute through the Steam Workshop. Otherwise, your users will encounter the following undesirable behavior:
  • Your addon will load before all other addons specified in addonlist.txt.
  • Your addon will never appear in the Addons menu, stopping you from enabling/disabling the addon. Although this only happens when the user takes the mod from the "Addons/Workshop" folder and installs it into "Addons".

Specification

AddonInfo.txt is a text files that determine the addon's name, version number, description and some content tags.
You can copy this template into a text file, edit the data according to what you need and save it as "Addoninfo.txt" in the Root folder of your addon. The folder containing "materials", "Models", "Sound", ect.

"AddonInfo"
{
	addonversion		"1.0"				//Max 31 	characters. Allows decimals.
	addontitle			"Addon_Name_Here"	//Max 127 	characters.
	addonauthor			"Author_Name_Here"	//Max 119 	characters.
	addonDescription	"Description_Here"	//Max 1023 	characters.
	
	// These booleans act as content descriptors, showing up as tags ingame.
	// Users can filter addons by these tags and see what's inside without reading the description.
	// Set to 1 where applicable. You can use multiple, such as "Weapons" and "skins".
	addonContent_Campaign		0	//Has multiple maps that string into a campaign.				Represented ingame as: Campaigns
	addonContent_Map			0 	//Has at least one map.											Represented ingame as: Campaigns
	addonContent_Skin			0 	//Modifies an existing model or texture.						Represented ingame as: Skins
	addonContent_weapon			0 	//Modifies a weapon in some way. (or adds melee weapons)		Represented ingame as: Weapons
	addonContent_BossInfected	0 	//Modifies the Tank or the Witch.								Represented ingame as: Infected
	addonContent_CommonInfected	0 	//Modifies CI	.												Represented ingame as: Infected
	addonContent_Survivor		0 	//Modifies Survivors.											Represented ingame as: Survivors
	addonContent_Sound			0 	//Modifies a sound. (not for when a map is shipped with sounds)	Represented ingame as: Sounds
	addonContent_Music			0 	//Modifies specifically music.									Represented ingame as: Sounds
	addonContent_Script			0 	//Modifies a script.											Represented ingame as: Scripts
	addonContent_prop			0 	//Modifies a prop												Represented ingame as: Items
}

Non-existent or deprecated keys

The following keys either used to exist at one point or were never properly implemented in the first place.
Some of these can still be seen in the “DEADLINE” and “DEADLINE 2” AddonInfo.txt files, which were supposed to be an example, but they aren't used in-game.

Key Description
addonSteamAppID The AppID of the addon’s target game. Only addoninstaller.exe uses this.
addonTagline The addon’s subtitle or tagline. May have had a similar purpose to key poster/posterTagline in mission files.
addonAuthorSteamID The addon author’s SteamID. Supposedly used to construct a URL to the author’s Steam profile page.
addonSteamGroupName The addon’s Steam group. Supposedly used to construct a URL to the addon’s Steam group page.
addonURL0 The addon’s homepage. May have had a similar purpose to key Website in mission files.
addonContent_Survival
addonContent_Versus
addonContent_Scavenge
If the addon provides custom campaigns supporting the Survival, Versus, or Scavenge game modes. This functionality is provided by mission files.
addonContent_Prefab If the addon provides custom Hammer Hammer prefabs.
addonContent_Spray If the addon provides custom logos.
addonContent_BackgroundMovie If the addon provides custom background movies.
Content_Weapon If the addon provides custom weapons (e.g., “…a new weapon, i.e. guns, explosives, booby traps, hot tar, etc.”).
Content_WeaponModel If the addon provides custom weapon model.
addonDescription_locale The addon’s description localized for locale locale, where locale is an ISO 639-1 code in ALL CAPS.

Content tag handling

An addon’s addoninfo content keys provide an abstraction over Source Source’s implementation-specific content tags.
Source Source will convert all keys into an internal representation (typically, a bitfield).
A content key may correspond to its internal tag; some keys provide redundant meaning useful only to authors and distributors.
Source Source will use these content tags to describe and filter addons in the CBaseModFrame Addons.


In Left 4 Dead Left 4 Dead and Alien Swarm Alien Swarm

Left 4 Dead Left 4 Dead maintains a one-to-one correspondance between content keys and content tags. The handler closely resembles that found in the Alien Swarm Alien Swarm SDK.

Source Source will generate the content label by concatenating the VGUI localization strings corresponding to the given content tag followed into an array of 60 wide characters.
The right-most comma will always be replaced with a NULL terminator.
The effective length of the label is 59 characters since the last character will always be a NULL terminator.


In Left 4 Dead 2 Left 4 Dead 2

Left 4 Dead 2 Left 4 Dead 2 stores the content keys for each addon as an int16_t representing the following bitfield (assume little-endian):

Left 4 Dead 2 Left 4 Dead 2 content tag bitfield
Bit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
Tag N/A N/A N/A N/A CONTENT_ITEM CONTENT_UI CONTENT_SCRIPT CONTENT_SOUND CONTENT_SURVIVOR CONTENT_INFECTED CONTENT_MUTATION CONTENT_WEAPON CONTENT_SKIN CONTENT_MISCELLANEOUS CONTENT_CAMPAIGN CONTENT_RESERVED
Key N/A N/A N/A N/A addonContent_prop N/A addonContent_Script addonContent_Sound
addonContent_Music
addonContent_Survivor addonContent_BossInfected
addonContent_CommonInfected
N/A addonContent_Weapon addonContent_Skin N/A addonContent_Campaign
addonContent_Map
N/A

The content tags CONTENT_MISCELLANEOUS, CONTENT_MUTATION, and CONTENT_UI can be set only through the Steam Workshop.

Source Source will generate the content label by concatenating the VGUI localization strings corresponding to the given content tag followed into an array of 60 wide characters. The right-most comma will always be replaced with a NULL terminator. The effective length of the label is 59 characters since the last character will always be a NULL terminator.

Examples

The following are outdated examples of old "Example campaigns". They hold now deprecated strings, but they're still useful as a basic example of what an addoninfo would look like. Avoid using the “DEADLINE” or “DEADLINE 2” samples as templates. Use the one above.

“DEADLINE”

Download Valve’s “DEADLINE” campaign from here. The following snippet matches the original exactly as of April 30, 2023.

// The addoninfo.txt file is a metadata file that is required by all Left 4 Dead Add-ons. 
"AddonInfo"
{
	addontitle		"Dead Line"                                     // Add-on title that shows up in Add-ons list. ~20 chars max
	addonversion	        1.3                                             // Add-on version.
	addontagline		"Catch the last subway... out of hell."	        // Add-on tagline or wrap-up- a short description. ~100 chars max
	addonauthor 		"Valve"                                         // Name/alias of the author
	addonauthorSteamID 	"http://steamcommunity.com/groups/Valve"        // Steam Profile URL of author or group
	
	addonContent_Campaign		1 	                                //This addon provides muliple connected maps with a finale
	
	addonURL0 "http://media.steampowered.com/apps/513/deadline.html"	//An html home page for the add-on that includes a download link.
	
	// short description that appears in the Add-on list screen...
	addonDescription "Survivors must escape on a subway train in this short tutorial example campaign. Get source files and tools for creating your own campaigns by downloading the Left 4 Dead Authoring tools SDK, which is available under the 'Tools' tab in Steam."
	
	// Authors can add localized descriptions here. (Not yet supported)
	addonDescription_FR "Les survivants doivent s'échapper en métro dans cette carte du tutoriel. Obtenez les fichiers et les outils pour créer vos propres cartes en chargeant les outils de création SDK Left 4 Dead qui sont disponibles sous l'onglet "Outils" sur Steam."	
}

“DEADLINE 2”

Download Valve’s “DEADLINE 2” campaign from here. The following snippet matches the original exactly as of April 30, 2023.

// The addoninfo.txt file is a metadata file that is required by all Source Engine Add-ons.
"AddonInfo"
{
	addonSteamAppID         550                                                     // 500 is the app ID for Left 4 Dead, 550 for Left 4 Dead 2
	addontitle              "Dead Line 2"                                           // Add-on title that shows up in Add-ons list. ~20 chars max
	addonversion	     1.0                                                     // Add-on version.
	addontagline            "Catch the last subway... out of hell... Again!"	     // Add-on tagline or wrap-up- a short description. ~100 chars max
	addonauthor             "Valve"                                                 // Name/alias of the author
	addonSteamGroupName     "deadline2add-on"                                       // (Optional) Steam group related to the add-on. We use this to construct a URL to the group page.
	addonauthorSteamID      "YasserMalaika"                                         // (Optional) Steam ID of author. We use this to construct a URL to the author's page.
	addonContent_Campaign   1 	                                                     //This addon provides muliple connected maps with a finale
	addonURL0               "http://media.steampowered.com/apps/513/deadline2.html" //An html home page for the add-on that includes a download link.
	
	// short description that appears in the Add-on list screen...
	addonDescription        "Survivors must escape on a subway train in this short tutorial example campaign. Get source files and tools for creating your own campaigns by downloading the Left 4 Dead 2 Authoring tools SDK, which is available under the 'Tools' tab in Steam."
	
	// Authors can add localized descriptions here. (Not yet supported)
	addonDescription_FR     "Les survivants doivent s'échapper en métro dans cette carte du tutoriel. Obtenez les fichiers et les outils pour créer vos propres cartes en chargeant les outils de création SDK Left 4 Dead 2 qui sont disponibles sous l'onglet "Outils" sur Steam."	
}

See also