Changes

Jump to navigation Jump to search

Games/ETS2/Modding guides

6,511 bytes removed, 00:12, 21 April 2022
Updates
With each new game patch update we are also shipping modding guides for users to be able to get their existing mods up-to-date.
Page is organizing modding guides by patch update version numbers.
= Misc useful commands =
<ul>
<li>Running the game with <strong>-unlimitedlog</strong> command line parameter will disable the standard 1MB limit on size of game log file. This might be useful during update if you want to focus on some bugs first.</li>
<li>Running the game with <strong>-validate</strong> command line parameter or executing <strong>validate</strong> command on the console will run special game mode which will load all defined models, prefabs, vehicles and other objects to detect missing textures and similar errors. By examining the game log you can determine what the game was trying to do when error appeared. Note that there is still lot of things which might be wrong which are not checked in this mode.</li>
<li>Running the game with <strong>-error_overlay</strong> command line parameter will show overlay with number of error and warning messages printed to the log once at least one such message is printed.</li>
</ul>
* Running the game with <strong>-unlimitedlog</strong> command line parameter will disable the standard 1MB limit on size of game log file. This might be useful during update if you want to focus on some bugs first.
* Running the game with <strong>-validate</strong> command line parameter or executing <strong>validate</strong> command on the console will run special game mode which will load all defined models, prefabs, vehicles and other objects to detect missing textures and similar errors. By examining the game log you can determine what the game was trying to do when error appeared. Note that there is still lot of things which might be wrong which are not checked in this mode.
* Running the game with <strong>-error_overlay</strong> command line parameter will show overlay with number of error and warning messages printed to the log once at least one such message is printed.
= Patch: 1.22 Updates =
== 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 significantly in some next patch. For this reason it is recommended that you avoid using them in your mods at this time* [[Games/ETS2/Modding guides/1.44]]<* [[Games/li> <li> When basing you model on the original ones, add to your mod also <strong>ALL<ETS2/strong> original Modding guides/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 parameters1.43]]<* [[Games/li> <li> When modifying original models, always include <strong>ALL<ETS2/strong> compoments of the model (pmg+pmd) instead of just those you changed. Otherwise you risk crash if we change the modelModding guides/1.42]]<* [[Games/li> <li> As always when adding new objects to files which support multi-file approach (e.g. road_look.sii) it is <strong>HIGHLY RECOMMENDED<ETS2/Modding guides/strong> 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 appears1.40]]<* [[Games/ETS2/li><Modding guides/ul>1.39]] == How to convert map ==<ul><li> Temporarily store * [[http:Games/ETS2/eurotrucksimulator2Modding guides/1.com38]]* [[Games/moddingETS2/Modding guides/1.2237]]* [[Games/ETS2/Modding guides/vegetation1.old.sii vegetation.old.sii36]] file into <strong>* [[Games/defETS2/worldModding guides/vegetation1.old.sii<35]]* [[Games/ETS2/Modding guides/strong> to make old definitions of vegetation profiles accessible1.33]]</li> <li> Store * [[http:/Games/eurotrucksimulator2.comETS2/moddingModding guides/1.22/replace.sii this32]] replacement script <strong>Documents\Euro Truck Simulator 2\replace.sii<* [[Games/strong><ETS2/li> <li> Open the map in the editor<Modding guides/li> <li> If the log contains references to missing road looks <ul><li> Provide dummy definitions for them. Otherwise the editor will crash during save or some other operations1.31]]<* [[Games/li> <li> Locate items using those dummy definitions and change them to other suitable looks<ETS2/li><Modding guides/ul> 1.30]]<* [[Games/li> <li> Open the replacement dialog (F3)<ETS2/li> <li> Run "Batch replace"<Modding guides/li> <li> Save map1.28]]<* [[Games/li> <li> Do rebuild (F8)<ETS2/li> <li> Save map<Modding guides/li> <li> Remove dummy road look definitions, if any</li> <li> Remove vegetation1.old27.sii2]]<* [[Games/li><ETS2/Modding guides/ul>1.27]] == Changes ===== Vegetation profiles ===As most of the information previously set by the vegetation profile was moved into the map items, we cleaned up the vegetation templates. Use the attached files (see * [[#How to convert mapGames/ETS2/Modding guides/1.26]]) to convert the map from the old profiles into the new ones. === Models ===We cleaned folder structure of models and some files from DLC Scandinavia were moved to the base. As part of the cleanup content of asset_shared was moved to model2/prefab2 folders. Also some unfinished *_fr files were removed.<br><br>As long your map mod is not overriding our <strong>[[Games/defETS2/worldModding guides/1.25]]*.sii<[[Games/ETS2/strong> files nor depending on those unfinished files, it should be fine. Otherwise you will need to update the definition file with the new paths or replace the referenced objects with something else. If your mod is overriding one from the affected models, you will need to move the models to the new path. === Map ===When saving the map, the editor now creates separate file <strong>europe.set<Modding guides/strong> to store selection sets. That file is not used by game itself and does not have to be included in mod.  = Patch: 1.20 =24]] == 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 significantly in some next patch. For this reason it is recommended that you avoid using them in your mods at this time.<* [[Games/li> <li> When basing you model on the original ones, add to your mod also <strong>ALL<ETS2/strong> original Modding guides/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 parameters1.23]]<* [[Games/li> <li> When modifying original models, always include <strong>ALL<ETS2/strong> compoments of the model (pmg+pmd) instead of just those you changed. Otherwise you risk crash if we change the modelModding guides/1.22]]<* [[Games/li> <li> As always when adding new objects to files which support multi-file approach (e.g. road_look.sii) it is <strong>HIGHLY RECOMMENDED<ETS2/Modding guides/strong> 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 appears1.20]]<* [[Games/li><ETS2/ul> == How to convert map ==<ul><li> Ensure that the log contains no errors related to vegetation profiles. Load of the map in old format will bake most of that information into the map file so it is critical that the information is correct before continuing with the conversion.<Modding guides/li> <li> Use the replacement dialog (F3, "Prefab node correction") to add new prefab nodes which we added to some ferry prefabs in Scandinavia1.19]]<* [[Games/li> <li> Save map<ETS2/li> <li> Do rebuild (F8)<Modding guides/li> <li> Save map1.17]]<* [[Games/li><ETS2/ul> == Changes ===== Traffic-related changes ======= AI vehicle type definition ====To specify spawned trailer count per vehicle, use the array attribute<strong> spawn_trailer_count</strong>. It defines the array of possible trailer counts for gived vehicle type. Before each AI vehicle is spawned, the game randomly selects one of the value from the array. So far, only values <strong>0<Modding guides/strong> and <strong>1 </strong>are supported. For example:<pre># Set the trailer spawn probability to 75&#37;:#spawn&#95;trailer&#95;count&#91;16]]: 0spawn&#95;trailer&#95;count&#91;]: * [[Games/ETS2/Modding guides/1spawn&#95;trailer&#95;count&#91;.15]: 1spawn&#95;trailer&#95;count&#91;]: 1<* [[Games/pre>Currently, the default trailer spawn probability for trucks is <strong>90%<ETS2/Modding guides/strong>1.14]] ==== AI vehicle definition ====To allow better control over AI trailer spawning, the meaning of attribute <strong>attachable_trailer <* [[Games/strong>has been modified: <strong>BEFORE <ETS2/strong>- when choosing a trailer model to spawn, the game randomly selects one, which name matches ANY OF THE STRINGS contained in the array <strong>NOW - <Modding guides/strong>when choosing a trailer model to spawn, the game randomly selects ONE OF THE STRINGS contained in the array and then selects a model which name matches the selected string1. This allows specifying spawn probability for specific trailer models. Furthermore, this attribute <strong>supports wildcard '11]]*'<[[Games/strong> - it can be placed at the beginning of any string, at the end of any string or both (beginning and end) to allow partial trailer name matchesETS2/Modding guides/1.9]] To allow <strong>all</strong> trailer models, use <code>attachable_trailer* []: ""</code> or <code>attachable_trailer[]: "*"<Games/code> Spawned trailer count can be set also per-vehicle by using attribute <strong>trailer_count<ETS2/strong>. It works the same way as <em>spawn_trailer_count <Modding guides/em>defined per-vehicle-type ==== AI trailer definition ====It is now possible to specify, to which AI vehicles can each AI trailer be attached - using array attribute <strong>allowed_tractor</strong>1. This attribute <strong>supports wildcard '*'</strong> - it can be placed at the beginning of any string, at the end of any string or both (beginning and end) to allow partial name matches4. For example:<pre># Allow this trailer be attached only to a single vehicle allowed&#95;tractor&#91;1]]: &#34;traffic.scania&#95;r&#95;a&#34;</pre> By default, all vehicles are allowed.
507
edits

Navigation menu