RedM documentation
Murphy's Doctor
Getting Started
Notifications
Every notification of murphy_doctor (the ones sent by the server included) goes through a single client function, Notify in client/notify.lua. One setting chooses how they look, and you can plug in your own system.
Notification style
| Value | Shown with |
|---|---|
"murphy" (default) |
The Murphy info box, top right. Uses murphy_notify 2.0 or newer when it runs, so it looks the same on every Murphy script; otherwise murphy_doctor shows its own copy of that box |
"framework" |
Your framework's notification (see below) |
"native" |
The game's own notification feed, on the left |
"custom" |
Your own function, Config.CustomNotify (see below) |
With "framework":
| Framework | System |
|---|---|
| REDEM:RP 2023 | Event redem_roleplay:NotifyLeft |
| VORP | exports.vorp_core:DisplayLeftNotification (the game's feed on very old cores) |
| RSG-Core | ox_lib:notify |
If the framework adapter has no notification function, the game's own feed is used.
Kinds and icons
A notification has a title (Doctor, Health, Treasury...), a text, a kind and a duration (5 seconds by default). The kinds are info, success, warning and error; older internal types are mapped to them (bleeding and poisoned show as warning, the others as info).
The Murphy box shows one of the game's icons:
- the icon the caller asked for, when there is one;
- otherwise a shield for an immunity notification (vaccine);
- otherwise a money icon when the text contains a
$; - otherwise by kind:
tick(success),cross(error),alert(warning), no icon for info.
The icon name is also passed to Config.CustomNotify.
Screen zones
When murphy_notify does not run, the Murphy box is drawn by murphy_doctor in the zones of Config.NotifyZones:
| Field | Values |
|---|---|
position |
"top-right", "top-left", "top-center", "bottom-right", "bottom-left", "bottom-center" |
max |
How many boxes are shown at once in that zone (4 when missing) |
A notification picks its zone by name (feed when none is given). A caller may also give a position directly (for example "bottom-left"). You can add your own zone names. When murphy_notify runs, its own zone settings apply instead.
murphy_notify
With Config.NotifyStyle = "murphy", murphy_doctor sends each notification to murphy_notify when that resource is started and its version is 2.0 or newer (read from its fxmanifest.lua). The call is exports.murphy_notify:Notify(title, text, kind, duration, icon, zone). With murphy_notify 1.x, absent, or if the call fails, murphy_doctor shows its own box. This is checked for every notification, so starting or stopping murphy_notify takes effect at once.
Your own notification system
Set Config.NotifyStyle = "custom" and fill Config.CustomNotify in shared/config.lua. It runs on the client, for every notification:
| Argument | Content |
|---|---|
title |
Title, already translated ("Doctor", "Health", "Treasury"...) |
text |
Message, already translated |
kind |
"info", "success", "warning" or "error" |
duration |
Milliseconds |
icon |
The icon the Murphy box would show ("tick", "cross", "alert", "money", "shield"...) or nil |
zone |
The zone the caller asked for ("feed", "center"...) or nil |
The shipped function sends an ox_lib notification. Examples:
If your function raises an error, the game's own notification is shown instead and the error is printed in the F8 console (Config.CustomNotify failed: ...). With "custom" but no function defined, the Murphy box is used.
Health threshold notifications
The player is warned when hunger, thirst or health gets low, and when the body temperature leaves the normal range. These settings are in shared/config_metabolism.lua:
| Setting | Effect |
|---|---|
Enabled |
false turns the hunger, thirst, health and temperature threshold warnings off. The "you feel cold / hot" messages of the temperature system still show (they only use ThresholdCooldown and Labels.Temperature) |
ThresholdCooldown |
Minimum time, in seconds, between two warnings of the same kind and level |
Thresholds.Hunger / Thirst / Health |
Percent: a low warning below low, a critical one below critical. A warning is shown when the level changes, never repeated while it stays the same |
Thresholds.Temperature |
Body temperature (°C) below cold or above hot |
Labels |
Optional texts replacing those of the language files, for example Labels.Hunger = { low = "...", critical = "..." }. Temperature accepts feeling_cold, cold, feeling_hot, hot |
The health warning is never shown while the player is dead or in a coma. The default texts are in the metabolism block of the language files (Localization).
From the server and from other resources
The server sends notifications as language keys, which each client translates, so they follow Config.Locale. Your own resources can use the same channel:
The event arguments are (kind, message, duration, icon, zone); only the first two are required. The title is always the localized "Doctor" title.
On the client, exports.murphy_doctor:Notify(title, message, kind, duration, icon, localeKey, zone) shows a notification with your own title, through the same style. The other notification exports are listed on Client exports.
Last updated: November 20, 2026