Drug&Breathaylser
1. Import sql/install.sql. 2. Add inventory images matching the three item image names in Core shared items. 3. Start this resource after core, inventory, logs, oxmysql and statuseffects. 4. Configure police jobs, limits, durations, commands and equipment in config.lua. Officers can use the equipment items or /roadside, /breathtest and /drugtest. The subject must consent. Results are calculated by the server from VCORE status effects and registered substance exposures; players cannot type their own result. Drug-producing or consumable resources can call the server exports AddSubstanceExposure(source, substance, level, duration) and AddAlcoholExposure(source, micrograms, duration). Only resources listed in Config.Exposure.allowedResources may record exposure.
Introduction
1. Import sql/install.sql. 2. Add inventory images matching the three item image names in Core shared items. 3. Start this resource after core, inventory, logs, oxmysql and statuseffects. 4. Configure police jobs, limits, durations, commands and equipment in config.lua. Officers can use the equipment items or /roadside, /breathtest and /drugtest. The subject must consent. Results are calculated by the server from VCORE status effects and registered substance exposures; players cannot type their own result. Drug-producing or consumable resources can call the server exports AddSubstanceExposure(source, substance, level, duration) and AddAlcoholExposure(source, micrograms, duration). Only resources listed in Config.Exposure.allowedResources may record exposure.
UI page: html/index.html
Dependencies & References
| Resource | Detected as | Package status |
|---|---|---|
core | Manifest dependency | Included in Base |
inventory | Manifest dependency | Included in Base |
logs | Manifest dependency | Included in Base |
oxmysql | Manifest dependency | External / prerequisite |
statuseffects | Manifest dependency | Included in Base |
Cross-resource export calls
| Resource | Functions called |
|---|---|
core | getCoreObject |
inventory | AddItem, GetItemAmount |
logs | Log |
statuseffects | GetStatusEffectValue |
Installation / Start Order
The updated server.cfg explicitly classifies Drug&Breathaylser under Addons and extras. It is optional and is not started by default.
ensure Drug&BreathaylserKeep the addon after its required framework dependencies. Global Vcore prerequisites and database setup are documented in Getting Started.
Configuration
Config files
config.lua
Top-level config keys detected
CommandsConsentTimeoutDebugExposureGiveResultItemItemsMaxDistancePoliceJobsRequestCooldownSubstancesTestsEvents, Exports & Callbacks
Exports
Client exports2
StartBreathTestStartDrugTest
Server exports4
AddAlcoholExposureAddSubstanceExposureClearSubstanceExposureGetRoadsideTest
Callbacks
No Vcore callback registrations were detected.
Registered network events
Client registered events8
vcore_roadside:client:beginOfficervcore_roadside:client:beginSubjectvcore_roadside:client:consentvcore_roadside:client:endTestvcore_roadside:client:notifyvcore_roadside:client:resultvcore_roadside:client:showReportvcore_roadside:client:use
Server registered events3
vcore_roadside:server:completevcore_roadside:server:consentvcore_roadside:server:request
Commands
No commands were detected.
Database / SQL
| File | Type |
|---|---|
sql/install.sql | Resource SQL file |
vcore_roadside_testsThe root Base package also ships the consolidated VCORE_INSTALL.sql.
Source Layout
| Area | Detected files |
|---|---|
| Client Lua | 1 |
| Server Lua | 1 |
| Other/shared Lua | 2 |
| JavaScript | 1 |
| HTML | 1 |
| CSS | 1 |
| SQL | 1 |
Troubleshooting
- Confirm all manifest dependencies are started before
Drug&Breathaylser. - This addon is intentionally commented out in the supplied server.cfg. Enable it only after its dependencies are installed.
- If database queries fail, import the consolidated Base SQL and any resource-local SQL listed above.
- If the UI fails, verify the resource's NUI files and
ui_pagewhen one is declared.

