Installation
Dependencies
QBCore Framework qb-inventory (Custom inventory possible)
How to install
Drag the script in your folder, run the SQL player_drugs
Add the following item to yourinventory/data/items.lua
QBCore users to qbcore/shared/items.lua
Add the item image to your inventory/images
-- Weed
["weed"] = {
["name"] = "weed",
["label"] = "Weed Bag 2g",
["weight"] = 10,
["type"] = "item",
["image"] = "weed_baggy.png",
["unique"] = false,
["useable"] = true,
["shouldClose"] = false,
["combinable"] = nil,
["description"] = "A weed bag with 2g"
},
-- Seeds
["seed_weed"] = {
["name"] = "seed_weed",
["label"] = "Weed Seed",
["weight"] = 2,
["type"] = "item",
["image"] = "weed-plant-seed.png",
["unique"] = false,
["useable"] = true,
["shouldClose"] = false,
["combinable"] = nil,
["description"] = "Marijuana Seed"
},
--raw weed
["raw_weed"] = {
["name"] = "raw_weed",
["label"] = "Weed Plant",
["weight"] = 150,
["type"] = "item",
["image"] = "harvested_weed.png",
["unique"] = false,
["useable"] = true,
["shouldClose"] = false,
["combinable"] = nil,
["description"] = "Raw Weed Plant"
},
--Trowel
["trowel"] = {
["name"] = "trowel",
["label"] = "Trowel",
["weight"] = 100,
["type"] = "item",
["image"] = "trowel.png",
["unique"] = false,
["useable"] = true,
["shouldClose"] = true,
["combinable"] = nil,
["description"] = ""
},
--Empty bottle
["empty_bottle"] = {
["name"] = "empty_bottle",
["label"] = "Empty Bottle",
["weight"] = 10,
["type"] = "item",
["image"] = "empty_bottle.png",
["unique"] = false,
["useable"] = true,
["shouldClose"] = true,
["combinable"] = nil,
["description"] = "Empty bottle to fill with water"
},
Create custom Weed Plants
This is an example how to create a custom Weed Plant.
Create the custom Weed Plant as a Item and add it to yourinventory/items.lua
"raw_purple_weed" is that what you get on harvesting. "purple_weed" is that what you get after proceeding the Weed Plant.
-- Purple Weed
['raw_purple_weed'] = {
label = 'Purple Weed Plant',
weight = 200,
client = {
image = 'harvested_weed.png',
},
},
['purple_weed'] = {
label = 'Purple Weed',
weight = 100,
client = {
image = 'weed.png',
},
},
Add the new custom Weed Plant to your configuration.
WeedPlantTypes = {
"raw_weed",
"raw_purple_weed",
--"raw_amnezia_weed",
},
You need "raw_purple_weed" to process "purple_weed"
Config.WeedProceedTypes = {
["raw_weed"] = "weed", -- You need a raw weed plant to proceed weed
["raw_purple_weed"] = "purple_weed", -- You need a purple weed plant to proceed purple weed
--["raw_amnezia_weed"] = "amnezia_weed",
}
Make sure to add the final item to the Sell list to sell it.
Config.SellItems = {
["weed"] = 100,
["purple_weed"] = 100,
--["amnezia_weed"] = 100,
}
Last updated