Changes

Jump to navigation Jump to search

Games/ETS2/Modding guides/1.33

2,003 bytes added, 23:04, 16 December 2018
Mods localization support
{{Tip|Be aware that page is not final. Thus do not fully rely on written subjects, until this message is here!}}
 
 
= Introduction =
* Select correct looks for models where the selection of the looks changed
= Changes & New Features =
== Cloud Profiles ==
This update supports use of Steam Cloud which can be enabled on per driver profile basis. Please note that the cloud is only used to store the profile data and saves. If you are using cloud to synchronize profiles between multiple computers, you still need to ensure that the mods required by those profiles are available and updated on all relevant computers either using Steam Workshop or manually.
If profile is not opted-in into the cloud, which is the default behavior for already existing profiles, it will be stored in '''"Documents\Euro Truck Simulator 2\[[Documentation/Engine/Game_user_path|Game User Path]]/profiles" ''' as before. If profile is opted-in, most of its files are managed internally by the Steam Client. There is still small part of profile configuration which is not stored on the cloud. It contains setting related to HW such as input binding or sound settings. This portion is stored in '''"Documents\Euro Truck Simulator 2\[[Documentation/Engine/Game_user_path|Game User Path]]/steam_profiles"'''" and you need to configure this part on each new computer you use the cloud profile on.
As with the opted-out profiles, the game will create a backup copy of the profile the first time a new version of the game runs on the computer. Note that the backup copy is created as a local copy. If you want to restore something from it, you need to opt-out the profile from the Steam, copy the files from the backup and then opt-it back in.
An '''automatic company paint job selection''' has been added, which randomly selects one of the paint jobs stored in '''company_paint_job''' directory at corresponding trailer chassis definition location (i.e. player trailer paint jobs). This feature can be turned on using the following attribute in traffic trailer definition:
company_paint_job: true
 
== Mods localization support ==
 
From 1.33 mods can add new localization strings. To do this inside directory '''/locale/$language$/''' you have to create localization module. The module file name should be called that way: '''local_module.$mod_name$.sii''' for example '''local_module.mod_awesome_jobs.sii'''. The file must define single unit of class '''localization_db'''.
 
{{Note|$language$ should be tag of language the localization is for, for example: british english is '''en_gb''', american english is '''en_us''', polish is '''pl_pl''', czech is '''cs_cz''' etc.}}
 
Example:
<pre>
SiiNunit
{
localization_db : .localization
{
key[]: "chassis" # This is localization token, you can use it by typing @@chassis@@. We recommend to keep them written using lower-case alpha-numeric ASCII characters.
val[]: "Chassis" # This is its value in the language. For every language this value can be different.
 
key[]: "truck_cabin" # Another localization token.
val[]: "Cabin" # And its value - as you can notice its always pair of key and val attributes.
 
# ...
}
}
</pre>
 
If you do so your mod should be properly localized now.
 
{{Note|Mods localization cannot override strings that are already defined. That means localization for example of key 'chassis' defined in game main localization will be used first, and if not defined mod with highest priority will be used.}}
{{Tip|Our system does not fallback untranslated tokens to english so you have to define localization for all languages supported by the game. Currently game supports following list of the languages.
 
<pre>bg_bg, ca_es, cs_cz, da_dk, de_de, el_gr, en_gb, en_us, es_es, es_la, et_ee, eu_es, fi_fi, fr_fr, gl_es, hr_hr, hu_hu, it_it, ja_jp, ka_ge, ko_kr, lt_lt, lv_lv, mk_mk, nl_nl, no_no, pl_pl, pl_si, pt_br, pt_pt, ro_ro, ru_ru, sk_sk, sl_sl, sr_sp, sr_sr, sv_se, tr_tr, uk_uk, vi_vn, zh_cn, zh_tw</pre>
 
If you cannot afford translating your mod to each language we recommend to at least copy english localization to rest of them.}}
developer
1,626
edits

Navigation menu