411 REFERENCE · Wikibooks
Trainz/Content Configuration
Reference material by Wikibooks contributors. This retains its source identity and is not 411 news reporting.
Trainz CC
For a new-user walk-through explaining how to create various types of content, see the HowToGuides HowToGuides page instead.
Overview of Trainz Content
This page acts as reference manual for all Trainz content, and it's legal data types (K KINDs) and data structures (generally, C Containers). It is intended to provide accurate and concise description of the capabilities and configuration of Trainz current-version content. To the new user, particularly those with no familiarity with programming language practices, the information in this page can become a starting point to understanding. Every Trainz asset from the mighty collection of assets contained in a route to the lowliest scenery item such as imitation grass, the color of a rock or field—all have two things in common: The list of common legal tag names which begin the definition of the asset found in the K TrainzBaseSpec, and the container which lists and defines them, the INI file initialization file type known as config.txt.
All configuration files are not created equal for they also hold data fields which define which type of asset they are intended to weld together from disparate parts, and depending upon the need (a flower, for all it's beauty and lovely fragrance has no where near the animative complexity of a diesel locomotive and a steam loco is more complicated still). The solution for Trainz software writers was a common self-descriptive and self-defining data structure that was because of the self-definition property, a common starting point for parsing a content creators meaning and translating it into the binary representation needed by the Auran JET graphics engine.
Auran and later N3V Games installed content differs in kind from downloaded or other types of add on content. The installed assets are located in the software's CAB files, binary compressed data cabinet files which in Trainz have the .ja extension. Whereas the imported cdp file cdp files and other third party or self-developed content reside in directories in the .../local folder (directories) and sub-folders, as do the asset config.txt files any user needs to contend with directly.
Structure of a Trainz Asset
Each item of Trainz content ("an asset") is created as the contents of a single operating system folder, containing a config.txt file and some number of supporting files and/or folders and their files. Files located in the content folder must obey the Filename character restrictions (similar to, but not as restrictive as Microsoft Windows file name restrictions) and each item should be directly relevant to the asset in question. When committed or as in newer Trainz releases, tested for validation before commitment, the asset's folder contents and the config.txt file will be validated against one another, the ideal minimum definitions will be bounced against those and each must be in balance and correct with respect to one another. Older Pre-TS2009 versions were comparatively lacking in this error-checking-in-advance process, and the legacy errors one sometimes still sees when downloading older content from the DLS is directly attributable to this earlier leniency. Sometimes Trainz would crash in run time modes because of such errors, so today, today's Trainz are more restrictive to avoid those run-time un-ohs!
Content Types
Each asset built for the Trainz environment follows a preset template, which defines what tags can be included in the config.txt file, what capabilities the asset will have, and how the user can manipulate the asset in-game. The following types of custom content are supported by Trainz:
KD KIND Achievement-category KIND Achievement-category - Achievement category descriptor.
KD KIND Achievement-group KIND Achievement-group - Achievement group descriptor.
KD KIND Asset-group KIND Asset-group - Asset group descriptor.
KD KIND Behavior KIND Behavior - Session rules.
KD KIND Bogey KIND Bogey
KD KIND Buildable KIND Buildable - Basic scenery object with attached track.
KD KIND Controlset KIND Controlset - Defines a set of input controls
KD KIND Drivercharacter KIND Drivercharacter
KD KIND Drivercommand KIND Drivercommand
KD KIND Engine KIND Engine
KD KIND Enginesound KIND Enginesound
KD KIND Environment KIND Environment - Defines a set of skies.
KD KIND Fixedtrack KIND Fixedtrack
KD KIND Gameplaymenu KIND Gameplaymenu - Main menu page.
KD KIND Groundtexture KIND Groundtexture - Textures for painting the ground.
KD KIND Hornsound KIND Hornsound
KD KIND HTML-asset KIND HTML-asset
KD KIND Industry KIND Industry - Scenery object with attached track and product processing functionality.
KD KIND Interior KIND Interior
KD KIND Library KIND Library - Script Libraries.
KD KIND Map KIND Map - Routes.
KD KIND Mesh KIND Mesh KD KIND MOCrossing KIND MOCrossing - Grade crossings.
KD KIND MOJunction KIND MOJunction - Junction levers.
KD KIND MOSignal KIND MOSignal - Railroad signals.
KD KIND MOSpeedboard KIND MOSpeedboard
KD KIND Pantograph KIND Pantograph
KD KIND Product KIND Product
KD KIND Product-category KIND Product-category
KD KIND Profile KIND Profile - Sessions.by an older title
KD KIND Region KIND Region - Defines the area of the world, as well as traffic style.
KD KIND Scenery KIND Scenery - A basic object.
KD KIND Scenery-trackside KIND Scenery-trackside - Object that attaches to track.
KD KIND Servlet KIND Servlet - An iTrainz servlet daemon.
KD KIND Steam-engine KIND Steam-engine
KD KIND Texture KIND Texture - A texture defined for use in other objects.
KD KIND Texture-group KIND Texture-group - A group of textures defined for use with other objects.
KD KIND Track KIND Track - (including Bridges and Tunnels) and scenery splines are built using TS2009 Stitched track.
KD KIND Tracksound KIND Tracksound
KD KIND Traincar KIND Traincar - Locomotives and Rolling Stock.
KD KIND Turntable KIND Turntable
KD KIND Water2 KIND Water2 - Water for rivers / seas.
Category Tags
Category tags (Category Class codes) were added to Trainz content and the TrainzBaseSpec per user suggestion around the time of Trainz 1.0 and are an aid to sorting and selecting appropriate content that would be found in a time or place, or of narrowing down a particular sort of asset initially in Surveyor, but seen now mainly in filters when running Content Manager Content Manager.
t Category-class - For Category search. This parameter was defined in the early Trainz UTC Content Creator's Guide as being for 'How the CC thought of the asset' regardless of the KIND used to create it.
t Category-region - For Region search; meaning geographic locales by country codes such as 'UK', 'AU', or 'CA' mapped respectively to the United Kingdom, Australia, and Canada. The linked page gives a very long list of two letter country codes.
t Category-era - For Era Search, meaning a span of years in decades. For example: A Train station building (depot) coded for the 1850s-1880s and designed for the American West hardly has scope in post-1900 anywhere after 1910, while a Victorian Brick Station built in the American Northeast in an important nodal yard for a railroad, might well still be in service in the 2010s—such is the case for fact of the station once built by the owners of the Lehigh and Susquehanna in Mauch Chunk, Pennsylvania; a town now renamed Jim Thorpe, PA.
Interpretation of category-era coding varies amongst content creator's—some use it to represent dates of manufacturing (perhaps only a half-dozen years, so list a single decade), but others may use it to date the service life of the asset (Various locomotives and rolling stock assets were in-service for decades after manufacturing ceased.
Feedback
Content_Configuration_Feature_Requests Content Configuration Feature Requests - ask here for new config.txt files features
Categories
Categories are the sometimes overlooked superhighways of getting around in a Wiki project, and the user will find these listed are index pages to finding things faintly remembered efficiently and effectively:
:Category:Asset KIND
:Category:Trainz Config Container
:Category:Trainz Config Tag
:Category:Trainz content configuration
CC
See also
The following category pages will list and index Trainz specific articles throughout this Wiki
:Category:Trainz fundamentals pages
:Category:Trainz reference pages
Notes, Footnotes & References
Config.txt files are endemic and ever present in Trainz assets, for no asset can be defined without this type of Computer Science container. The keyword-value_of_key pairing must always be kept in mind in editing or creating Trainz content. The TrainzBaseSpec contains values and containers which are most common in asset defining config.txt files.
Notes
Footnotes
References
Trainz printed or pdf file Manuals, applicable version - usually in the ..\extras or ..\extras\manuals folder
Config.txt_file TrainzOnline Wiki Config.txt file page and various other pages
CCG TrainzOnline Wiki: Content Creator's Guide pages (various)
Various CCG and Auran websites
CC http://online.ts2009.com/mediaWiki/index.php?title=Content_Configuration&oldid=5445