Installation Guide
Generic install hub for oxide-police, with per-framework guides for item registration, weapon registration, and legacy police resource removal.
Generic install hub for oxide-police. For framework-specific item registration, weapon registration, and legacy police resource removal, see the per-framework guides linked at the bottom.
Prerequisites
Required resources
| Resource | Purpose |
|---|---|
ox_lib | Locale, callbacks, skill checks, keybinds, UI helpers |
oxmysql | Database persistence |
o-link | Framework abstraction (character, job, money, inventory, notify, target, dispatch, banking, doorlock) |
screenshot-basic | Mugshot capture upload |
Recommended resources
| Resource | Purpose |
|---|---|
oxide-dispatch | Powers the MDT Dispatch tab. Without it, set Config.MDT.dispatchEnabled = false |
oxide-banking | Fine invoicing and treasury accounts |
pma-voice or yaca-voice | Police radio channels and megaphone voice routing |
o-link expectations
This resource depends on your server's o-link setup for:
- player-ready and player-unload lifecycle events
- character identifier, name, and metadata
- job assignment and duty state
- money operations (cash / bank, fines, salaries)
- inventory reads, writes, container registration, and item images
- notifications and helptext
- local entity targeting (clock-in, armory, garage, evidence, mugshot, jail)
- callback transport through
olink.callback - dispatch alerts (forwarded into the MDT Dispatch tab when
oxide-dispatchis the provider) - banking invoices for fines (when
oxide-bankingis started) - door lock state (optional)
Installation
Place the resource
Place oxide-police inside your server's resources folder.
Disable the legacy police resource
Do not run qb-policejob or esx_policejob alongside oxide-police. If you are using the Oxide custody system, also disable qb-prison. See the per-framework install guides for the exact disable steps.
oxide-police declares provide 'qb-policejob' so that third-party scripts that check whether a player is handcuffed through exports['qb-policejob']:IsHandcuffed() (a client-side check) keep working after the legacy resource is removed.
Add startup order
Start dependencies before the resource:
ensure ox_lib
ensure oxmysql
ensure screenshot-basic
ensure o-link
ensure oxide-banking # optional — fine invoicing and department treasury
ensure oxide-dispatch # optional — powers the MDT Dispatch tab
ensure oxide-policeo-link must start before oxide-police. The oxide-banking and oxide-dispatch lines are optional — leave them out if you do not run those resources. If you do use oxide-dispatch, start it before oxide-police so the MDT Dispatch tab works.
Install the SQL tables
Run sql/install.sql against your database.
The install creates tables for departments, stations, grades, officers, fleet, garages, armory loadouts, uniforms, radio channels, doors, MDT cases, the charge catalog, warrants, BOLOs, criminal records (including fines), mugshots, custody, prisoner job points, the prison shop, treasury transactions, unpaid payroll, the evidence registry, the weapon registry, speed cameras, CCTV cameras, bodycam recordings, and the prison revive point.
If you are upgrading an existing install, run the relevant 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 (the column already exists):
| Migration | Adds |
|---|---|
001_video_storage.sql | MDT Video Storage tab — bodycam recordings table with case attachments |
002_vehicle_type.sql | Vehicle type column for MDT vehicle records |
003_random_plates.sql | Plate-randomisation support on fleet vehicles |
004_weapon_registry.sql | Weapon registry (MDT Weapons tab) and the firearm registration desk on stations |
005_multi_department.sql | Multi-department support — lets one character be enrolled in more than one department at once (Config.AllowMultiDepartment) |
006_server_fleet_persistence.sql | Corrects the stored vehicle type on existing boat/helicopter fleet vehicles — required for persistent fleet vehicles to spawn correctly |
Fresh installs only need install.sql — install.sql already includes everything the migrations add.
Do not run sql/reset.sql unless you intentionally want to drop every Oxide Police 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.
| Item | Purpose | Image |
|---|---|---|
body_cam | Streams the wearer's POV to other officers via /bodycams | body_cam.png |
police_tablet | Opens the MDT when used. Only needed if you set Config.MDT.useItem = true — otherwise the MDT opens with /mdt and no item is required | (use any image) |
police_radio | Required to use the police radio overlay (toggle: Y) | police_radio.png |
megaphone | Handheld PA, plus vehicle PA from any fleet vehicle (B) | megaphone.png |
evidence_camera | Photographs evidence drops at a crime scene | evidence_camera.png |
breathalyzer | Reads suspect BAC from your drunk system via Config.Breathalyzer.sources | breathalyzer.png |
cctv_camera | Placeable CCTV camera, viewable through /cameras | cctv_camera.png |
prison_food_tray | Free meal handed out at the prison shop | prison_food_tray.png |
ziptie | Field-restraint applied to hands-up / restrained targets | ziptie.png |
scissors | Cuts zip ties off targets | scissors.png |
wheel_clamp | Immobilises the front-left wheel of a vehicle | wheel_clamp.png |
mouthtape | Disables pma-voice / yaca-voice on the target | mouthtape.png |
tracking_band | Live blip + GPS coords on a target every second | tracking_band.png |
headbag | Black-out overlay on the target's screen | headbag.png |
evidence_blood | Blood evidence drop spawned by Config.Evidence.types.blood | evidence_blood.png |
evidence_bullet | Bullet evidence drop spawned on weapon discharge | evidence_bullet.png |
evidence_fingerprint | Fingerprint left on objects / vehicles when target is unglued | evidence_fingerprint.png |
lockpick | Configurable lockpick used to remove cuffs (Config.FieldActions.Cuffs) | lockpick.png |
weapon_radar | Handheld speed radar (WEAPON_RADAR); must also be registered as a weapon. See the next step. | weapon_radar.png |
If you use ox_inventory (the inventory used by ESX and Qbox servers, and by some QBCore servers), open ox_inventory/data/items.lua and paste these entries into the list. These are the exact names Oxide Police looks for — do not rename them:
['body_cam'] = { label = 'Body Camera', weight = 250, stack = false, close = true },
['police_tablet'] = { label = 'Police Tablet', weight = 250, stack = false, close = true }, -- only if Config.MDT.useItem = true
['police_radio'] = { label = 'Police Radio', weight = 500, stack = false, close = true },
['megaphone'] = { label = 'Megaphone', weight = 1000, stack = false, close = true },
['evidence_camera'] = { label = 'Evidence Camera', weight = 750, stack = false, close = true },
['breathalyzer'] = { label = 'Breathalyzer', weight = 350, stack = false, close = true },
['cctv_camera'] = { label = 'CCTV Camera', weight = 1500, stack = false, close = true },
['prison_food_tray'] = { label = 'Prison Food Tray', weight = 500, stack = true, close = true },
['ziptie'] = { label = 'Zip Tie', weight = 25, stack = true, close = true },
['scissors'] = { label = 'Scissors', weight = 100, stack = false, close = true },
['wheel_clamp'] = { label = 'Wheel Clamp', weight = 2500, stack = false, close = true },
['mouthtape'] = { label = 'Mouth Tape', weight = 50, stack = true, close = true },
['tracking_band'] = { label = 'Tracking Band', weight = 100, stack = false, close = true },
['headbag'] = { label = 'Headbag', weight = 150, stack = true, close = true },
['lockpick'] = { label = 'Lockpick', weight = 100, stack = true, close = true },
['evidence_blood'] = { label = 'Blood Evidence', weight = 50, stack = false, close = false },
['evidence_bullet'] = { label = 'Bullet Evidence', weight = 25, stack = false, close = false },
['evidence_fingerprint'] = { label = 'Fingerprint Evidence', weight = 25, stack = false, close = false },The handheld radar (WEAPON_RADAR) is a weapon, so it goes in ox_inventory/data/weapons.lua instead — see the next step. After saving, restart ox_inventory (or your server).
If you use qb-inventory (common on QBCore), the syntax is different — see the QBCore install guide for copy-paste entries.
Register the handheld speed radar weapon
oxide-police ships a streamed addon weapon (WEAPON_RADAR) for the handheld speed radar. The model files (w_pi_radar.ydr, w_pi_radar.ytd) and weapon meta files (weapons.meta, weaponarchetypes.meta, weaponanimations.meta, pedpersonality.meta) are streamed automatically from oxide-police/stream/.
You also need to register the weapon as an inventory item for your framework so officers can equip it from an armory loadout. The exact item / weapon-table syntax differs per framework — see the per-framework guides.
The handheld radar only activates when the officer equips WEAPON_RADAR and is on duty. The vehicle radar is independent: vehicles in your fleet must have has_radar enabled (set per fleet entry in /padmin).
Copy item images
Copy the .png files from items/ 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 body_cam item's image is body_cam.png).
Review configuration
Adjust these files to fit your server:
shared/config.lua— global settings: salary interval, treasury mode, door hotkey, radar / speedcam unitsshared/config/charges.lua— pre-loaded charges catalog (100 entries)shared/config/mdt.lua— MDT permissions, warrant / BOLO defaults, fine capsshared/config/custody.lua— jail uniform, locker stash size, prison revive cutsceneshared/config/interactions.lua— cuffing, escort, search, tackle, hands-up, carryshared/config/field_actions.lua— tickets, cuffs / lockpick, ziptie, headbag, station servicesshared/config/field_tools.lua— wheel clamp, mouth tape, tracking band, impoundshared/config/evidence.lua— evidence types, weapon ballistics, registrable items, GSRshared/config/fleet_catalog.lua— vehicles offered in the fleet managershared/config/breathalyzer.lua— drunk-resource integration sourcesshared/config/bodycam.lua/shared/config/cctv.lua— viewer settingsshared/config/radio.lua/shared/config/megaphone.lua— voice toolsshared/config/mugshot.lua— mugshot upload endpoint and webhookshared/config/prisonerjobs.lua/shared/config/prisonshop.lua— prison economyshared/config/objects.lua— placeable scene propsshared/config/compat.lua— QBCore / ESX / Qbox compatibility shims
Full per-key reference: Configuration.
Make sure your admins can use the admin tools
The admin panel (/padmin) 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 standard 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 (replace the licence with your own):
# 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 allowSave 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.
Set up media uploads (FiveManage)
Mugshots and bodycam clips are saved to the cloud through a service called FiveManage, using a single key set in your server.cfg (the text file that holds your server's settings). The same key also powers bait car dashcam clips if you run oxide-baitcar.
The short version: create a free FiveManage account, make a Media token, and add it to server.cfg:
set FIVEMANAGE_MEDIA_API_KEY "your_key_here"Then restart your server. For the full step-by-step walkthrough (account, team, token, where to paste it), see Setting up FiveManage media uploads.
If you skip this, mugshots and bodycam recordings will not upload, but the rest of the resource works normally.
First-time in-game setup
After SQL is installed, items registered, and the server is running:
- Join the server with an admin account.
- Run
/padminto open the admin panel. - Create a department. The department
namemust match a job in your framework (e.g.police,lspd,bcso). - Add grades that match your framework's job grades.
- Add at least one station with a clock-in point.
- Add radio channels if using the police radio.
- Add a garage and at least one vehicle to the fleet if testing fleet features.
- Add custody / prison points if testing the jail flow.
- Hire a test officer with
/phire <serverID> <deptName> <gradeRank>. - Have the test officer clock in at the station before testing dispatch, MDT, evidence, fleet, or prison.
Verification
ox_lib, oxmysql, o-link, screenshot-basic, and oxide-police load without dependency errors./padmin as an admin and create / verify a department./phire, clock in at a station, and confirm /mdt opens.WEAPON_RADAR, equip it, aim at a vehicle, and confirm the radar overlay appears.K) works from inside it./padmin → Detention Mugshot, place the camera and photo points, and use the Preview button to check the framing. Preview only shows the shot — it does not take or upload a photo. To confirm uploads actually work, book a test suspect and take a real mugshot (requires screenshot-basic and the FiveManage key — see Set up media uploads)./bodycams and /cameras to confirm the viewers open.Framework-specific setup
The steps above are generic. The exact item registration syntax, weapon registration, and legacy police resource disable steps differ per framework. The per-framework guides below cover those details and are accurate for their respective stacks — they should be followed in addition to the steps on this page:
- QBCore install guide —
qb-coreitems / weapons, disablingqb-policejobandqb-prison, QB compatibility shim coverage. - ESX install guide —
ox_inventoryitems / weapons, disablingesx_policejob, ESX job sync setup. - Qbox install guide —
qbx_core+ox_inventoryitems / weapons, Qbox-specific notes.
Notes
- The user interface is prebuilt and already included in the resource. There is nothing to build or install.
oxide-policedoes not talk directly to framework or inventory resources. Those integrations are expected to be handled byo-link.- Departments, stations, garages, armory loadouts, uniforms, radio channels, prison points, and speed cameras are all configured in-game through
/padmin, and the charge catalog through the MDT — they are stored in the database, not inshared/config/.