RedM documentation
Murphy's Doctor
Getting Started
Localization
One setting chooses the language of the whole resource:
The texts live in two layers, and both follow Config.Locale:
| Layer | Files | Covers | Languages shipped |
|---|---|---|---|
| Script (Lua) | shared/locales/<code>.lua and its companion files |
Notifications, prompts, vitals, coma causes, symptoms, medication and dose names, grimoire content, minigame instructions, staff command messages | 5 |
| Interface | ui/build/locales/<code>.js |
Labels, buttons and titles of every screen | 22 |
No rebuild is needed for either layer: edit the file and restart the resource. All of these files are editable in both editions.
Languages
| Code | Script texts | Interface |
|---|---|---|
en (English) |
yes | yes |
fr (French) |
yes | yes |
es (Spanish) |
yes | yes |
de (German) |
yes | yes |
pt-BR (Brazilian Portuguese) |
yes | yes |
ar, cs, hu, it, ja, ko, nl, pl, pt, ro, ru, sv, tr, uk, zh, zh-CN, zh-TW |
English | yes |
With a language that only exists for the interface (for example Config.Locale = "it"), the interface is in that language and the script texts are in English. You can add the script texts yourself, see Add a language.
Script texts (Lua)
Files
Each language is split into four files in shared/locales/, all loaded automatically:
| File | Content |
|---|---|
<code>.lua |
Almost everything: interactions, causes, vitals, injuries, medications, doses, help calls, poisons, consumables, treatment, coma, dispensary, duty, treasury, billing, staff messages, grimoire diseases |
<code>_mg3d.lua |
The world minigames (surgery, injection, apothecary bench) |
<code>_records.lua |
The medical file and the autopsy |
<code>_transport.lua |
Carrying, the stretcher and the dispensary beds |
How a text is found
Each text has a dotted key such as causes.fall or dispensary.recruited. The script looks for it:
- in the language of
Config.Locale, - otherwise in English (
shared/locales/en.luaand its companions), - otherwise the key itself is shown.
A language file can therefore be partial: a missing key shows in English. If you see a raw key such as help.reasons.fire in game, it is missing from both your language and English.
Messages sent by the server are sent as keys and translated by each player's client, so every player sees them in the server's Config.Locale.
Edit a text
Open shared/locales/<code>.lua (or the companion file), change the text on the right, keep the key on the left. Keep the %s and %d placeholders: names and numbers replace them.
Add a language
- Copy the four English files and rename them with your code, for example
it.lua,it_mg3d.lua,it_records.lua,it_transport.lua. - In each new file, replace the language name of the table:
Locales.en = {becomesLocales.it = {in the main file, andLocales["en"]becomesLocales["it"]in the companions. Use the bracket form for a code with a dash:Locales["pt-BR"]. - Translate the texts, never the keys.
- Set
Config.Locale = "it".
There is nothing to add to fxmanifest.lua. Use the same code as the interface file so both layers switch together.
Per-server overrides in the config
Some config files have a Labels table (or a label field) whose entries are commented out. Fill one in to replace that text on your server, whatever the language. A value set there wins over the language files, so it is not translated.
| Setting | File |
|---|---|
Config.Consumables.Labels |
shared/config_consumables.lua |
Config.HelpCall.Labels, and label on a PredefinedReasons entry |
shared/config_helpcall.lua |
Config.Notifications.Labels |
shared/config_metabolism.lua |
Config.Nurse.Labels, and label on a nurse NPC |
shared/config_nurse.lua |
Config.Poison.Labels |
shared/config_poison.lua |
Config.Infection.InfectionNotifyText, and notifyText on a vaccine |
shared/config_infection.lua |
Config.Grimoire.KeybindLabel |
shared/config.lua |
blip.label on a dispensary |
shared/config_dispensary.lua |
For a translation, prefer the language files. Keep these overrides for wording specific to your server.
Interface texts
How the interface picks its language
- The page starts with the
localeofui/build/config.js("en"). - As soon as it has loaded, it asks the game for the language and switches to
Config.Locale. - If
murphy_platformruns and publishes a server-wide language, the interface uses that language instead, and follows it live when it changes.
In practice you never edit ui/build/config.js: set Config.Locale and the interface follows. config.js only covers the first moments before the game answers.
The murphy_platform language applies to the interface only. Script texts always follow Config.Locale: keep both on the same language.
The interface always loads en.js first, then your language on top of it. A key missing from your language shows in English, and a missing language file gives an English interface.
Edit a text
Open ui/build/locales/<code>.js and change the value on the right. Keep the key on the left and the structure of the file:
Add a language
- Copy
ui/build/locales/en.jstoui/build/locales/<code>.js. - Translate the values.
- Set
Config.Locale = "<code>".
Open source edition: the same files are in ui_src/public/locales/. They are copied into ui/build/locales/ when you rebuild the interface, so apply your changes there too if you rebuild.
Grimoire texts
The grimoire entries (diseases and injuries) are defined in Config.Treatment.GrimoireEntries (shared/config_treatment.lua). That table holds the ids and the game rules, with French texts as the base version. shared/grimoire_locale.lua replaces those texts at display time with the diseases block of the language file, keyed by the entry id:
Rules:
- A text present in the language file wins over the config. To change the text of a shipped entry, edit
diseases.<id>inshared/locales/<code>.lua: editing the French text inconfig_treatment.luahas no visible effect while the language file has that key. - A field missing from the language file falls back to the config text.
playerSymptomsandcontextare lists: keep the same number of entries, in the same order, as in the config.vitalsuses the same keys as the config entry.
All shipped entries are translated in the 5 script languages.
Your own diseases
Add the entry to Config.Treatment.GrimoireEntries with its texts written directly in your language: it works without any language key, the config texts are shown as they are. Add a diseases.<id> block to the language files only if you run several languages.
The config urgency must be one of "modérée", "haute", "critique", "variable" (or "moderate", "high", "critical"): the colour of the urgency badge depends on it, whatever the language. The text on the badge is the language file's urgency when there is one.
Medication and dose labels
Medication texts are in the medications block of the language file, keyed by item name:
When a medication has no label in the language file, the script uses a label field on its Config.Treatment.MedicationItems entry, then the item label of your inventory, then the item name. description, symptoms and treatment fall back to fields of the same name on the config entry, or stay empty.
Doses
Doses are config values such as "5ml", "15 gouttes" or "Cataplasme thoracique". The same value is the key of the efficacy table, so never translate a dose in the config. Its displayed text comes from the doses block of the language file, keyed by the exact config value:
A dose without an entry is shown as written in the config, which is why numeric doses ("5ml", "0.05mg") have none. When you add a dose that needs a translation, add it to MedicationItems, to MedicationEfficacy and to the doses block of each language you use.
Injury labels
An injury stores only its type (cut, fractured, projectile...). Its name is chosen when it is displayed, from the language file (shared/injury_label.lua), so every injury shows in the current language whatever created it:
injuryTypes.<type>in the language file;- otherwise the
labelof the type inshared/injuries_types.lua; - otherwise the generic "injured" text.
Body part names are in bodyParts (script) and in bodyParts of the interface file.
Other names
| Text | Where |
|---|---|
| Prescription side effect names and messages | treatment.debuffs.<id> in the language file. The French label and notification of Config.Treatment.PrescriptionDebuffs are only the fallback |
| Help call reasons | help.reasons.<id> in the language file |
| Coma cause stored on the treatment form and in the incident records | causes.<key> in the language file of Config.Locale. An optional Config.Coma.CauseLabels overrides it, see Coma |
| Dispensary names | name in Config.Dispensaries (not translated) |
| Epidemic zone names | label in the zones of shared/config_epidemic.lua (not translated) |
| Rank of a doctor recruited from the board | Config.Dispensary.DefaultRank (not translated) |
Rank given by doc_addchief / doc_adddoctor |
dispensary.default_chief_rank / dispensary.default_doctor_rank in the language file |
| Item names in the inventory | Your inventory's item definitions, see Items |
Keep your changes
An update replaces the language files. Keep a copy of every file you edited and merge your changes into the new files after updating (new versions may add keys).
Last updated: November 20, 2026