Unzip the script folder within your server resources folder. Ensure script in server.cfg ... "ensure ns-cocainedrug". ( NOTE : Please don't change the script name or folder name.)
STEP 2 - Script Configuration
When you open the config file you'll see a lines of codes to configure it to your server.
STEP 2.1 - Dependency Configuration
Framework ="qb-core", -- Folder NameTarget ="qb-target", -- Folder NameNotify ="qb", -- "qb" or "okok" or "infinity" or "rr" or "t"Menu ="qb", -- qb or oxInv ="qb", -- qb or ox
STEP 2.2 - Consumable Effects
Config.TakeDrugs = { Crack = { Enable =true, -- If you want to make it consumable Animations = { Dict ='switch@trevor@trev_smoking_meth', -- Animation dictonary for taking Anim ='trev_smoking_meth_loop', -- Animation for taking Flags =49-- Animation flags for taking }, Armour = {min =10, max =30}, -- % Stress = {min =10, max =30}, -- % Effects =true, -- Enables screen effects; true = enabled, false = disabled Time =math.random(5,8), -- Time in (s) to take Requiredlighter = {Enabled =true, item ='lighter'} }, Cocaine = { Enable =true, -- If you want to make it consumable Animations = { Dict ='switch@trevor@trev_smoking_meth', -- Animation dictonary for taking Anim ='trev_smoking_meth_loop', -- Animation for taking Flags =49-- Animation flags for taking }, Armour = {min =10, max =30}, -- % Stress = {min =10, max =30}, -- % Effects =true, -- Enables screen effects; true = enabled, false = disabled Time =math.random(5,8) -- Time in (s) to take }}
You can edit what each consumable item gives your player. Cocaine and crack also have amazing effects on players.
STEP 2.3 - Location Configuration
You are able to change the locations within the target.lua file, located within the client/opensource folder
STEP 2.4 - Dispatch Configuration
Instead of using the default qbcore dispatch system like I have used, you are able to easily add your own dispatch system within the script by heading over to client/opensource/police.lua and updating the TriggerEvent.
You can always join the support discord and create a ticket for help.
STEP 2.5 - Blackmarket
Config.Blackmarket = { label ="BlackMarket", slots =3, items = { -- You need to add your own items here, any you want. { name ='empty_weed_bag', price =2, amount =500, info = {}, type ='item', slot =1}, { name ='drug_cuttingkit', price =1000, amount =50, info = {}, type ='item', slot =2}, { name ='drug_scales', price =1500, amount =50, info = {}, type ='item', slot =3} },}
Blackmarket is a feature set at the location where players can process drugs. You are able to add more items if you would like to. It is mainly included to provide cutting tools to bag your drugs.
STEP 3 - Inventory Images
Add your images to your inventory script, e.g:
[qb] > qb-inventory > html > images
STEP 4 - Add Items to QbCore
In [qb] > qb-core > shared> items.lua
-- Tools['drug_shears'] = {['name'] = 'drug_shears', ['label'] = 'Trimming Shears', ['weight'] = 200, ['type'] = 'item', ['image'] = 'drug_shears.png', ['unique'] = false, ['useable'] = false, ['shouldClose'] = false, ['combinable'] = nil, ['description'] = 'A set of high quality trimming shears.'},
['drug_scales'] = {['name'] = 'drug_scales', ['label'] = 'Scale', ['weight'] = 1500, ['type'] = 'item', ['image'] = 'drug_scales.png', ['unique'] = false, ['useable'] = true, ['shouldClose'] = false, ['combinable'] = nil, ['description'] = 'A set of premium scales for weighing out decimals..'},
['drug_cuttingkit'] = {['name'] = 'drug_cuttingkit', ['label'] = 'Cutting Kit', ['weight'] = 1000, ['type'] = 'item', ['image'] = 'drug_cuttingkit.png', ['unique'] = false, ['useable'] = true, ['shouldClose'] = true, ['combinable'] = nil, ['description'] = 'A mirror, a razor blade.. obviously this is a make up kit..'},
['plasticjerrycan'] = {['name'] = 'plasticjerrycan', ['label'] = 'Plastic Jerrycan', ['weight'] = 500, ['type'] = 'item', ['image'] = 'plasticjerrycan.png', ['unique'] = false, ['useable'] = true, ['shouldClose'] = true, ['combinable'] = nil, ['description'] = 'A empty jerry can for storing liquids.'},
['lighter'] = {['name'] = 'lighter', ['label'] = 'Lighter', ['weight'] = 5, ['type'] = 'item', ['image'] = 'lighter.png', ['unique'] = false, ['useable'] = false, ['shouldClose'] = true, ['combinable'] = nil, ['description'] = 'On new years eve a nice fire to stand next to'},
['empty_weed_bag'] = {['name'] = 'empty_weed_bag', ['label'] = 'Empty Weed Bag', ['weight'] = 0, ['type'] = 'item', ['image'] = 'weed_baggy_empty.png', ['unique'] = false, ['useable'] = true, ['shouldClose'] = true, ['combinable'] = nil, ['description'] = 'A small empty bag'},
-- Elements['cement'] = {['name'] = 'cement', ['label'] = 'Cement', ['weight'] = 1000, ['type'] = 'item', ['image'] = 'cement.png', ['unique'] = false, ['useable'] = true, ['shouldClose'] = true, ['combinable'] = nil, ['description'] = 'Just a regular bag of builders cement.'},
['cocaleaf'] = {['name'] = 'cocaleaf', ['label'] = 'Cocaine Leaf', ['weight'] = 200, ['type'] = 'item', ['image'] = 'cocaineleaf.png', ['unique'] = false, ['useable'] = true, ['shouldClose'] = false, ['combinable'] = nil, ['description'] = 'Makes that premium nose candy!'},
['sodiumbicarbonate'] = {['name'] = 'sodiumbicarbonate', ['label'] = 'Baking Soda', ['weight'] = 1000, ['type'] = 'item', ['image'] = 'sodiumbicarbonate.png', ['unique'] = false, ['useable'] = true, ['shouldClose'] = true, ['combinable'] = nil, ['description'] = 'Baking soda ey? What you cooking?'},
['illegalgasoline'] = {['name'] = 'illegalgasoline', ['label'] = 'Illegal Gasoline', ['weight'] = 2500, ['type'] = 'item', ['image'] = 'illegalgasoline.png', ['unique'] = false, ['useable'] = true, ['shouldClose'] = true, ['combinable'] = nil, ['description'] = 'Stolen gasoline? What are you doing with this?'},
['benzocaine'] = {['name'] = 'benzocaine', ['label'] = 'Benzocaine', ['weight'] = 500, ['type'] = 'item', ['image'] = 'benzocaine.png', ['unique'] = false, ['useable'] = true, ['shouldClose'] = true, ['combinable'] = nil, ['description'] = 'Benzo? You got a toothache mate?'},
-- Drugs['cokebaggy'] = {['name'] = 'cokebaggy', ['label'] = '1g Bag of Coke', ['weight'] = 10, ['type'] = 'item', ['image'] = 'cocaine_baggy.png', ['unique'] = false, ['useable'] = true, ['shouldClose'] = true, ['combinable'] = nil, ['description'] = 'A gram of the finest nose candy!'},
['coke_1oz'] = {['name'] = 'coke_1oz', ['label'] = 'Ounce of Cocaine', ['weight'] = 280, ['type'] = 'item', ['image'] = 'coke_1oz.png', ['unique'] = false, ['useable'] = true, ['shouldClose'] = true, ['combinable'] = nil, ['description'] = 'A ounce of the finest nose candy!'},
['crack_1oz'] = {['name'] = 'crack_1oz', ['label'] = 'Ounce of Crack', ['weight'] = 500, ['type'] = 'item', ['image'] = 'crack_1oz.png', ['unique'] = false, ['useable'] = true, ['shouldClose'] = true, ['combinable'] = nil, ['description'] = 'For all the thirsty out there'},
['crack_baggy'] = {['name'] = 'crack_baggy', ['label'] = '1g Bag of Crack', ['weight'] = 10, ['type'] = 'item', ['image'] = 'crack_baggy.png', ['unique'] = false, ['useable'] = true, ['shouldClose'] = true, ['combinable'] = nil, ['description'] = 'Man your about to lose some teeth!'},
STEP 5 - CocaineLab
If you are going to use the default locations shown in previews for cocaine processing, you will need to make sure your Entering/ exiting the lab is set within the qb-smallresources.
Normally, qb-smallresources comes set for it as default, however if you have deleted it, you will need to add it back.
It is really simple, just locate Config.Teleports within qb-smallresources/config.lua,...
Make sure players are able to purchase water_bottles and sodiumbicarbonate from 7-11 Shops, add this to qb-shops/config.lua > Config.Products = { ["normal"] = {
[13] = {
name = "sodiumbicarbonate",
price = 6,
amount = 100,
info = {},
type = "item",
slot = 13,
},
Also make sure to add the drug shear item (drug_shears) somewhere. I recommend adding it in smoke in the water
Preview Videos
TEBEX
Link to Purchase Escrow ($5.99):
Link to Purchase Open Source ($14.99):