Label scenery objects

  • Certain scenery objects contain text fields so that the map builder can label them individually. Typical objects are street signs and bus stops.

    1 In the MapEditor / Set object on the map

    After the object has been placed in the MapEditor and only if the object developer has provided for it, all you have to do is click on the object with the right mouse button and on "Set Start Variables" with the left mouse button.

    Then a dialog box appears, which shows all variables, which the object developer has released for editing in the MapEditor.

    There you will find the text field which controls the label, you can fill it in directly, click on "OK" and see the result immediately. For more complex objects, it may well be the case that there are several independent text fields, which is why there are several lines in the dialog box.

    It is also possible that the object developer has built in other ways to configure the object. In this case, you may also find other variable types, such as "hooks" that can be switched on or off, with which you can, for example, make individual parts of the object visible or invisible.

    2 In the Object & Vehicle Tool / Configure your own object

    In order for a scenery object to be labeled and/or preconfigured in the map editor, i.e. so that the map editor can determine which variables are to receive which value during initialization, the relevant variable names must begin with a "$", e.g. "$Streetname".

    The configuration of the text texture itself is then simply done as described here:

    Writing and drawing on textures

    Here the variable "$Streetname" is used. That's it! :-)

    But you can also use all other variable types and the whole script system can of course read these variables, so that you can realize any complex configuration possibilities! A relatively simple example would be module stops, where the map creator can define the number of timetables mounted on the mast by an integer variable and then the script sets visibility variables and/or animation variables in the initialize procedure (see script system ), with which the individual timetable modules can be switched visible or invisible and moved to the correct position. (I haven't tested that this works in the Initialize procedure yet!)