HZ-Bridge
Overview
HZ-Bridge is the shared foundation used by all Hz-Scripts resources. It automatically detects your server environment and provides a unified API so that every Hz-Script works out of the box, regardless of your framework or addon combination.Free asset — HZ-Bridge is available for free on the Hz-Scripts shop. Download it once and all compatible scripts will use it automatically.
What does it do?
Instead of each script including its own framework detection and adapter code, HZ-Bridge handles it centrally:
| Module | What it detects |
|---|---|
| Framework | ESX, QBCore, QBox, Ox Core, vRP, Standalone |
| Inventory | ox\_inventory, qs-inventory, ps-inventory, codem, core, origen, tgiann, framework |
| Notifications | ox\_lib, okokNotify, mythic\_notify, codem, pNotify, framework, GTA native |
| Target | ox\_target, qb-target, interact, built-in TextUI |
| Menu / UI | ox\_lib (full), qb-menu + qb-input, ESX menu, GTA native fallback |
| Dispatch | cd\_dispatch, ps-dispatch, qs-dispatch, rcore\_dispatch, emergencydispatch, built-in |
| Callbacks | Bidirectional (client-server) with rate limiting & timeout |
| Minigames | Progress bar, skill check, sequence |
/hzpanel) — every HZ-Script module declares its config schema, and the panel auto-builds a typed in-game editor so you tweak everything without touching files or restarting. See Admin Panel.
Key Benefits
- Install once — All Hz-Scripts share the same bridge, no duplicate code
- Auto-detection — Leave everything on
'auto'and HZ-Bridge figures out your setup - Override when needed — Force a specific system in one config file
- 60+ exports — Use the bridge from your own scripts too
- Centralised admin UI —
/hzpanelopens one panel for every HZ-Script module (more) - Unified theme — change accent, surfaces, radius scale in one place, every HZ NUI retints live
- Zero performance cost — Detection runs once at startup, exports are instant
Supported Systems
Frameworks
| Framework | Resource | Status |
|---|---|---|
| ESX | es_extended | Full |
| QBCore | qb-core | Full |
| QBox | qbx_core | Full |
| Ox Core | ox_core | Full |
| vRP | vRP | Full |
| Standalone | — | Full |
Inventories
| Inventory | Resource | Status |
|---|---|---|
| ox\_inventory | ox_inventory | Full |
| qs-inventory | qs-inventory | Full |
| ps-inventory | ps-inventory | Full |
| codem-inventory | codem-inventory | Full |
| core\_inventory | core_inventory | Full |
| origen\_inventory | origen_inventory | Full |
| tgiann-inventory | tgiann-inventory | Full |
| Framework native | — | Basic |
Menu Systems
| Menu System | Resource | Features |
|---|---|---|
| ox\_lib | ox_lib | Context, Input, Alert, TextUI, Progress, List menu |
| qb-menu | qb-menu | Context, Input (via qb-input), TextUI (via qb-core) |
| ESX menu | esx_menu_default | Context, List menu, TextUI (via esx\_textui) |
| Native | — | GTA keyboard input, help text, basic fallback |
Quick Start
- Download HZ-Bridge from the shop (free)
- Place it in your
resources/folder - Add
ensure HZ-Bridgeto yourserver.cfgbefore any Hz-Script - Done — all Hz-Scripts will auto-detect it
For Developers
HZ-Bridge exposes 60+ exports that you can use from your own scripts:
-- Framework
local job = exports['HZ-Bridge']:GetPlayerJob()
-- Notifications
exports['HZ-Bridge']:Notify('Hello!', 'success', 3000)
-- Inventory (server)
exports['HZ-Bridge']:AddItem(source, 'bread', 5)
-- Menu (client)
exports['HZ-Bridge']:ContextMenu('my_menu', 'My Menu', {
{ title = 'Option 1', onSelect = function() print('selected') end },
})
-- Callbacks
exports['HZ-Bridge']:RegisterCallback('myResource:getData', function(source)
return { money = 1000 }
end)
See the full Exports & API reference.
