Installation Guide

Generic install hub for oxide-ems, with per-framework guides for item registration and legacy ambulance-job removal.

Generic install hub for oxide-ems. For framework-specific item registration and legacy ambulance-job removal, see the per-framework guides linked at the bottom. Follow this page first, then the guide for your framework.

Prerequisites

Required resources

ResourcePurpose
ox_libLocale, callbacks, keybinds, UI helpers
oxmysqlDatabase persistence
o-linkFramework abstraction (character, job, money, inventory, notify, target, medical, death, dispatch, banking, clothing, placement)
oxide-medicalThe medical record — blood types, injuries, illnesses, fractures and vitals. Ships alongside oxide-ems
ResourcePurpose
oxide-dispatchDelivers EMS alerts to a dispatch board. Without it, alerts still page on-duty medics directly, but automatic down and death alerts go nowhere
oxide-bankingDepartment treasury accounts, and the invoices patients receive for revives and treatment
oxide-radioRuns the radio that department channels are registered into
g-multijobMirrors hires, fires and promotions into the in-game multi-job menu

What oxide-medical is for

oxide-medical is where a player's medical condition actually lives — the broken bones, the bleeding, the illnesses, the blood type, and the vitals feed behind the pulse and blood-pressure readouts. oxide-ems is the job that acts on that record: the examine overlay reads it, treatment and surgery cure entries in it, x-ray scans filter it down to fractures and retained bullets, and triage decides who counts as critical from the severity of what is in it.

The two ship together and are installed together. If oxide-medical is not running, medics can still clock in, revive, stabilize, transport and bed patients — but examine reports nothing to find, treatments refuse with "the medical system is not available", and x-ray scans come back empty.

This resource depends on your server's o-link setup for:

  • player-ready and player-unload lifecycle events
  • character identifier and name
  • job assignment and duty state
  • money operations (bank fees, salaries, payouts)
  • inventory reads, writes, stash registration, item images and the item registry
  • notifications and progress bars
  • entity and player targeting (clock-in, beds, lockers, patients, vehicles)
  • callback transport through olink.callback
  • the medical record (olink.medical) — conditions, vitals, treatment
  • the death lifecycle (olink.death) — downed and dead state, revives, hospital respawn points
  • dispatch alerts (delivered when oxide-dispatch is the provider)
  • banking accounts and invoices (when oxide-banking is started)
  • clothing (uniform application and reverting to civilian clothes)
  • in-world placement (olink.placement) for the admin picker previews and the two in-world screens

Installation

Place the resource

Place oxide-ems inside your server's resources folder.

Disable the ambulance job that came with your framework

Do not run qb-ambulancejob, esx_ambulancejob or qbx_ambulancejob alongside oxide-ems. See the per-framework guides for the exact steps.

oxide-ems declares provide 'qb-ambulancejob' so that scripts checking whether that resource exists keep working after it is removed.

Qbox is the exception in one respect: leave qbx_medical running. On Qbox, qbx_medical remains in charge of the downed and dead state, and oxide-ems layers the ambulance job on top of it. Only qbx_ambulancejob is removed.

Add startup order

Start dependencies before the resource:

server.cfg
ensure ox_lib
ensure oxmysql
ensure o-link
ensure oxide-medical
ensure oxide-banking    # optional — treasury accounts and patient invoices
ensure oxide-dispatch   # optional — delivers EMS alerts to a dispatch board
ensure oxide-radio      # optional — department radio channels
ensure oxide-ems

o-link must start before oxide-ems. If a required resource is missing, oxide-ems prints an error in the server console naming exactly which one and refuses to initialise.

Install the SQL tables

Run sql/install.sql against your database.

The install creates tables for departments, facilities (with their placed interaction points), grades, medics, garages, the vehicle fleet, uniforms, radio channels, the supply shop catalog, treasury transactions and unpaid payroll. It also creates the shared oxide_settings table, which is where your settings live once the server has booted once.

If you are upgrading from an earlier pre-release build, run the migration files from sql/migrations/ in order — and only the ones you have not run before. Run each migration once; re-running an ADD COLUMN migration on a database that already has the column will error harmlessly:

MigrationAdds
0001_xray.sqlX-ray machine points on facilities
0002_uniforms.sqlThe uniforms table
0003_surgery.sqlOperating table points on facilities
0004_blip_label_scale.sqlCustom map blip name and size per facility
0005_radio_channels.sqlThe department radio channels table

Fresh installs only need install.sql — it already includes everything the migrations add.

Do not run sql/reset.sql unless you intentionally want to drop every Oxide EMS table.

Register items

Register these item names in the inventory system behind your o-link.inventory adapter. Item registration syntax is framework-specific — see the per-framework guides for copy-paste examples.

ItemPurposeImage
medical_bagUsable kit that unpacks into field supplies and is consumedmedical_bag.png
medical_bandageConsumed when treating a gunshot wound or a lacerationmedical_bandage.png
medical_splintFracture supply. Not consumed by any default treatment — add it to a treatment in /ems settings if you want it usedmedical_splint.png
medical_surgical_kitConsumed when operating on a retained bulletmedical_surgical_kit.png

These four are the items oxide-ems itself looks for. Images for all four ship in itemimages/, along with antacid.png, antibiotics.png and antiviral.png for the oxide-medical cure items.

The revive and stabilize item. Medics need one item to revive or stabilize a patient. By default this is your framework's existing first-aid item — firstaid on QBCore and Qbox, medikit on ESX — so on a stock server there is nothing extra to register. Change it (or remove the requirement) under Field Care in /ems settings.

The medical bag's default contents. Using a medical_bag unpacks it into:

