Difference between revisions of "Games/ETS2/Modding guides/1.23"

From SCS Modding Wiki
Jump to navigation Jump to search
 
(4 intermediate revisions by 2 users not shown)
Line 12: Line 12:
 
= Changes =
 
= Changes =
 
== Definitions ==
 
== Definitions ==
Attribute "engine_brake_positions" added to engine_data. It works in conjunction with new inputs for engine brake increase/decrease in same way as retarder.  
+
Attribute "engine_brake_positions" added to "accessory_engine_data". It works in conjunction with new inputs for engine brake increase/decrease in same way as retarder.  
  
Attribute "name" in "direct_gearbox_config" is shown in game (options/control/layout selection) if defined. Furthermore, attribute "name" was also added to "direct_gearbox_gear" so each gear definition can have one. These names are displayed in game and override anything defined by transmission_data or default generated by game.
+
Attribute "name" in "direct_gearbox_config" is shown in game (options/control/layout selection) if defined. Furthermore, attribute "name" was also added to "direct_gearbox_gear" so each gear definition can have one. These names are displayed in game and override anything defined by "accessory_transmission_data" or default generated by game.
 +
 
 +
Attributes "trailer_brake_stick_anim" and "trailer_air_stick_anim" added to "accessory_interior_data" unit. They handle animations of trailer brake and air supply knob respectively.
 +
 
 +
To silence warnings in UI units/defs, remove following obsolete attributes from your modded UI scripts: child_nameless, p2p_pml, name, tooltip.
  
 
== Sounds ==
 
== Sounds ==
Line 28: Line 32:
  
 
== Editor changes ==
 
== Editor changes ==
 +
* Terrains are separated from Roads, now they are standalone items with custom properties dialog. Previous road-based terrains will be automatically converted when the map is loaded.
 
* Added editor ruler tool for measuring distances. In the statusbar it shows length of the path. Controls:  
 
* Added editor ruler tool for measuring distances. In the statusbar it shows length of the path. Controls:  
 
** Left click to add a point into the path,  
 
** Left click to add a point into the path,  
Line 34: Line 39:
 
* Sign project now contains "quick texts" that are merged with list of nearby cities in sign editor. The texts can be added when editing sign project. This way you can add frequently repeated words in sign templates without retyping them manually each time.
 
* Sign project now contains "quick texts" that are merged with list of nearby cities in sign editor. The texts can be added when editing sign project. This way you can add frequently repeated words in sign templates without retyping them manually each time.
 
* Added new snapping mode: "Snap to ground". When turned on the items that are being free-moved (no axis lock) with '''M''' tool are automatically dropped to ground (the same way they are dropped with '''F6'''). It also works for other tools which means these following tools can now be used in free camera (with the snap on): '''New''', '''Place Start''', '''Ruler''' and '''Brush'''.
 
* Added new snapping mode: "Snap to ground". When turned on the items that are being free-moved (no axis lock) with '''M''' tool are automatically dropped to ground (the same way they are dropped with '''F6'''). It also works for other tools which means these following tools can now be used in free camera (with the snap on): '''New''', '''Place Start''', '''Ruler''' and '''Brush'''.
* Sun profiles names and sorting in list on environment screen improved. Right now its sorted by day time and the interval is directly displayed there. Position that it depends on is displayed on side as well (closest city + latitude).
+
* Sun profiles names and sorting in list on environment screen improved. Right now its sorted by day time and the interval is directly displayed there. Position that it depends on is displayed on side as well (closest city + current latitude).

Latest revision as of 13:45, 17 March 2016

Recommendations

  • Some new models utilizing the "fr" suffix or prefix are still work in progress and it is likely that they might change significantly in some next patch. For this reason it is recommended that you avoid using them in your mods at this time.
  • When basing you model on the original ones, add to your mod also ALL original /automat/ files used by it. The names of the files are generated as SHA1 hash of theirs content so whenever we change the parameters of the material in any way, a different file will be used to store them and the original file might cease to exist if there is no other model utilizing the original parameters.
  • When modifying original models, always include ALL compoments of the model (pmg+pmd) instead of just those you changed. Otherwise you risk crash if we change the model.
  • As always when adding new objects to files which support multi-file approach (e.g. road_look.sii) it is HIGHLY RECOMMENDED to use suffix or prefix in the name to avoid conflicts with new objects we are adding in patches. Otherwise you might have to use the batch renaming functionality (see Batch renaming) to fix the conflicts when new patch appears.

How to convert map

  • Load map
  • Do rebuild (F8)
  • Save map

Changes

Definitions

Attribute "engine_brake_positions" added to "accessory_engine_data". It works in conjunction with new inputs for engine brake increase/decrease in same way as retarder.

Attribute "name" in "direct_gearbox_config" is shown in game (options/control/layout selection) if defined. Furthermore, attribute "name" was also added to "direct_gearbox_gear" so each gear definition can have one. These names are displayed in game and override anything defined by "accessory_transmission_data" or default generated by game.

Attributes "trailer_brake_stick_anim" and "trailer_air_stick_anim" added to "accessory_interior_data" unit. They handle animations of trailer brake and air supply knob respectively.

To silence warnings in UI units/defs, remove following obsolete attributes from your modded UI scripts: child_nameless, p2p_pml, name, tooltip.

Sounds

New sound for connect/disconnect trailer: "/sound/truck/clunk.ogg" and "/sound/truck/clunk_off.ogg".

Models

Wheels customization

Rims were split to 4 accessories - disc, hub, nuts and optional hub cover.

Until the truck is taken to upgrade shop, old rims/wheels will work. In upgrade shop, known rims will be switched for new equivalent, unknown ones will be switched to defaults (see "/def/vehicle/rim_data.sii").

All wheel accessories (wheel, tire, rim parts) must be named in a bit more strict format - LAST token of unit name always define type and position of accessory e.g. "rdisc" = disc of rear wheel. This must be true for modded AI wheels as well! Attributes that were used before: front_wheel, front_rim, etc. are now obsolete. Used token names are: "ftire", "fdisc", "fhub", "fnuts" and "fcover" for player trucks and "fwheel" for AI vehicles (similarly rear wheels).

Editor changes

  • Terrains are separated from Roads, now they are standalone items with custom properties dialog. Previous road-based terrains will be automatically converted when the map is loaded.
  • Added editor ruler tool for measuring distances. In the statusbar it shows length of the path. Controls:
    • Left click to add a point into the path,
    • Middle click to remove the last point,
    • Escape to delete current path.
  • Sign project now contains "quick texts" that are merged with list of nearby cities in sign editor. The texts can be added when editing sign project. This way you can add frequently repeated words in sign templates without retyping them manually each time.
  • Added new snapping mode: "Snap to ground". When turned on the items that are being free-moved (no axis lock) with M tool are automatically dropped to ground (the same way they are dropped with F6). It also works for other tools which means these following tools can now be used in free camera (with the snap on): New, Place Start, Ruler and Brush.
  • Sun profiles names and sorting in list on environment screen improved. Right now its sorted by day time and the interval is directly displayed there. Position that it depends on is displayed on side as well (closest city + current latitude).