RedM documentation

Murphy's Doctor

Configuration

General settings


This page covers shared/config.lua (framework, language, doctor detection, player interactions, keybinds, grimoire, notifications) and the two helper files loaded next to it: shared/framework.lua and shared/optional_resources.lua. It also documents Config.Notifications and Config.DiscordLogs, which live at the bottom of shared/config_metabolism.lua.

Framework and language

Key Default Description
Config.framework "auto" Which roleplay framework to talk to. "auto" probes the running resources at startup (see Framework detection). You can force one: "REDEMRP2k23", "vorp" or "rsg". Aliases are accepted, case-insensitive: "redemrp", "redem", "redem_roleplay", "vorp_core", "vorpcore", "rsg-core", "rsgcore". An unknown value prints a red warning and falls back to auto-detection.
Config.Locale "en" Language of every text the resource shows: Lua strings (notifications, prompts, vitals, coma causes) and the NUI. Shipped Lua languages: en, fr, de, es, pt-BR. When murphy_platform runs, its server-wide language overrides this value. Missing keys fall back to English. See Localization.
lua
Config.framework = "auto" -- or "vorp", "rsg", "REDEMRP2k23"
Config.Locale = "fr"

Notifications

Every notification of the script, server ones included, goes through one setting. Full details, zones and examples are in Notifications.

Key Default Description
Config.NotifyStyle "murphy" "murphy": the Murphy info box at the top right (rendered by murphy_notify 2.0 when it runs, by the built-in copy otherwise). "framework": your framework's notification (ox_lib on RSG, VORP or REDEM:RP tips). "native": the game's own notification feed on the left. "custom": calls Config.CustomNotify.
Config.NotifyZones see below Screen zones of the Murphy box when murphy_notify is not running (with murphy_notify, its own zones apply). A notification picks its zone by name, otherwise feed.
Config.NotifyZones.<zone>.position - "top-right", "top-left", "top-center", "bottom-right", "bottom-left" or "bottom-center".
Config.NotifyZones.<zone>.max - How many boxes can show at once in that zone.
Config.CustomNotify ox_lib event Function run on the client for every notification when NotifyStyle = "custom". Arguments: title, text (both already translated), kind ("info", "success", "warning", "error"), duration (milliseconds), icon (the icon the Murphy box would show, or nil), zone (or nil). If the function errors, the game's own notification is shown instead and the error is printed in F8.

Shipped zones:

Zone position max
feed "top-right" 4
center "top-center" 2
left "top-left" 4
bottom "bottom-center" 3
lua
Config.NotifyStyle = "custom"
Config.CustomNotify = function(title, text, kind, duration, icon, zone)
exports["my_notify"]:Send(title, text, kind, duration)
end

Debug, cleanup and staff

Key Default Description
Config.Debug false Prints [Murphy Doctor DEBUG] lines in the consoles and registers the /doc:* test commands (see Commands). While it is on, every player sees the doctor prompts and a doctor may sign a treatment on himself. Never leave it on in production.
Config.CleanDeletedCharacters true A minute after the resource starts, removes the doctor rows of characters deleted from your framework: health, coma, HUD layout, duty, dispensary membership, addictions. Reports, invoices and incident records are kept as the dispensary's history. false keeps everything.
Config.AdminGroups { "admin", "superadmin" } Framework groups allowed to run the staff commands (for example /doc:disease, /doc:infect:*, doc_addchief, doc_archives) even with Config.Debug = false. The server console is always allowed. On REDEM:RP and VORP these are character groups. On RSG they are ACE principals (rsgcore.<group>, for example "admin" or "god").

Who is a doctor

Doctor status decides who sees the doctor prompts, who can open the grimoire, examine, treat, revive, operate and use the apothecary bench. It is checked on the server and cached for 30 seconds per player, so a job change can take up to 30 seconds to apply.

