Difference between revisions of "Games/ETS2/Modding guides/1.19"
(Created page with "= Patch: 1.19 = == Recommendations == <ul> <li> Some new models utilizing the "fr" suffix or prefix are still work in progress and it is likely that they might change signifi...") |
|||
Line 1: | Line 1: | ||
− | + | = Recommendations = | |
− | |||
− | |||
<ul> | <ul> | ||
<li> 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. | <li> 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. | ||
Line 10: | Line 8: | ||
</ul> | </ul> | ||
− | + | = How to convert map = | |
<ul> | <ul> | ||
<li> If your mod overrides <strong>signs.sii</strong> or <strong>sign.dlc_north.sii</strong>, you need to update those files to account for us moving some signs from DLC Scandinavia to base. | <li> If your mod overrides <strong>signs.sii</strong> or <strong>sign.dlc_north.sii</strong>, you need to update those files to account for us moving some signs from DLC Scandinavia to base. | ||
Line 19: | Line 17: | ||
</ul> | </ul> | ||
− | + | = Changes = | |
− | + | == Traffic-related changes == | |
− | + | === AI vehicle model storage === | |
For each supported vehicle type (currently: <strong><em>car, truck, bus</em></strong>) a separate unit exists in <strong>/def/vehicle/traffic_vehicle_type.sii</strong>. These units contain paths to actual model storage for given vehicle type (e.g.<strong> /def/vehicle/traffic_storage_car.sii</strong>) | For each supported vehicle type (currently: <strong><em>car, truck, bus</em></strong>) a separate unit exists in <strong>/def/vehicle/traffic_vehicle_type.sii</strong>. These units contain paths to actual model storage for given vehicle type (e.g.<strong> /def/vehicle/traffic_storage_car.sii</strong>) | ||
− | + | === AI trailer model storage === | |
For each supported trailer type (currently: <strong><em>semi_trailer</em></strong>) a separate unit exists in <strong>/def/vehicle/traffic_trailer_type.sii</strong>. These units contain paths to actual model storage for given trailer type (e.g.<strong> /def/vehicle/traffic_storage_semi_trailer.sii</strong>) | For each supported trailer type (currently: <strong><em>semi_trailer</em></strong>) a separate unit exists in <strong>/def/vehicle/traffic_trailer_type.sii</strong>. These units contain paths to actual model storage for given trailer type (e.g.<strong> /def/vehicle/traffic_storage_semi_trailer.sii</strong>) | ||
− | + | === AI vehicle definition === | |
Property <strong>attachable</strong> is now obsolete. It has been replaced by an array attribute <strong>attachable_trailer</strong>. The array contains unit names (as strings) of all trailer models which can be attached to the given vehicle. | Property <strong>attachable</strong> is now obsolete. It has been replaced by an array attribute <strong>attachable_trailer</strong>. The array contains unit names (as strings) of all trailer models which can be attached to the given vehicle. | ||
Line 34: | Line 32: | ||
<code>attachable_trailer[]: ""</code> | <code>attachable_trailer[]: ""</code> | ||
− | + | === AI trailer definition === | |
To allow future features and improvements, the type of the unit defining an AI trailer <strong>CHANGED FROM</strong> <code>trailer</code> <strong>TO</strong> <code>traffic_trailer</code> | To allow future features and improvements, the type of the unit defining an AI trailer <strong>CHANGED FROM</strong> <code>trailer</code> <strong>TO</strong> <code>traffic_trailer</code> | ||
Line 45: | Line 43: | ||
<code>trafic_trailer : traffic.trailer.fuel_cistern</code> | <code>trafic_trailer : traffic.trailer.fuel_cistern</code> | ||
− | + | === Road look definition === | |
The <strong>lane_count_left</strong>, <strong>lane_count_right</strong> and <strong>ai_speed_type</strong> attributes are now obsolete. They were replaced by <strong>lanes_left</strong> and <strong>lanes_right</strong> arrays. (The array items are ordered from the center of the road to the borders) This allows specifying some traffic lane attributes for each lane separately - see "<em>Traffic lane definition</em>" | The <strong>lane_count_left</strong>, <strong>lane_count_right</strong> and <strong>ai_speed_type</strong> attributes are now obsolete. They were replaced by <strong>lanes_left</strong> and <strong>lanes_right</strong> arrays. (The array items are ordered from the center of the road to the borders) This allows specifying some traffic lane attributes for each lane separately - see "<em>Traffic lane definition</em>" | ||
− | + | === Traffic lane definition === | |
Traffic lane definitions can be found in <strong>/def/world/traffic_lane.sii</strong>. | Traffic lane definitions can be found in <strong>/def/world/traffic_lane.sii</strong>. | ||
− | + | === License plate definition === | |
The definitions of per-country license plates were moved into separate <strong>/def/country/<country_name>/license_plates.sii</strong> file. It contains separate unit for each vehicle type (car, truck, bus). If more than one unit exists for some type, the game will use the first unit it encounters. | The definitions of per-country license plates were moved into separate <strong>/def/country/<country_name>/license_plates.sii</strong> file. It contains separate unit for each vehicle type (car, truck, bus). If more than one unit exists for some type, the game will use the first unit it encounters. | ||
− | + | === Country speed limit definition === | |
The definitions of per-country speed limits were moved into separate <strong>/def/country/<country_name>/speed_limits.sii</strong> file. It contains separate unit for each vehicle type (car, truck, bus). If more than one unit exists for some type, the game will use the first unit it encounters. | The definitions of per-country speed limits were moved into separate <strong>/def/country/<country_name>/speed_limits.sii</strong> file. It contains separate unit for each vehicle type (car, truck, bus). If more than one unit exists for some type, the game will use the first unit it encounters. | ||
− | + | == Vehicle changes == | |
− | + | === Separate interior model === | |
The cabin interior now uses separate model for rendering from external views. That model is defined using new <strong>ext_model</strong>, <strong>ext_variant</strong> and <strong>ext_look</strong> attributes of interior accessory. | The cabin interior now uses separate model for rendering from external views. That model is defined using new <strong>ext_model</strong>, <strong>ext_variant</strong> and <strong>ext_look</strong> attributes of interior accessory. | ||
− | + | == Editor changes == | |
<ul> | <ul> | ||
<li> <span style="background-color: transparent;">The toolbar window and editor window were combined into one.</span> | <li> <span style="background-color: transparent;">The toolbar window and editor window were combined into one.</span> | ||
Line 72: | Line 70: | ||
</li></ul> | </li></ul> | ||
− | + | === 3D move manipulator === | |
<ul> | <ul> | ||
<li> <span style="background-color: transparent;">Editor contains 3D move manipulator ("gizmo").</span> | <li> <span style="background-color: transparent;">Editor contains 3D move manipulator ("gizmo").</span> | ||
Line 81: | Line 79: | ||
</ul> | </ul> | ||
− | + | === Grid === | |
<ul> | <ul> | ||
<li> <span style="background-color: transparent;">Editor can render grid when enabled from menu View > Grid.</span> | <li> <span style="background-color: transparent;">Editor can render grid when enabled from menu View > Grid.</span> |
Revision as of 16:00, 10 February 2016
Contents
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
- If your mod overrides signs.sii or sign.dlc_north.sii, you need to update those files to account for us moving some signs from DLC Scandinavia to base.
- Convert AI model storage definitions to the new format
- Convert the road look definitions to the new format.
- Convert the speed limit and license plate definitions in country data to the new format.
Changes
AI vehicle model storage
For each supported vehicle type (currently: car, truck, bus) a separate unit exists in /def/vehicle/traffic_vehicle_type.sii. These units contain paths to actual model storage for given vehicle type (e.g. /def/vehicle/traffic_storage_car.sii)
AI trailer model storage
For each supported trailer type (currently: semi_trailer) a separate unit exists in /def/vehicle/traffic_trailer_type.sii. These units contain paths to actual model storage for given trailer type (e.g. /def/vehicle/traffic_storage_semi_trailer.sii)
AI vehicle definition
Property attachable is now obsolete. It has been replaced by an array attribute attachable_trailer. The array contains unit names (as strings) of all trailer models which can be attached to the given vehicle.
To allow all trailer models, add an empty string at the beginning of the array:
attachable_trailer[]: ""
AI trailer definition
To allow future features and improvements, the type of the unit defining an AI trailer CHANGED FROM trailer
TO traffic_trailer
For example:
trailer : traffic.trailer.fuel_cistern
changes to
trafic_trailer : traffic.trailer.fuel_cistern
Road look definition
The lane_count_left, lane_count_right and ai_speed_type attributes are now obsolete. They were replaced by lanes_left and lanes_right arrays. (The array items are ordered from the center of the road to the borders) This allows specifying some traffic lane attributes for each lane separately - see "Traffic lane definition"
Traffic lane definition
Traffic lane definitions can be found in /def/world/traffic_lane.sii.
License plate definition
The definitions of per-country license plates were moved into separate /def/country/<country_name>/license_plates.sii file. It contains separate unit for each vehicle type (car, truck, bus). If more than one unit exists for some type, the game will use the first unit it encounters.
Country speed limit definition
The definitions of per-country speed limits were moved into separate /def/country/<country_name>/speed_limits.sii file. It contains separate unit for each vehicle type (car, truck, bus). If more than one unit exists for some type, the game will use the first unit it encounters.
Vehicle changes
Separate interior model
The cabin interior now uses separate model for rendering from external views. That model is defined using new ext_model, ext_variant and ext_look attributes of interior accessory.
Editor changes
- The toolbar window and editor window were combined into one.
- Editor window can be resized, docked, maximized.
- Resolution can be choosed from menu View > Resolution.
- Mouse cursor behaves significantly better.
- Free camera can be rotated with right mouse button (RMB).
- Several items can be combined into one by "Ctrl+G" or from menu Tools > Compound Selection.
3D move manipulator
- Editor contains 3D move manipulator ("gizmo").
- Move manipulator can lock movement along one axis when X, Y or Z pressed.
- Move manipulator can lock movement along one plane when Shift+X, Shift+Y or Shift+Z pressed.
- Eg. Shift+Y means that movement does not change in Y axis.
Grid
- Editor can render grid when enabled from menu View > Grid.
- On toolbar you can enable/disable Snap to grid and Snap to nodes.
- Beware: Grid is placed in zero height, if you have items in different height, the snapping may seem weird as it is distorted by perspective.