ItemCountWhere it comes from
medical_bandage5oxide-ems
medical_splint2oxide-ems
medical_surgical_kit1oxide-ems
antibiotics2oxide-medical
antiviral2oxide-medical
antacid2oxide-medical
painkillers2stock on QBCore, ESX and Qbox
bandage5stock on QBCore, ESX and Qbox
your first-aid item1firstaid on QBCore and Qbox, medikit on ESX — worked out automatically

The last row is not a fixed name. With Include first-aid item switched on (the default), the bag adds whichever first-aid item your framework already ships, so the same default list works everywhere. Turn it off under General → Medical bag in /ems settings if you would rather list one yourself.

Anything in that list your inventory does not recognise simply won't be handed over, and the medic is told some supplies didn't fit. Edit the list under General → Medical bag in /ems settings to match the items your server actually has.

Copy item images

Copy the .png files from itemimages/ into the image directory used by your inventory resource.

Common locations:

  • qb-inventory/html/images/
  • ox_inventory/web/images/

Every image file is named after its item (the medical_bag item's image is medical_bag.png).

Restart the whole server

Not restart oxide-ems — a full server restart.

oxide-ems streams the stretcher prop, and streamed props are registered when the server starts. Restarting only the resource leaves the stretcher invisible or missing for everyone who was already connected. This applies to the first install and to any future update that changes the streamed files.

Review configuration

Almost nothing in oxide-ems is configured in files. On first boot, the values in shared/config.lua and shared/config/ are copied into the oxide_settings database table, and from then on the database is what the server reads. Edit settings in-game with /ems settings, where changes save and apply immediately.

The config files remain useful for two things: they seed a fresh install, and they are the "reset to default" target in the settings editor.

The full per-setting reference is in Configuration.

Everything else — departments, facilities, interaction points, grades, garages, the fleet, uniforms, radio channels and the supply shop catalog — is created in-game through /ems admin and stored in the database. There is no list of hospitals to edit.

Make sure your admins can use the admin tools

The admin panel (/ems admin), the settings editor (/ems settings) and the admin commands are for your server admins — the people you already trust to run admin tools. A player counts as an admin if they are in a group that has the admin permission.

If you have already set up admins for other Oxide resources (or for txAdmin), you are done — they can use these tools too, with nothing extra to add.

If you have not set up an admin group yet, add these two lines to your server.cfg (the text file that holds your server's settings). Replace the licence with your own:

server.cfg
# 1. Put your account in the "admin" group
add_principal identifier.license:abc123 group.admin

# 2. Give the "admin" group permission to use admin tools
add_ace group.admin admin allow

Save the file and restart your server. There is one admin level — a player either is an admin or is not — and it works the same on QBCore, ESX and Qbox.

First-time in-game setup

After the SQL is installed, items are registered and the server has fully restarted:

  1. Join the server with an admin account.
  2. Run /ems admin to open the admin panel.
  3. Create a department. The department's internal name must match a job in your framework (for example ambulance). The display label is what players see.
  4. Add grades. Give at least one grade the boss flag so somebody can open the management desk.
  5. Add a facility — a hospital for emergency work, or a doctor's office for walk-in appointments.
  6. Place at least a clock-in point on it. Add beds, lockers, a management desk, a supply counter, a reception desk, x-ray machines and operating tables as you want them.
  7. On a hospital, place a respawn point so players who give up respawn there.
  8. Add a garage and at least one spawn bay if you want a fleet, then add vehicles.
  9. Add supply shop items so medics have somewhere to restock.
  10. Hire a test medic with /ems hire <serverID> <deptName> <gradeRank>.
  11. Have the test medic clock in at the facility before testing anything else.

The panel shows a setup checklist per department that ticks off ranks, a facility, a clock-in point, a garage and a spawn bay as you complete them.

Step-by-step walkthrough: Admin.

Verification

Start the server and confirm ox_lib, oxmysql, o-link, oxide-medical and oxide-ems load without dependency errors. oxide-ems logs which death provider it detected on start.
Run /ems admin as an admin and create a department with at least one grade and one facility.
Hire yourself with /ems hire, then clock in at the facility's clock-in point.
Hold H and confirm a station marker card appears pointing at the facility.
Aim at another player and confirm Examine Patient appears while you are on duty.
Have a second player go down. Confirm the downed overlay appears for them, that a distress signal with G reaches you, and that Revive / Stabilize / Load Patient appear on their body.
Park an ambulance, take out the stretcher from the rear, drag it, and place the patient on it.
Check the patient into a hospital bed and confirm they are revived and healed.
Open the supply shop at a supply counter and buy an item.
Open the management desk as a boss-graded medic and confirm the roster, treasury, payroll, uniforms and fleet tabs load.
Run /ems settings, change a value, save, and confirm it takes effect without a restart.

Framework-specific setup

The steps above are generic. The exact item registration syntax and legacy ambulance-job removal steps differ per framework. The per-framework guides below cover those details and should be followed in addition to the steps on this page:

  • QBCore install guideqb-core items, disabling qb-ambulancejob, what the QBCore shim re-provides.
  • ESX install guideox_inventory items, disabling esx_ambulancejob, ESX job-table sync and society registration.
  • Qbox install guideox_inventory items, disabling qbx_ambulancejob while keeping qbx_medical.

Notes

  • The user interface is prebuilt and already included in the resource. There is nothing to build or install.
  • oxide-ems does not talk directly to framework or inventory resources. Those integrations are expected to be handled by o-link.
  • Departments, facilities, interaction points, grades, garages, the fleet, uniforms, radio channels and the supply shop catalog are all configured in-game and stored in the database, not in shared/config/.
  • Settings live in the oxide_settings database table after first boot. Editing a config file on a server that has already started once will not change anything until that setting is reset to default in /ems settings.

Next Steps