> 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/vip-shop/guides/localization.md).

# Localization

## Server side texts

Notifications, command feedback and Discord log titles are localized. Files live in `vip_shop/locales/`:

```
locales/
├── en.lua
└── tr.lua
```

Select the language with `Config.Locale = 'en'`.

### Adding a language

1. Copy `en.lua` to, for example, `de.lua`.
2. Change the table key: `Locales['de'] = { ... }`.
3. Translate the values. Placeholders (`%s`, `%d`) must be kept.
4. Set `Config.Locale = 'de'`.

Missing keys fall back to English automatically, so partial translations are safe.

### Key groups

| Group      | Examples                                                 |
| ---------- | -------------------------------------------------------- |
| Purchases  | `purchase_success`, `not_enough_coins`, `inventory_full` |
| Coins      | `coins_received`, `balance_is`                           |
| Redeem     | `redeem_success`, `redeem_expired`, `redeem_already`     |
| Orders     | `order_placed`, `orders_empty`, `charslot_added`         |
| Membership | `membership_set`, `membership_removed`                   |
| Admin      | `no_permission`, `code_created`, usage strings           |
| Discord    | `log_purchase`, `log_order`, `log_membership`            |

## Storefront (UI) texts

The React UI ships in English with an intentional 1899 frontier catalogue tone. To translate it, edit the strings in `src/components/*.tsx` and `src/data/catalog.ts`, then run `npm run build:resource`. Both display fonts include full Latin extended glyph coverage, including Turkish.
