π Create a Custom Locale
This guide explains how to add your own language translation (locale) for use in Dream scripts.
Please use official language codes as file names (e.g., de
for German, fr
for French).
info
π¬ Feel free to share your translation with the community β help others benefit!
π οΈ Step-by-Step Guideβ
1. π Copy an Existing Localeβ
Navigate to the /settings/locales
folder.
Copy an existing file (e.g., en.lua
) and rename it using your language code.
Example:
de.lua
β Germanfr.lua
β French
2. π Update the Locale Identifierβ
Open your new file and update the DreamLocales
identifier at the top to match your language code:
DreamLocales['en'] = {
-- Your translated keys
}
3. π Translate the Valuesβ
Translate all values into your target language.
β οΈ Do not change the keys β only edit the text on the right side of each line:
["open_menu"] = "MenΓΌ ΓΆffnen", -- β
OK
["ΓΆffne_menΓΌ"] = "Open Menu", -- β Don't translate keys!
4. β Activate Your Localeβ
To use your new locale, open the DreamCore
config file and set:
DreamCore.Language = 'de'
Replace 'de'
with your language code.
π§ Tipsβ
- Test your translations in-game after saving.
- Ensure all keys are translated to avoid missing text.
- Never ever change the key names β only the values.
- Keep formatting and special characters intact (e.g.,
~INPUT_CONTEXT~
,~r~
,%s
etc.) - Share your translation with others in the community!
Happy translating! π