KIND Controlset: Difference between revisions

From TrainzOnline
Jump to navigationJump to search
New page: KIND Controlset Defines a set of input controls. ==Supported Tags== Each controlset asset supports the following tags. Each tag is shown here with its default value. ''TBD'' ==Exam...
 
No edit summary
 
(11 intermediate revisions by 5 users not shown)
Line 1: Line 1:
[[KIND Controlset]]
[[KIND Controlset]] defines a set of user-input controls. The controls defined represent basic commands, e.g. "Activate headlights", and are thus independent from the actual method used to activate them (e.g. a keyboard key, gamepad button, etc).


Defines a set of input controls.
==KIND Hierarchy==
===Parent Classes===
* [[KIND TrainzBaseSpec]]
===Child Classes===
* ''none.''


==Supported Tags==
==Supported Tags==
Each controlset asset supports the following tags. Each tag is shown here with its default value.
Each controlset asset supports the following tags. The trainz-build tag should be greater than or equal to 3.6.


''TBD''
  controls
  {
  }
 
====controls====
:Type: [[Controls_container|Controls container]]
:Desc: Specifies the various control commands. The specification for the controls themselves are documented separately [[Controls_container|here]].


==Example Config.txt==
==Example Config.txt==
Sample [[config.txt file]] for a controlset asset, with the standard tags excluded for brevity:
Sample [[config.txt file]] for a controlset asset, with the standard tags excluded for brevity:


''TBD''
  kuid                                    <kuid:401543:1100>
  kind                                    "controlset"
  username                                "Menu Controls"
  trainz-build                            3.6
  category-class                          "CS"
  description                            "Keyboard shortcuts used within the Trainz menus"
 
  thumbnails
  {
    1
    {
      image                              "thumbnail.jpg"
      width                              240
      height                              180
    }
  }
 
  controls
  {
    routes-menu
    {
      name-token                          "routes-name"
      desc-token                          "routes-desc"
      event                              "routes-menu"
      default-keys                        "r"
      context                            "Menu"
    }
 
    new-route
    {
      name-token                          "new-route-name"
      desc-token                          "new-route-desc"
      event                              "new-route"
      default-keys                        "n,c"
      context                            "Menu"
    }
  }
 
  string-table
  {
    routes-name                          "Routes Menu"
    routes-desc                          "Opens the routes menu"
    new-route-name                        "New Route"
    new-route-desc                        "Creates a new route in Surveyor"
  }


==Categories==
==Categories==
[[Category:Asset KIND]]
[[Category:Asset KIND|C]]

Latest revision as of 04:04, 22 November 2017

KIND Controlset defines a set of user-input controls. The controls defined represent basic commands, e.g. "Activate headlights", and are thus independent from the actual method used to activate them (e.g. a keyboard key, gamepad button, etc).

KIND Hierarchy

Parent Classes

Child Classes

  • none.

Supported Tags

Each controlset asset supports the following tags. The trainz-build tag should be greater than or equal to 3.6.

 controls
 {
 }

controls

Type: Controls container
Desc: Specifies the various control commands. The specification for the controls themselves are documented separately here.

Example Config.txt

Sample config.txt file for a controlset asset, with the standard tags excluded for brevity:

 kuid                                    <kuid:401543:1100>
 kind                                    "controlset"
 username                                "Menu Controls"
 trainz-build                            3.6
 category-class                          "CS"
 description                             "Keyboard shortcuts used within the Trainz menus"
 
 thumbnails
 {
   1
   {
     image                               "thumbnail.jpg"
     width                               240
     height                              180
   }
 }
 
 controls
 {
   routes-menu
   {
     name-token                          "routes-name"
     desc-token                          "routes-desc"
     event                               "routes-menu"
     default-keys                        "r"
     context                             "Menu"
   }
 
   new-route
   {
     name-token                          "new-route-name"
     desc-token                          "new-route-desc"
     event                               "new-route"
     default-keys                        "n,c"
     context                             "Menu"
   }
 }
 
 string-table
 {
   routes-name                           "Routes Menu"
   routes-desc                           "Opens the routes menu"
   new-route-name                        "New Route"
   new-route-desc                        "Creates a new route in Surveyor"
 }

Categories