KIND Scenery

From TrainzOnline
(Difference between revisions)
Jump to: navigation, search
m (Compulsory and default.)
m (Roll description)
 
Line 105: Line 105:
 
====rotate-yz-range====
 
====rotate-yz-range====
 
:Type: Decimal Pair
 
:Type: Decimal Pair
:Desc: Allows 'rolling' of the asset along its Y axis where the first and second values reflect the number of degrees from normal orientation.  For example, if the first value is -20 and the second is 20 then the asset can be rolled anywhere within 40 degrees of arc.  By default, objects have a roll range of 0 to 0 (i.e. no roll).  Rolling is performed in Surveyor by holding 'shift' while using the object rotate tool.
+
:Desc: Allows 'rolling' of the asset along its Y axis where the first and second values reflect the number of degrees from normal orientation.  For example, if the first value is -20 and the second is 20 then the asset can be rolled anywhere within 40 degrees of arc.  By default, objects have a roll range of 0 to 0 (i.e. no roll).  Rolling is performed in Surveyor by holding 'shift' while using the object rotate tool. The roll range values must be specified from smaller to larger, such as -20,20 or 0,10.
  
 
====rollstep====
 
====rollstep====
 
:Type: Decimal
 
:Type: Decimal
:Desc: Specifies the step size of roll in degrees and is used in conjunction with rotate-yz-range. For example, if rotate-yz-range is (-10, 10), and rollstep is 5, then the allowable roll is -10, 5, 0, 5, and 10. The default rollstep is 1.0
+
:Desc: Specifies the step size of roll in degrees and is used in conjunction with rotate-yz-range. For example, if rotate-yz-range is (-10, 10), and rollstep is 5, then the allowable roll is -10, 5, 0, 5, and 10. The default rollstep is approximately 0.5.
  
 
====rotstep====
 
====rotstep====

Latest revision as of 09:28, 9 June 2019

KIND Scenery provides the basis for all surveyor-placeable assets.

A basic scenery asset that supports night lighting, smoke (particle) effects, sound and animation. It is height adjustable and forms the majority of map objects used.

Contents

[edit] KIND Hierarchy

[edit] Parent Classes

[edit] Child Classes

[edit] Supported Tags

Each scenery asset supports the following tags. Each tag is shown here with its default value.

 backdrop              0
 collate-meshes        0
 random-color-low-hsb  0,0,100
 random-color-high-hsb 0,0,100
 nightmode             "none"
 rgb                   0,0.5,0
 snapmode              0
 snapgrid              0
 dighole               0,0
 interior              ""
 soundscript
 {
 }
 smoke
 {
 }
 floating              0
 height-range          0,0
 autoname              0
 rotate                1
 rotate-yz-range       0,0
 surveyor-only         0
 icon-texture          ""
 queues
 {
 }
 rotstep               1
 rollstep              1
 decal
 {
 }

[edit] autoname

Type: Boolean
Desc: Will cause the object to be automatically named when placed in Surveyor. Objects are auto-named with their localised asset name followed by a number (eg. "Tree 10").

[edit] backdrop

Type: Boolean
Desc: If true then this signifies that the asset is a "backdrop". Backdrops are used to create the illusion of distant terrain in a route. To achieve this a backdrop has a much greater draw distance than other scenery assets so that it is visible from much farther away. Also, backdrops are not z-sorted, meaning that they will always appear 'behind' other scenery regardless of their actual position in the world. For this reason, backdrop objects should never be placed near the track.

[edit] camera-collidable

Type: Integer
Desc: This tag is not used in Trainz.

[edit] collate-meshes

Type: Boolean
Desc: The 'collate-meshes' tag allowed for rapid rendering (a primitive form of stitching) in older versions of Trainz. There were significant limitations on how they could be used. The tag allowed the ability to add random color variation to scenery objects via the 'random-color-low-hsb' and 'random-color-high-hsb' tags. Collated mesh coloring is not currently supported in TS2009 but is expected to be revived in future Trainz versions.

[edit] decal

Type: Decal Container
Desc: Specifies a decal to attach to the scenery object. Decals are effectively textures attached to the asset that are drawn on the ground rather than the asset itself. Decals are ideal for the creation of object shadows, or adding ground detail such as cracks, oil stains, etc. Decals should be used sparingly, as there is a runtime cost to creating and updating decals.

[edit] dighole

Type: Integer Pair
Desc: This tag allows objects to be sunk into the terrain by specifying a hole size to dig at the objects location. The ground underneath the object will not be drawn where there is a hole. This value is specified as an integer pair in 10 meter grid squares (ie. 5,2 = 50 x 20m) regardless of the actual terrain grid size, where the first value is the size in the N-S direction and the second value is the size in the E-W direction. Note that the size of a hole cannot exceed 64 (where "dighole = a,b", a * b <= 64). Also note that the hole position will be snapped to the terrain grid so the asset should generally have the 'snapgrid' tag specified. Typical usage for the 'dighole' tag is to allow for turntable pits.

[edit] floating

Type: Decimal
Desc: If specified the 'floating' tag specifies a vertical offset, in meters, for the assets position. This allows you to create an asset which 'floats' a certain distance of the ground.