Key Default Description
Config.Interactions.DoctorDetection "database" How a doctor is recognised. See the table below.
Config.Interactions.DoctorJobRequireDuty false With the "job" mode, only players who are on duty count. Needs a framework with an on-duty flag (RSG). On other frameworks a yellow warning is printed at start and the option is ignored.
Config.Interactions.DoctorSpeFromCraft false When true and murphy_craft is running, a player who unlocked the doctor specialisation tree in murphy_craft also counts as a doctor, on top of DoctorDetection. Fully inert without murphy_craft.
Config.Interactions.DoctorSpeCraftId "docteur" Id of the doctor specialisation tree in murphy_craft. The player must have unlocked its root node.
Config.DoctorJobs { "doctor", "medecin", "physician", "medic" } Framework job names that count as doctor for the "job" mode. Compared without case. medic is the stock RSG medical job.
Config.DoctorWhitelist {} Identifiers for the "whitelist" mode. An entry is either an account identifier exactly as the server reports it ("license:...", "steam:...", "discord:...", "fivem:...") or a character identifier (charid / citizenid, depending on the framework). The list is read once: restart the resource after editing it.

DoctorDetection values:

Value A player is a doctor when
"database" They are on a dispensary roster, managed in game from the dispensary board. No job system needed. Staff appoint the first chief with doc_addchief.
"job" Their framework job is in Config.DoctorJobs.
"whitelist" One of their identifiers is in Config.DoctorWhitelist.
"both" "job" or "database".
"any" "job", "database" or "whitelist".
a table Any of the listed modes, for example { "job", "whitelist" }.
lua
Config.Interactions.DoctorDetection = { "job", "whitelist" }
Config.DoctorJobs = { "doctor", "surgeon" }
Config.DoctorWhitelist = {
"license:0123456789abcdef0123456789abcdef01234567",
"steam:110000112345678",
}

Player interactions

The doctor's actions on another player: examine, treatment, revive, bandage, surgery, autopsy and transport.

Key Default Description
Config.Interactions.Enabled true false removes all player-to-player doctor interactions.
Config.Interactions.PromptType "auto" "murphy_interact": 3D targets from murphy_interact. "native": native RedM prompt groups, fully standalone. "auto": murphy_interact when it runs, native prompts otherwise. With "auto", the prompts switch on the spot when murphy_interact starts or stops. Dispensaries, archives, duty and nurse have their own PromptType settings.
Config.Interactions.PromptVisibility "doctors_only" "doctors_only": only doctors see the examine option. "everyone": everyone sees it (open-RP servers, testing). The server still refuses the actions to non-doctors.
Config.Interactions.Distance 3.5 Metres. Distance at which the murphy_interact target becomes visible.
Config.Interactions.InteractDistance 3.0 Metres. Distance at which the native prompts appear and the doctor can act. Kept at 3.0 so a ragdolled body on the ground stays reachable. The server allows 1 extra metre for the bandage and revive checks. Also sets the radial menu selection range.
Config.Interactions.PromptKey 0xCEFD9220 (E) Legacy single key for the examine prompt, used when NativeKeys.Auscultate is missing. The nurse NPC prompt also uses it when Config.Nurse.PromptKey is nil.
Config.Interactions.NativeKeys see below Native prompt key per doctor action (native mode only). Values are RedM control hashes, see Keybind hash reference.

Config.Interactions.NativeKeys:

Key Default Action
Auscultate 0xCEFD9220 (E) Examine the patient
Treatment 0xE30CD707 (R) Open the treatment form
Revive 0xB2F377E8 (F) Revive a patient in a coma
Bandage 0xF3830D8E (J) Apply a bandage
Surgery not set, 0x760A9C6F (G) Operate. Optional key, add it to change the default.
Autopsy not set, Config.Autopsy.PlayerKey (U) Autopsy of a player in a coma. Optional key.
Transport not set, 0x84543902 (interact option 2, H by default) Carry or stretcher. Optional key.
lua
Config.Interactions.NativeKeys = {
Auscultate = 0xCEFD9220, -- E
Treatment = 0xE30CD707, -- R
Revive = 0xB2F377E8, -- F
Bandage = 0xF3830D8E, -- J
Surgery = 0x760A9C6F, -- G
}

Bandage

A quick HP patch from a doctor on a conscious patient. It does not touch injuries, diseases or conditions: real wounds go through the treatment form. Refused on a patient in a coma (use revive).

