Immersion

ShadowDeathScreen

An immersive death flow: agony, a styled screen with a countdown, an EMS call and revival by medics.

Version
1.1.0
Resource
SF-DeathScreen
Version 1.1.0 Resource SF-DeathScreen Frameworks ESX ยท QBCore ยท QBX ยท Standalone Bundled languages 5 Store page View

Overview#

SF-DeathScreen replaces the moment a player dies with something worth playing. The world drains to black and white, blurs, and a heartbeat rises while the countdown runs. The player stays in the scene and can still roleplay: pressing E calls the medics, pressing G respawns at the nearest hospital once the timer is out. Exports let it sit underneath the ambulance script you already run, rather than replace it.

Agony screen

The player collapses and the screen shows the cause of death alongside the countdown.

Visual effects

Black and white, blur, ragdoll and a heartbeat whose volume and interval you set.

Roleplay while downed

The player keeps the use of /me during agony, so the scene continues.

Calling the medics

Pressing E alerts every EMS on duty and drops a blip on the body, with a cooldown.

Hospital respawn

Pressing G respawns at the nearest configured hospital once the timer is out, against medical fees.

Free EMS revival

A medic revives at any moment and at no cost, with no waiting on the timer.

Detection on three paths

The game damage event, the framework announcement and a safety watch. The first to answer wins.

Five languages

French, English, Spanish, German and Italian, in files that stay editable after escrow.

Dependencies#

ResourceRequiredWhy
ox_libYesInterface and notifications, declared in the manifest.
es_extended / qb-core / qbx_coreNoDetected at startup. Without one, the resource runs standalone and skips the job checks.

Installation#

  1. Disable the death screen of your ambulance script first, or stop that resource if it only served that purpose.
  2. Drop the SF-DeathScreen folder into your server resources directory.
  3. Add the ensure lines below to your server.cfg, after ox_lib and your framework.
  4. Set Config.Hospitals with your respawn points and Config.EmsJobs with your medical jobs.
  5. Check Config.AdminGroups so your staff can use /revive me.
  6. Run refresh, then restart SF-DeathScreen. A restart alone does not re-read the manifest.
server.cfg
ensure ox_lib
ensure SF-DeathScreen

# Optional: grant the revive permission by ACE rather than by framework rank
add_ace group.admin sf.revive allow

Configuration#

KeyDefaultWhat it does
Config.EnabledtrueTurns the whole death flow off without uninstalling the resource.
Config.DisableFrameworkDeathtrueBlocks the game automatic respawn so the agony screen has time to appear.
Config.RespawnTimer300Seconds before the player may respawn at hospital.
Config.RespawnCostโ€”Medical fee charged on respawn, taken server-side.
Config.EmsJobsโ€”Jobs treated as medical staff.
Config.AdminGroupsโ€”Framework ranks allowed to use /revive me.
Config.Hospitalsโ€”Respawn points. The nearest one is chosen.
Config.Effectsโ€”Black and white, blur, ragdoll, heartbeat volume and interval.
Config.EmsAlertโ€”Blip, display duration and call cooldown.
Config.ExtraDeathEventsโ€”Additional death events specific to your server.
Config.Localefrfr ยท en ยท es ยท de ยท it

Commands#

CommandWhoWhat it does
/reviveEMSRevives the nearest downed player, within five metres.
/revive <id>EMSRevives that player, within five metres.
/revive <id>AdminRevives at any distance.
/revive meAdminRevives yourself.
revive <id>ConsoleFrom the server console.
/sf_death_debugAdminLists downed players and the current configuration.
/deathtestโ€”Forces the screen without dying. Only when Config.Debug is true.

Staff are recognised either by ACE permission โ€” sf.revive, group.admin โ€” or by their framework rank listed in Config.AdminGroups. Most ESX servers declare no ACE at all, so both paths are accepted.

Exports#

Three server exports let your ambulance script read and drive the downed state.

server
exports['SF-DeathScreen']:IsPlayerDowned(source)   --> boolean
exports['SF-DeathScreen']:RevivePlayer(source)     --> boolean
exports['SF-DeathScreen']:GetDownedPlayers()       --> { { source, elapsed, coords, cause, called } }

Good to know#

Most servers already run a death screen โ€” esx_ambulancejob, qb-ambulancejob, wasabi_ambulance and others. Two death screens at once will fight each other. Disable theirs before enabling this one, usually through an option along the lines of Config.DeathScreen = false.
Death is detected on three independent paths on purpose. Many frameworks pick a player back up so quickly that a polling watch alone never sees them dead โ€” the damage event and the framework announcement catch what the watch would miss.
The countdown is held by the server, in downedAt. No client can shorten its own respawn. The elapsed time and the money are both checked before respawn, and the medical fee is taken server-side beforehand.
After editing any file, run refresh then restart SF-DeathScreen. A restart on its own does not re-read the fxmanifest.