-
Notifications
You must be signed in to change notification settings - Fork 2
Language Maintenance
RiptOPL's on-screen text is built from three sources that tools/lang_compiler.py merges at
build time. This doc explains the pipeline and the exact steps to add or update strings.
| Piece | What it is | Do you edit it? |
|---|---|---|
lng_tmpl/_base.yml |
The fork's master list of every string + its English text. Source of truth. | Yes — add strings here. |
lng_fork/<Language>.yml |
The fork's own translations of fork strings (and overrides). | Yes — add translations here. |
lng_src/ (git-ignored) |
The upstream community translations, cloned from ps2homebrew/Open-PS2-Loader-lang by tools/download_lng.sh. |
No — upstream owns these. |
tools/lang_compiler.py |
The tool that assembles everything into the binary .lng files + the C sources. |
No (it's the machinery). |
- label: MMCE_PREFIX
string: MMCE Prefix Pathtranslations:
MMCE_PREFIX: Chemin du préfixe MMCE-
--make_header/--make_source→ generateinclude/lang_autogen.h(the_STR_*enum every.cfile uses) andsrc/lang_internal.c(the built-in English fallback) straight from_base.yml. So English is always complete and automatic — you never translate English, and a missing translation always falls back to English, never blank. -
--update_translation_yml→ sync each upstreamlng_src/<Lang>.ymlagainst_base.yml; any label it lacks is markeduntranslated. -
--overlay_translation_yml --overlay lng_fork/<Lang>.yml→ pour the fork's own translations on top. If upstream later translates a label, the overlay quietly steps aside (upstream wins). Idempotent — safe to re-run. -
--make_lng→ compile the merged.ymlinto the binarylng/lang_<Lang>.lng.
lang_autogen.h and lang_internal.c are generated (git-ignored) — never hand-edit them.
-
Add it to the END of
lng_tmpl/_base.yml, below the APPEND-ONLY banner (~line 923):- label: MY_NEW_SETTING string: My New Setting
External
lang_*.lngfiles are consumed by line position (lang.c), so inserting a label mid-list shifts every later string ID and makes stale user language packs show the wrong text — never an English fallback. -
Use
_STR_MY_NEW_SETTINGin code (the enum id is auto-generated). -
That's enough to ship — it shows English everywhere until translated.
Add the key under translations: in the target lng_fork/<Language>.yml:
translations:
MY_NEW_SETTING: Mon nouveau réglageRepeat per language you want to cover. Untranslated languages fall back to English.
tools/lang_compiler.py only merges translations that already exist in lng_fork/*.yml. The
initial bulk fill of the 31 fork languages was a one-off external step (a machine
translation pass), not part of this repo's build. So to keep translations current you must
supply the translated text for lng_fork/*.yml yourself (by hand, an external MT tool, or
an assistant) — the build will not invent it.
The TRANSLATIONS list in the Makefile decides which lang_<Language>.lng files get built. A
language exists upstream as lng_src/<Language>.yml; to ship it, add its name to that list.
-
Fonts. A language that needs glyphs the built-in font lacks has a
font_<Language>.ttf(or.otf) in the upstream repo'sthirdparty/folder.tools/lng_pack.shcopies it beside the.lngin theRIPTOPL-LANGSpack, and the loader picks it up from the same folder. -
Serbian has no font upstream, and the built-in font has no
č,ćorđ. Serbian Latin uses exactly Croatian's letters, solng_pack.shshipsfont_Croatian.ttfasfont_Serbian.ttf. Check a new language's characters against the built-in font before assuming it needs no font. -
Fork strings. A language with no
lng_fork/<Language>.yml(Galician and Serbian today) shows the fork's own strings in English until someone adds that file.
make languagesRequires python3 + PyYAML (py3-yaml) and network access for tools/download_lng.sh (first
run clones the upstream lang repo into lng_src/). CI does this automatically.
Fork-added strings are the labels in lng_tmpl/_base.yml that upstream doesn't have. To
see which are still English-only in a given language, run make languages and look for
untranslated entries in lng_src/<Language>.yml after the overlay step.
Related guide: Languages.
Source: docs/LANGUAGES.md @ 3ce281b0793c.
Start here
Storage and networking
- USB, MX4SIO and iLink
- MMCE
- Internal HDD: APA and exFAT
- SMB shares
- Network boot: UDPFS and UDPBD
- HTTP
- NBD server
Games and features
- Neutrino core
- PS1: POPStarter and Ember
- Per-game settings
- Virtual memory cards
- GSM video modes
- In-game reset
- Cheats
- PADEMU
- RetroAchievements
- Apps
Interface and customization
Help and reference
- Troubleshooting
- ZSO format
- Backward-compatible PS3
- Credits and sources
- Features in other forks
- Project overview
Detailed references
- Complete repository guide
- Rolling release reference
- APA hard disk safety and code 402
- Autolaunch and global settings
- Controls reference
- GSM reference
- HTTP reference
- In-game reset reference
- Folders, parental lock and audio
- Language maintenance
- MX4SIO launch reference
- Neutrino reference
- PADEMU reference
- RetroAchievements reference
- Theme engine: full authoring reference
- PS1/VCD reference
- HTTP server conformance tools
- APA recovery tool