Skip to content
NivoDocs

Search documentation

Drugs Creator

Exports & events

Commands and events of nv_drugscreator. The script is managed in game from one admin UI, so it has no exports yet; ask in our Discord if you need one.

Preview: the script is not released yet. Names can still change; this page is updated with every release.

Commands

CommandWhoWhat it does
/drugsadmin group (Config.Admin.group)admin UI: harvest spots, props, drops and plant types
/drugbenchadmins (command.drugs)places a public workbench in front of you, usable by everyone; /drugbench remove deletes the nearest one

Events

EventSideUse
nv_plants:useclientstarts planting a seed of the given plant type (sent by the usable seed items)
nv_drugs:tablePlaceclientstarts placing a processing table (sent by the table item)
nv_drugs:bagUseclientopens the packing menu of the bag recipes (sent by the empty_bag item)

Items

Items come from install/items.json. nv_bridge adds them automatically on ESX and QBCore; for ox_inventory copy install/ox_items.lua into ox_inventory/data/items.lua.

Processing and selling

Everything here is edited in the /drugs window, sections Workbenches (tabs Workbenches and Recipes) and Selling, and stored in the database. plants_config.lua (PConfig.TableRecipes) and Config.Sell in config.lua only hold the defaults, which are copied to the database on the first start.

  • Recipes: drying, trimming and packing weed, packing cocaine from coca leaves, processing opium from poppy pods. You can create, edit, disable and delete recipes (input and extra item, output, duration, animation, per weed strain or plain). A recipe marked usable from the inventory also works anywhere by using an empty_bag. Works without nv_laboratorycreator.
  • Workbenches: the placeable table (weed_table item) or public workbenches that admins place from the window (Add workbench here) or with /drugbench.
  • Selling to NPCs: any pedestrian buys the listed items for a fixed price. Prices, pieces per sale, refusal chance, cooldown, payment (cash or dirty money), minimum police and the police alert chance are in the window. It switches off by itself when nv_drugs-selling runs, which has the full street selling.