gta6/prompts
medical
Vaultintermediatemedical

Hospital Admission — Bed & Ward Management

Assign admitted patients to numbered hospital beds/wards with server-owned live occupancy and a discharge step that frees the bed.

NON-TESTÉ — the reference Lua is syntax-validated, not run in a live FiveM server. Adapt and test on your own dev server before shipping.
Est. Lua
~91 loc
Claude
Claude Opus 4.x / Sonnet 4.x
Validation
syntax-validated
Updated
2026-06-25

Description

Admit a patient to the lowest free numbered bed in a ward, teleport and lay them down, track live occupancy server-side, and discharge them to free the slot. It is a standard part of every ambulance job, so servers buy a clean standalone version to get reliable, conflict-free ward management without dragging in a whole EMS overhaul.

Prompt Template

You are writing a FiveM resource for a roleplay server. Detect the framework via…

🔒 Eyes-only — locked prompt body

The full prompt template and its reference Lua are part of a one-time pack. Pick your depth — both are lifetime access, no subscription, ever.

Core$49one-time
  • 60 prompts + syntax-validated reference Lua
  • Lifetime access — pay once
Most Popular · Best Value
Vault$199one-time
  • All 510 prompts — the full library
  • Per-prompt profit/trend intelligence (CSV + playbook)
  • Lifetime free updates — new niches as the market moves
Get the Vault — $199

$49 for 60 · $199 for all 510 + intelligence — one-time, no subscription.

Expected Output

See content/expected-outputs/medical/10-hospital-bed-admission.lua. It owns a…

🔒 Eyes-only — locked prompt body

The full prompt template and its reference Lua are part of a one-time pack. Pick your depth — both are lifetime access, no subscription, ever.

Core$49one-time
  • 60 prompts + syntax-validated reference Lua
  • Lifetime access — pay once
Most Popular · Best Value
Vault$199one-time
  • All 510 prompts — the full library
  • Per-prompt profit/trend intelligence (CSV + playbook)
  • Lifetime free updates — new niches as the market moves
Get the Vault — $199

$49 for 60 · $199 for all 510 + intelligence — one-time, no subscription.

Known Failure Modes & Corrective Prompt

  • Client-tracked occupancy — two medics double-book a bed and the count drifts. Occupancy must live only in the server's beds table.
  • Teleport before confirmation — moving the patient before the server picks a free bed strands them on a full ward. Assign server-side first, then teleport.
  • Round-trip via TriggerEvent — assigned/discharged messages never cross without RegisterNetEvent + AddEventHandler.

Corrective re-prompt: "Make the server the only owner of bed state. On admit, pick the bed with firstFreeBed() BEFORE any teleport; only after claiming it TriggerClientEvent medical:bed:assigned on the patient. Reject admission with a 'ward full' notify when no bed is free."

Framework Integration

  • ESX: gate admission behind the ambulance job via exports["es_extended"]:getSharedObject() and resolve the patient with ESX.GetPlayerFromId.
  • QBCore: check QBCore.Functions.GetPlayer(src).PlayerData.job.name and pair occupancy with a qb-menu ward board.
  • QBox: use exports.qbx_core:GetPlayer(src) for the job gate and drive the ward UI with ox_lib menus; the beds table maps directly to slots.

Profit Potential

$150–$2000/mo on Tebex (expected ~$500). [INFERRED] priced inside the $50-389 script band against the signal-scraper tebex corpus (median seller $11.85K/mo, n=100); a stable utility with steady, low-churn demand.

Trend Signal

stable — corpus: Bed/ward admission is a standard module inside ambulance jobs (qb-ambulancejob hospital check-in); stable, steady demand.

Sales Angle

Position as the clean, standalone ward manager any hospital can drop in. Recommended Tebex price $129.

Difficulty & Ship Time

intermediate · ships in 2-4h.