Bridges
Everything in bridge/ is open. Integrations are detected automatically when kartik-ers starts.
bridge/
├── framework/ client + server: qbx.lua, qb.lua, esx.lua
├── mdt/ server: kartik-mdt.lua, imperialcad.lua
├── dispatch/ server: kartik-mdt.lua, ps-dispatch.lua, cd_dispatch.lua, imperialcad.lua
├── notifications/ client: built-in, ox_lib, qb, esx
└── progress/ client: built-in, ox_lib, qb (progressbar), esx (esx_progressbar)Framework
Each framework file starts with:
if not detectCore('qbx_core') then return enddetectCore matches the real resource name, so Qbox is never mistaken for qb-core. The bridge fills Bridge.Framework with player, job, duty and money helpers.
MDT and dispatch
MDT and dispatch files check that their resource is started, then fill Bridge.MDT and Bridge.Dispatch. Kartik MDT is preferred over ps-dispatch and cd_dispatch when more than one runs.
Imperial CAD works on top of whichever MDT or dispatch is running: calls and NPC records go to both. See Imperial CAD.
Without an MDT, ERS still works: records live in its own tables and the tablet's Records page, but nothing is pushed to an MDT.
Notifications and progress bars
Picked with Config.Notify and Config.Progress. To use another script, add a branch to bridge/notifications/client/client.lua or bridge/progress/client/client.lua:
elseif Config.Notify == 'mythic' then
exports['mythic_notify']:DoHudText(notifyType, message)Adding a bridge
- Copy the closest existing file, for example
bridge/dispatch/server/ps-dispatch.lua. - Change the resource name in the start check and the export calls.
- Start that resource before kartik-ers in
server.cfg.