Key Default Description
Config.Interactions.Bandage.Enabled true Shows the "Apply a bandage" option.
Config.Interactions.Bandage.Item "bandage" Item taken from the doctor, one per bandage. It must exist in your inventory.
Config.Interactions.Bandage.HealAmount 30 HP restored on the patient, capped at max health.
Config.Interactions.Bandage.AnimDuration 4500 Milliseconds. Length of the bandage animation; the HP are applied at the end. Also the per-doctor cooldown (plus 0.5 s).

Revive

Key Default Description
Config.Interactions.Revive.Item "concentrestimulant" Item the doctor must carry and spends to revive a patient in a coma. Without it the revive is refused with a notification. nil makes revives free.
Config.Interactions.Revive.Amount 1 Quantity taken per revive.

Examination and health panel

Key Default Description
Config.AuscultationDistance 2.0 Metres. When an examination is started without a target (debug command or export), the closest player within this distance is examined.
Config.AuscultationRefreshInterval 5000 Milliseconds. How often the open examination window refreshes the patient's vitals. 0 disables live refresh (vitals are read once).
Config.HealthKeybind 0x72 (F3) Key that opens the player's own health panel. It is a Windows virtual-key code read directly, so players do not have to bind it. Common codes: F1 0x70, F2 0x71, F3 0x72, F4 0x73, F5 0x74, F6 0x75, F7 0x76, F8 0x77. Full list: Microsoft "Virtual-Key Codes". nil disables the key.

Grimoire

The medical encyclopedia. It opens from the dispensary grimoire points, the keybind, the /grimoire command or the item. Every path requires the player to be a doctor. Its content is defined in Treatment.

Key Default Description
Config.Grimoire.Keybind "K" Default key registered with RedM's key mapping. Players can rebind it in the RedM key bindings menu; on some RedM builds they must confirm it there before it works. nil disables the key mapping (/grimoire and the dispensary still work).
Config.Grimoire.KeybindLabel nil Label of the binding in the key bindings menu. nil uses the locale text health.grimoire_keybind_label.
Config.Grimoire.Item "grimoire_medical" Usable item that opens the grimoire. It is not consumed. It must exist in your inventory. nil disables the item.

Legacy display tables

These tables are still shipped in config.lua but the 1.0 code does not read them. Changing them has no effect. Texts come from the locale files and the injury definitions instead.

Key Where the real setting is
Config.BodyParts Only used to validate the wound zone of a death certificate. The body zones themselves are fixed: head, belly, left-arm, right-arm, left-leg, right-leg, left-foot, right-foot.
Config.SeverityThresholds Not read. The vitals severity thresholds (25 / 50 / 75 percent) are built into the health panel.
Config.InjuryLabels Not read. Labels come from shared/locales/<lang>.lua (injuryTypes.*, symptoms.*), see Localization.
Config.ConditionIcons Not read.

Threshold notifications

Config.Notifications lives in shared/config_metabolism.lua. It warns the player when a vital crosses a threshold.

Key Default Description
Config.Notifications.Enabled true Turns the threshold warnings on.
Config.Notifications.ThresholdCooldown 60 Seconds between two warnings of the same type.
Config.Notifications.Thresholds.Hunger.low 30 Percent. "Getting hungry" warning below this.
Config.Notifications.Thresholds.Hunger.critical 15 Percent. "Starving" warning below this.
Config.Notifications.Thresholds.Thirst.low 30 Percent.
Config.Notifications.Thresholds.Thirst.critical 15 Percent.
Config.Notifications.Thresholds.Health.low 30 Percent of health.
Config.Notifications.Thresholds.Health.critical 15 Percent of health.
Config.Notifications.Thresholds.Temperature.cold 35 Degrees Celsius of body temperature. Below: hypothermia warning.
Config.Notifications.Thresholds.Temperature.hot 38 Degrees Celsius. Above: fever warning.
Config.Notifications.Labels {} Optional text overrides, same shape as the commented example in the file (Hunger.low, Thirst.critical, Temperature.feeling_cold...). Leave empty to use the locale texts (metabolism.*).

