Skip to content
NivoDocs

Search documentation

Drugs Selling

Exports & events

Exports and commands of nv_drugs-selling for other resources (phones, MDTs, admin menus, battle passes ...).

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

Server exports

GetDealerStats

Street-dealer progress of a player.

local stats = exports['nv_drugs-selling']:GetDealerStats(source)
-- { xp = 1240, sales = 87, level = 4, current = 240, next = 500, rank = 'Corner boy' } or nil
FieldMeaning
xptotal reputation points
salesstreet sales made
levelcurrent level
current / nextpoints inside the level / points needed for the next level
rankrank name from street_config.lua

AddDealerXp

Gives street reputation, for example from a mission or a battle pass.

local added, leveledUp, level = exports['nv_drugs-selling']:AddDealerXp(source, 50)

Returns the points added, true when the player reached a new level, and the level after the change. Returns 0, false, 0 when leveling is disabled or the player is not loaded.

WholesaleNow

Where the roaming wholesaler is right now.

local ws = exports['nv_drugs-selling']:WholesaleNow()
-- { label = 'Wholesaler', x = 0.0, y = 0.0, z = 0.0, leftMin = 34 } or nil

leftMin is the number of minutes until the wholesaler moves.

Commands

CommandWhoWhat it does
/sellmenuadmin group (Config.Admin.group)settings: prices, zones, reputation, wholesale, contracts
/dealerstatsevery playerown street-dealer level and reputation (name set in street_config.lua)
/wswhereadmins with command.sellmenucurrent wholesaler location in chat and console

Police alerts

Street sales and contracts send police alerts through nv_bridge, so they show up in your dispatch (lb-tablet, cd_dispatch, ps-dispatch, qs-dispatch, rcore_dispatch or your own in custom/dispatch.lua).