[edit] height-range

Type: Decimal Pair
Compulsory: No
Default: No height range restriction is applied.
Desc: Allows you to specify a range, in meters, for Surveyor's height adjustment tool. A value of 0,0 means the height range is fixed at ground level.

[edit] icon-texture

Type: Image File
Desc: Specifies an icon texture for the asset. Icons are used as thumbnails in various asset lists in Surveyor and can alternatively be specified using a thumbnail container.

[edit] interior

Type: KUID
Desc: Specifies an interior asset. Optional.

[edit] nightmode

Type: Selection
Desc: Specifies how/when to use a night mesh specified in the mesh table. Requires one or more night meshes to be added to the mesh-table, which are identified by the 'night-mesh-base' tag. 'nightmode' must be one of the following values:
  • home - switches on night effect at dusk and off sometime during the night
  • lamp - switches the night effect on from dusk to dawn
  • constant - lights are on day and night
  • none - no lights (default)

[edit] queues

Type: Queues Container
Desc: A queue container is used by certain asset types (such as stations, industries and rolling stock) to 'hold' product. Passengers are 'product' for queue purposes. Queue containers can make use of animated meshes or custom attachments to visually represent the amount of product they hold in game.

[edit] random-color-high-hsb

Type: Color (HSB)
Desc: This value requires 'collate-meshes' to be turned on and specifies the high point of the random color variation of an asset. Random color variations are specified as hue-saturation-brightness colors to allow meaningful interpolation between values.

[edit] random-color-low-hsb

Type: Color (HSB)
Desc: This value requires 'collate-meshes' to be turned on and specifies the low point of the random color variation of an asset. Random color variations are specified as hue-saturation-brightness colors to allow meaningful interpolation between values.

[edit] rgb

Type: Color (RGB, 0 to 1)
Desc: Specifies the color that this object will appear on the Minimap. Defaults to (0, 0.5, 0).

[edit] rotate

Type: Boolean
Desc: Used to allow rotation to be disabled for an asset. If added and set to false the object rotation tool in Surveyor will not work for this asset. Rotation is enabled if this tag is not supplied.

[edit] rotate-yz-range

Type: Decimal Pair
Desc: Allows 'rolling' of the asset along its Y axis where the first and second values reflect the number of degrees from normal orientation. For example, if the first value is -20 and the second is 20 then the asset can be rolled anywhere within 40 degrees of arc. By default, objects have a roll range of 0 to 0 (i.e. no roll). Rolling is performed in Surveyor by holding 'shift' while using the object rotate tool. The roll range values must be specified from smaller to larger, such as -20,20 or 0,10.

[edit] rollstep

Type: Decimal
Desc: Specifies the step size of roll in degrees and is used in conjunction with rotate-yz-range. For example, if rotate-yz-range is (-10, 10), and rollstep is 5, then the allowable roll is -10, 5, 0, 5, and 10. The default rollstep is approximately 0.5.

[edit] rotstep

Type: Decimal
Desc: Specifies the amount of each rotation step (in degrees) when rotating an asset in Surveyor

[edit] smoke

Type: Smoke Container
Desc: A smoke container is effectively a PFX (particle effects) emitter that allows your scenery object to produce smoke and similar effects. Smoke tags take the form smokeX where X is a number. There is no maximum number of smoke tags but they must be numbered sequentially (i.e. smoke0,smoke1,smoke2,etc).

[edit] snapgrid

Type: Integer
Desc: This tag specifies the size, in meters, of the snap grid for the 'snapmode' tag, default 10 meters.

[edit] snapmode

Type: Boolean
Desc: If true then this objects position will be constrained to a grid location on the ground. When placed or moved in Surveyor the object will 'snap' to the nearest grid location, the size of the grid is set using the snapgrid tag.

[edit] soundscript

Type: SoundScript Container
Desc: Details sounds that a scenery object produces. Sound should be used sparingly - objects that appear in large numbers throughout a scene should not contain a soundscript, to prevent an unnecessary performance hit.

[edit] surveyor-only

Type: Boolean
Desc: Enables the creation of Surveyor only objects. Surveyor only objects will not exist in Driver.


[edit] Example Config.txt

Sample config.txt file for a scenery asset, with the Standard Tags excluded for brevity:

kind scenery
nightmode home
mesh-table
{
  default
  {
    mesh scenery_asset.im
    anim anim.kin
    auto-create 1
    animation-loop-speed 1
    effects
    {
      0
      {
        kind name
        fontsize 0.15
        fontcolor 30,30,30
        att a.name0
        name name
      }
      1
      {
        kind corona
        att a.coronawhite
        frequency 1
        directional 0
        texture-kuid <KUID:-3:10111>
      }
    }
  }
  default-night
  {
    mesh night.im
    night-mesh-base default
  }
  radar
  {
  mesh radar/radar.im
  anim radar/radar.kin
  att a.radar
  att-parent default
  animation-loop-speed 1.0
  }
}

[edit] Downloads

Attach sample files here?

[edit] Categories

Personal tools