Documentation

Setup

Install and configure Drugdealer.

#Download

Download Zyke's Drugdealer from your CFX portal under Granted Assets. If it is missing from your portal, see Lacking Entitlement.

#Dependencies

Install oxmysql, ox_lib, and zyke_lib, and configure the framework and inventory in zyke_lib. See Dependencies.

#Resource

Place the resource in your server's resources folder as zyke_drugdealer. Keep the folder name as it is.

#Items & Images

Add the items to your inventory from zyke_drugdealer/extras/items/:

  • ox_inventory: copy the definitions from ox_inventory.lua into ox_inventory/data/items.lua.
  • QBCore / Qbox: copy the definitions from qb-core.lua into your shared items.
  • ESX with the default inventory: import zyke_drugdealer_item.sql into your database. It adds drugphone, weedleaf_quality2, and cokeleaf_quality2, the items the default config uses.

Copy the images from zyke_drugdealer/extras/items/images/ into the inventory's image directory.

The drugphone item opens the dealer phone. The leaves are the drugs customers buy. If your server already has its own drug items, change the item of each drug in shared/unlocked/config.lua instead.

#Database

The zyke_drugdealer_reputation table is created on the first start, so there is no SQL to import for it.

#Configuration

Edit shared/unlocked/config.lua. Review the phone item and command, the blocked jobs, the drugs and their prices, and the police alerts. Use the Config reference for the current defaults.

#Start Order

Start the dependencies before Drugdealer:

cfg
ensure oxmysql
ensure ox_lib
ensure zyke_lib
ensure zyke_drugdealer

#Verify Gameplay

Give yourself a drugphone and some weedleaf_quality2. Use the phone, or run /opendrugphone, wait for a customer's message, call them for the location, and complete the deal.