Dependencies & Load Order

Here’s a cleaned-up and professional version of your GitHub documentation section regarding dependencies and load order for ps_lib:


Dependencies & Load Order

While ps_lib has no hard dependencies, load order is still important to ensure proper functionality.

We recommend starting ps_lib after the following types of scripts:

  1. Frameworks – such as qb-core, es_extended, or qbx_core

  2. Inventory Systems – such as qb-inventory, ps-inventory, or ox_inventory

  3. Target Systems – such as qb-target, ox_target, or devyn-interact

  4. Emote Menus – such as rpemotes, dpemotes, or scully_emotes

Why this order matters

Loading these scripts first ensures that ps_lib can correctly reference and initialize all the necessary resources and exports. There is a fallback system in place if ps_lib is loaded later (except in the case of the framework), but for the smoothest experience, it's strongly advised to follow the recommended load order.

Additionally, ps_lib must be loaded before any scripts that depend on it.


Example Load Order

ensure qb-core
ensure qb-target
ensure qb-inventory
ensure rpemotes
ensure ps_lib
ensure ps-dispatch

Last updated