The “script-include-table” container is the top-level config.txt entry available for any asset that derives from KIND TrainzBaseSpec. This container allows an asset to directly include another asset’s scripts from the asset’s script file(s) parent. An extension container is a list of custom tags or sub-containers with a specific naming convention.
script-include-table
{
0 <kuid:123456:000000>
}
script "exclient.gs"
class "exclient"
Script: exclient.gs
include "signalext.gs"
class exclient isclass SignalExt {};
The attached exclient.gs script file refers to where to look for the scripts attached to config.txt using the KUID number.
Include: is a script found in the library.
Class “exclient” isclass SignalExt is a script that reads the appropriate control commands for a certain asset. More in Scripts
Library configuration file:
kind "library"
trainz-build 3.6
username "Core Library"
author "Autor name"
organization "Organization name"
contact-email "email name"
contact-website "www name"
license "All right reserved by ©name 2023"
category-region "CH"
category-era "1990s"
always-load-in-global-context 0
category-class "YR"
script "emptylib.gs"
class "emptylib"
thumbnails
{
1
{
width 240
height 180
image "thumbnail_0.jpg"
}
}
kuid <kuid:123456:000000>
kuid-table
{
}
Library script: emptylib.gs
include "Library.gs"
class emptylib isclass Library {};