Dependencies

3 min readUpdated 2 weeks ago

Required

ML HealthSystem declares three hard dependencies in fxmanifest.lua. The resource will not start if any are missing.

  • ml_bridge: Framework abstraction layer. Resolves player data, inventory operations, notifications, and usable-item binding without framework-specific exports.
  • ox_lib: Callbacks, zones, context menus, and notifications.
  • oxmysql: MySQL driver. Used for the three persistence tables (ml_healthsystem, ml_lifepoints, ml_health_tents).
fxmanifest.lua
1dependencies {
2    'ox_lib',
3    'oxmysql',
4    'ml_bridge',
5}

Framework

ml_bridge supports QBCore, Qbox, ESX, and standalone. Pick the matching tab and add the ensure block to server.cfg. Load order matters: ml_bridge must start after the framework core and before ml_healthsystem.

server.cfg
1ensure qb-core
2ensure oxmysql
3ensure ox_lib
4ensure ml_bridge
5ensure ml_healthsystem
server.cfg
1ensure qbx_core
2ensure oxmysql
3ensure ox_lib
4ensure ml_bridge
5ensure ml_healthsystem
server.cfg
1ensure es_extended
2ensure oxmysql
3ensure ox_lib
4ensure ml_bridge
5ensure ml_healthsystem
server.cfg
1ensure oxmysql
2ensure ox_lib
3ensure ml_bridge
4ensure ml_healthsystem
Auto Detection

ml_bridge detects the running framework at startup. ML HealthSystem has no separate framework setting.

Inventory

Item use, removal and metadata route through ml_bridge. The shipped definitions target ox_inventory: copy the medical items and respawn_tent from _INSTALL/ox_items.txt into ox_inventory/data/items.lua. Include zombie_antidote if you enable the optional zombie cure. Keys must match Config.MedicalItems, Config.RespawnTent.Item and Config.ZombieTransformation.Cure.Item. The script binds item use through ML Bridge.

Item key parity

Renaming an item in ox_inventory/data/items.lua without updating the matching key in shared/config/items.lua (or shared/config/respawn.lua for the tent) breaks the bind. The item will exist in the inventory but do nothing on use.

Database

oxmysql is required for the persistence tables. The resource creates each enabled table on first start with CREATE TABLE IF NOT EXISTS:

  • ml_healthsystem: aggregated medical state per identifier (health_data LONGTEXT). Live injuries, bleeding, fractures, and diseases are tracked in real time during a session; this table is the persistence layer that survives disconnects and restarts.
  • ml_lifepoints: Life Points balance per identifier. Created only when Config.LifePoints.Enabled is true.
  • ml_health_tents: placed respawn tents (coords, heading, optional label).

No manual SQL import is needed.

Optional

  • pma-voice: Proximity voice muting on death and last stand. Controlled by Config.Voice in shared/config/effects.lua (Enable, System = 'pma-voice', MuteDead, MuteLastStand). Leave Config.Voice.Enable = false to skip it.

Player zombie transformation runs within ML Health System and has no NPC zombie resource dependency. Original ped mode needs no appearance provider. Optional model switching requires a model installed on your server and an appearance provider that captures and restores the complete character. Other inventories need a registered provider if they do not support the built-in ox_inventory lock flags. Provider contracts and targeting exports are in the Developer guide.

Transformation state is saved in the existing ml_healthsystem.health_data data; no additional SQL table or manual migration is needed.

Health System Dependencies, FiveM Docs | Micio Mods