> For the complete documentation index, see [llms.txt](https://code-after-sex.gitbook.io/script-documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://code-after-sex.gitbook.io/script-documentation/cas-wagon-livery-studio/languages.md).

# Languages

CAS Wagon Livery Studio languages: English, Turkish, German, French, Spanish, Portuguese (Brazil), Russian and Polish, and how to add your own with one JSON file.

Every text staff and players see (the studio, the livery book, the counter prompt and blip, the messages) comes from one file per language in `locales/`.

* `en`: English
* `tr`: Turkish
* `de`: German
* `fr`: French
* `es`: Spanish
* `pt-BR`: Portuguese (Brazil)
* `ru`: Russian
* `pl`: Polish

Pick one in `config.lua`:

```lua
Config.Locale = "de"
```

## Add your own

1. Copy `locales/en.json` to `locales/<code>.json`, for example `locales/it.json`. (`locales/template.json` has every key with an empty value, if you prefer to start blank.)
2. Translate the values. Keep the keys and the `{placeholders}` (`{name}`, `{n}`, `{slot}`, `{price}`...) as they are.
3. Set `Config.Locale = "it"` and restart the server.

A text your file lacks, or leaves empty, shows in English, so a half-done file never breaks a screen. A broken file (not valid JSON) shows English everywhere, and the client console says so.

{% hint style="info" %}
Save the file as UTF-8. A file saved with a byte order mark works too.
{% endhint %}

## Words worth a look

Some words depend on your server's setting, so check them in your language:

* `book.title` (*Stables*): the book's title away from a stable.
* `counter.open` (*Livery book*) and `counter.blip` (*Liveries*): the counter prompt and its map blip.
* `export.shops` (*Stables*): the hand-out choice for selling at the stables.
* `error.no_wagon`, `error.wrong_wagon`, `error.not_here`: what players read when Apply or Buy cannot work.