Discord logs

Config.DiscordLogs lives in shared/config_metabolism.lua. The webhook URLs live in server/adapters/webhooks.lua (server only, so players cannot read them). Logs are sent from the server as Discord embeds with the player's name and character id.

Key Default Description
Config.DiscordLogs.Enabled false Master switch. Set true and fill the webhooks in server/adapters/webhooks.lua.
Config.DiscordLogs.BotName "Murphy Doctor" Name shown as the webhook author.
DoctorWebhooks.<type> "" Webhook URL per log type, in server/adapters/webhooks.lua. An empty URL skips that type.
Config.DiscordLogs.Colors.<type> see file Embed colour per log type, as a decimal number.
Config.DiscordLogs.LogEvents.<Type> true Per-type switch. Note the capital first letter (Coma, Revive...).

Log types:

Type (DoctorWebhooks / Colors key) LogEvents key Sent when
coma Coma A player falls into a coma
revive Revive A player is revived (doctor, natural get-up, treatment), or an early coma exit is refused
treatment Treatment A treatment report is signed
injury Injury A severe injury is recorded
infection Infection A disease is caught or a vaccine given. Also needs Config.Infection.LogToDiscord (Infection)
bandage Bandage A doctor applies a bandage
billing Billing An invoice is issued
nurse Nurse The nurse NPC heals a player
treasury Treasury Money is withdrawn from the dispensary till
lua
-- shared/config_metabolism.lua
Config.DiscordLogs.Enabled = true
-- server/adapters/webhooks.lua
DoctorWebhooks = {
coma = "https://discord.com/api/webhooks/...",
treatment = "https://discord.com/api/webhooks/...",
-- leave the other types empty to skip them
}

Webhooks still set in Config.DiscordLogs.Webhooks (the 1.0.0 location) keep working, but the server prints a red warning at start until you move them.

Framework detection (framework.lua)

shared/framework.lua turns Config.framework into one value that every adapter checks: Config.FrameworkResolved, which is "REDEMRP2k23", "vorp" or "rsg". It has no setting of its own.

  • With "auto", it checks which of these resources is started, in this order: redem_roleplay, vorp_core, rsg-core. The first one found wins.
  • Your framework must start before murphy_doctor in server.cfg, otherwise auto-detection finds nothing.
  • When nothing is found, the console prints NO SUPPORTED FRAMEWORK DETECTED in red. Fix the start order or set Config.framework explicitly.
  • With Config.Debug = true, the resolved framework and how it was found are printed at start.

Other scripts can call the global IsFramework("vorp") from inside the resource. See Frameworks.

Optional resources (optional_resources.lua)

shared/optional_resources.lua has no setting. On the client, it watches murphy_interact and murphy_radialmenu: when one of them starts after the doctor, or stops during the session, the modules that use it (interactions, archives, dispensary, duty, treasury, nurse, apothecary bench) rebuild their prompts on the spot. No restart of murphy_doctor is needed.

Keybind hash reference

Native prompt keys use RedM control hashes. The reference block at the top of shared/config.lua:

Key Hash Key Hash Key Hash
A 0x7065027D J 0xF3830D8E U 0xD8F73058
B 0x4CC0E2FE L 0x80F28E95 V 0x7F8D09B8
C 0x9959A6F0 M 0xE31C6A41 W 0x8FD015D8
D 0xB4E465B4 N 0x4BC9DABB X 0x8CC9CD42
E 0xCEFD9220 P 0xD82E0BD2 Z 0x26E9DC00
F 0xB2F377E8 Q 0xDE794E3E ENTER 0xC7B5340A
G 0x760A9C6F R 0xE30CD707 BACKSPACE 0x156F7119
H 0x24978A28 S 0xD27782E3 TAB 0xB238FE0B
I 0xC1989F95 - - LSHIFT 0x8FFC75D6
LCTRL 0xDB096B85 LALT 0x8AAA0AD4 SPACE 0xD9D0E1C0
DELETE 0x4AF4D473 - - - -

Config.HealthKeybind is the exception: it takes a Windows virtual-key code, not a RedM hash.


Last updated: November 20, 2026