Skip to content

Setup and Items

Quick installation guide and required item setup for 0r-drug-business

This page covers the minimum setup required to get the script running correctly: dependencies, server.cfg start order, database import, and required items.

Required Dependencies#

lua
start oxmysql
start ox_lib
start framework -- es_extended, qb-core, or qbx_core
-- other resources
start 0r-drugbusiness

Database#

Import this file manually:

lua
0r-drugbusiness/database.sql

The script creates these tables:

sql
CREATE TABLE IF NOT EXISTS `0r_drugbusiness_warehouses` (...);
CREATE TABLE IF NOT EXISTS `0r_drugbusiness_warehouse_logs` (...);

This resource does not auto-run the SQL file from fxmanifest.lua. Import it yourself before testing the script.

Required Items#

These item names are used directly in config.lua:

  • lockpick
  • packaged_weed
  • packaged_cocaine
  • packaged_meth

If your server already has lockpick, you only need to add the packaged product items.

OX Inventory Example#

{% tabs fullWidth="false" %}

lua
["packaged_weed"] = { label = "Packaged Weed", weight = 100, stack = true },
["packaged_cocaine"] = { label = "Packaged Cocaine", weight = 100, stack = true },
["packaged_meth"] = { label = "Packaged Meth", weight = 100, stack = true },

QB Core Example#

{% tabs fullWidth="false" %}

lua
packaged_weed = { name = "packaged_weed", label = "Packaged Weed", weight = 100, type = "item", image = "packaged_weed.png", unique = false, useable = false, shouldClose = false },
packaged_cocaine = { name = "packaged_cocaine", label = "Packaged Cocaine", weight = 100, type = "item", image = "packaged_cocaine.png", unique = false, useable = false, shouldClose = false },
packaged_meth = { name = "packaged_meth", label = "Packaged Meth", weight = 100, type = "item", image = "packaged_meth.png", unique = false, useable = false, shouldClose = false },

Money Setup#

By default:

  • Config.CleanMoney uses account money
  • Config.DirtyMoney uses black_money

If you change either section to isItem = true, you must also add those money items to your inventory system.

Final Checklist#

After setup, verify these points:

  • SQL was imported successfully
  • ox_lib and oxmysql start without errors
  • 0r-drugbusiness starts without errors
  • Packaged product items exist in your inventory
  • You can open the warehouse interaction and complete at least one test flow