Skip to content

Items ​

np_drugs adds about 80 items. Drug items are generated from the substances' portions (Config.Substances[*].portions, their look in Config.DrugItems); everything else is defined in shared/config/items.lua and the module files.

Installing them ​

Inventory What to do
np_inventory Nothing: np_drugs registers every item at start with its use callback and context actions
ox_inventory Run npdrugs_items ox in the server console and paste the output into ox_inventory/data/items.lua. Usable items carry server = { export = 'np_drugs.useItem' }
qb-inventory (qb-core / qbx) Run npdrugs_items qb and paste the output into qb-core/shared/items.lua (inside QBShared.Items)
ESX inventory Add the items to the items table with the same names. Without metadata, drug items are plain stacks (Compatibility)

At start np_drugs prints how many items were registered. Items np_inventory already ships (weed, cigarettes, burger, water, cooler, gloves, lighter, weapon_knife) keep their own definition; np_drugs only answers their use where it needs to (weed, cigarettes, the food and drink containers).

Images: np_drugs' screens show <Config.ImagePath><item>.png (default nui://np_inventory/web/images/), named after the item, 320×320 PNG. Without one the screens draw a stand-in, but the inventory itself shows nothing: add an icon per item to your icon pack before you open the server.

Drugs ​

Substance Items (units)
Alcohol moonshine (4 drinks), moonshine_jug (40)
Tobacco cigarettes (20 cigs, np_inventory ships it)
Weed joint (0.5 g), weed (1 g, np_inventory ships it), weed_bag (3.5 g), weed_brick (250 g)
Cocaine cocaine_bag_s (0.5 g), cocaine_bag (1 g), cocaine_bag_l (3.5 g), cocaine_brick (250 g)
Ecstasy ecstasy_pill (1), ecstasy_bag (5), ecstasy_bag_l (20), ecstasy_jar (500)
Meth meth_bag_s (0.5 g), meth_bag (1 g), meth_bag_l (3.5 g), meth_brick (250 g, "Meth Tray")
Heroin heroin_bag_s (0.2 g), heroin_bag (1 g), heroin_bag_l (3.5 g), heroin_brick (250 g)
Fentanyl fentanyl_powder (1 g), fentanyl_vial (10 mg medical stock)

The bulk forms (bricks, the jar, the jug, fentanyl powder) are what the batch table cuts and portions.

Everything else ​

Kind Items
Containers ecola, sprunk, water, chips, burger, pizza_box, cereal_box (and cigarettes)
Tools drug_scale, baggies, cutting_agent, drug_pipe, rolling_paper, syringe, lighter, glue, tape, gloves, weapon_knife, cooler, respirator, k9_leash
Lab equipment lab_glassware, gas_burner, grow_tent, grow_lamp, maceration_barrel, pill_press, copper_still, fermenter
Ingredients weed_seed, fertilizer, coca_leaf, kerosene, baking_soda, cold_medicine, pseudoephedrine, solvent, raw_opium, lab_acid, safrole_oil, pill_binder, corn, sugar, yeast
Kits purity_test_kit, breathalyzer, drug_swab, blood_kit, tox_kit
Medical naloxone, naloxone_spray, sedative, activated_charcoal, saline, substitute_dose
Documents lab_report, clean_certificate
Evidence cut_packaging, used_syringe, chem_waste

The full list with labels, images and the ox / qb definitions is in the resource's README.

Containers ​

Container Capacity (g) Weighs like the real thing up to Cover Safe minutes in a vehicle
ecola, sprunk 28 14 5 180
chips 56 28 4 240
burger 14 7 4 45
pizza_box 250 120 3 60
cereal_box 500 260 2 360
water 20 8 2 120

Cover (1..5, shown as a grade) drops at odd hours (a cold pizza at 4 am) and when one person carries too many of the same. See Product loop → Concealment.

Item metadata ​

np_drugs writes only these keys. Substance and units never go into metadata: they follow from the item name.

Key On Meaning
batch Drug items Batch id ('K-2041'); everything else is read from the batch store
grade Drug items 'A'…'D', for the tooltip
purity Drug items Whole percent, only when the batch was tested
stamp Drug items Stamp id, when the batch has one
display Drug items { { label, value } } rows np_inventory shows in the tooltip
uses Kits; opened portions Uses left; doses left in a portion
evidence Used syringes Opaque id of who left it
case, seizedBy, seizedAt, prints Seized items Written when an item goes into evidence
report Lab reports, test slips The test result
lot Containers Opaque id of the concealed contents. Ordinary containers carry a decoy lot of the same shape

Context actions (np_inventory) ​

Item kind Actions
Containers Inspect (the carry card), Hollow out / pack, Cut open, Throw away. The same menu whether it is packed or not; "Use" stays the inventory's
Drugs, tools, kits, medical, documents, ingredients Throw away
Evidence Examine (police: the evidence view), Throw away

Inventories without item actions use npdrugs_inspect and the bin's own screen.