Install Instructions

Automatic SQL Injection

You'll notice in your lation_weed/install directory a file named lation_weed.sql - you do not need to import this manually into your database. Upon starting your server (or just the resource) it will automatically create and setup the necessary database table for you if it doesn't exist already.

Step 1 - Install Dependencies

There are only two dependencies (other resources) required to get Advanced Weed Growing installed properly & working: oxmysql & ox_lib. You may already have these installed, but please double check & ensure you have the latest version of each.

Important Notice

It is vitally important to ensure you start each resource in the correct order in your server.cfg. To begin, "oxmysql" should be one of, if not, the first resource started, followed by "ox_lib" - both of these should be started even before your framework (qb-core or es_extended).

Step 2 - Add Items

Next up, simply navigate to lation_weed/install/items directory (or look below this message) and find your respective inventory resource. Open the text file (or expand the drop-down menu) and copy and paste the items into your inventory resource's item directory.

Where do I add items in my inventory?

If you are unsure exactly where and how to add items into your inventory, just expand the drop down menu for your inventory and at the top will tell you where you need to copy the items too!

ox_inventory
-- Add items into ox_inventory/data/items.lua
['watering_can'] = {
    label = 'Watering Can',
    weight = 325,
},

['fertilizer'] = {
    label = 'Fertilizer',
    weight = 175,
},

['plant_pot'] = {
    label = 'Plant Pot',
    weight = 25,
},

['plant_shovel'] = {
    label = 'Shovel',
    weight = 75,
},

['plant_shears'] = {
    label = 'Shears',
    weight = 10,
},

['rolling_paper'] = {
    label = 'Rolling Paper',
    weight = 5,
},

['regweed_seed'] = {
    label = 'Weed Seed',
    weight = 15,
},

['bananakush_seed'] = {
    label = 'Banana Kush Seed',
    weight = 10,
},

['purplehaze_seed'] = {
    label = 'Purple Haze Seed',
    weight = 10,
},

['bluedream_seed'] = {
    label = 'Blue Dream Seed',
    weight = 10,
},

['regweed_bud'] = {
    label = 'Weed Bud',
    weight = 15,
},

['bananakush_bud'] = {
    label = 'Banana Kush Bud',
    weight = 15,
},

['purplehaze_bud'] = {
    label = 'Purple Haze Bud',
    weight = 15,
},

['bluedream_bud'] = {
    label = 'Blue Dream Bud',
    weight = 15,
},

['regweed_joint'] = {
    label = 'Weed Joint',
    weight = 15,
},

['bananakush_joint'] = {
    label = 'Banana Kush Joint',
    weight = 15,
},

['purplehaze_joint'] = {
    label = 'Purple Haze Joint',
    weight = 15,
},

['bluedream_joint'] = {
    label = 'Blue Dream Joint',
    weight = 15,
},
qb-inventory
-- Add items into [qb]/qb-core/shared/items.lua
watering_can = { name = 'watering_can', label = 'Watering Can', weight = 300, type = 'item', image = 'watering_can.png', unique = false, useable = false, shouldClose = true, combinable = nil, description = 'Looks pretty expensive to me' },
fertilizer = { name = 'fertilizer', label = 'Fertilizer', weight = 125, type = 'item', image = 'fertilizer.png', unique = false, useable = false, shouldClose = true, combinable = nil, description = 'Looks a little dirty' },
plant_pot = { name = 'plant_pot', label = 'Plant Pot', weight = 25, type = 'item', image = 'plant_pot.png', unique = false, useable = false, shouldClose = true, combinable = nil, description = 'I could plant something in here' },
plant_shovel = { name = 'plant_shovel', label = 'Plant Shovel', weight = 75, type = 'item', image = 'plant_shovel.png', unique = false, useable = false, shouldClose = true, combinable = nil, description = 'This would be a nice weapon..' },
plant_shears = { name = 'plant_shears', label = 'Plant Shears', weight = 15, type = 'item', image = 'plant_shears.png', unique = false, useable = false, shouldClose = true, combinable = nil, description = 'Seems useful' },
rolling_paper = { name = 'rolling_paper', label = 'Rolling Paper', weight = 10, type = 'item', image = 'rolling_paper.png', unique = false, useable = false, shouldClose = true, combinable = nil, description = nil },
regweed_seed = { name = 'regweed_seed', label = 'Weed Seed', weight = 10, type = 'item', image = 'regweed_seed.png', unique = false, useable = true, shouldClose = true, combinable = nil, description = 'I should plant this' },
purplehaze_seed = { name = 'purplehaze_seed', label = 'Purple Haze Seed', weight = 10, type = 'item', image = 'purplehaze_seed.png', unique = false, useable = true, shouldClose = true, combinable = nil, description = 'I should plant this' },
bluedream_seed = { name = 'bluedream_seed', label = 'Blue Dream Seed', weight = 10, type = 'item', image = 'bluedream_seed.png', unique = false, useable = true, shouldClose = true, combinable = nil, description = 'I should plant this' },
bananakush_seed = { name = 'bananakush_seed', label = 'Banana Kush Seed', weight = 10, type = 'item', image = 'bananakush_seed.png', unique = false, useable = true, shouldClose = true, combinable = nil, description = 'I should plant this' },
regweed_bud = { name = 'regweed_bud', label = 'Weed Bud', weight = 15, type = 'item', image = 'regweed_bud.png', unique = false, useable = false, shouldClose = true, combinable = nil, description = 'Is this legal?' },
purplehaze_bud = { name = 'purplehaze_bud', label = 'Purple Haze Bud', weight = 15, type = 'item', image = 'purplehaze_bud.png', unique = false, useable = false, shouldClose = true, combinable = nil, description = 'Is this legal?' },
bluedream_bud = { name = 'bluedream_bud', label = 'Blue Dream Bud', weight = 15, type = 'item', image = 'bluedream_bud.png', unique = false, useable = false, shouldClose = true, combinable = nil, description = 'Is this legal?' },
bananakush_bud = { name = 'bananakush_bud', label = 'Banana Kush Bud', weight = 15, type = 'item', image = 'bananakush_bud.png', unique = false, useable = false, shouldClose = true, combinable = nil, description = 'Is this legal?' },
regweed_joint = { name = 'regweed_joint', label = 'Weed Joint', weight = 10, type = 'item', image = 'regweed_joint.png', unique = false, useable = true, shouldClose = true, combinable = nil, description = 'Sell or smoke.. I cannot decide' },
bananakush_joint = { name = 'bananakush_joint', label = 'Banana Kush Joint', weight = 10, type = 'item', image = 'bananakush_joint.png', unique = false, useable = true, shouldClose = true, combinable = nil, description = 'Sell or smoke.. I cannot decide' },
purplehaze_joint = { name = 'purplehaze_joint', label = 'Purple Haze Joint', weight = 10, type = 'item', image = 'purplehaze_joint.png', unique = false, useable = true, shouldClose = true, combinable = nil, description = 'Sell or smoke.. I cannot decide' },
bluedream_joint = { name = 'bluedream_joint', label = 'Blue Dream Joint', weight = 10, type = 'item', image = 'bluedream_joint.png', unique = false, useable = true, shouldClose = true, combinable = nil, description = 'Sell or smoke.. I cannot decide' },
qs-inventory
-- Add items into [qb]/qb-core/shared/items.lua if on QBCore
-- Add items into qs-inventory/shared/items.lua if on ESX
['watering_can'] = {
    ['name'] = 'watering_can',
    ['label'] = 'Watering Can',
    ['weight'] = 300,
    ['type'] = 'item',
    ['image'] = 'watering_can.png',
    ['unique'] = false,
    ['useable'] = false,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = 'Looks a little dirty'
},
['fertilizer'] = {
    ['name'] = 'fertilizer',
    ['label'] = 'Fertilizer',
    ['weight'] = 125,
    ['type'] = 'item',
    ['image'] = 'fertilizer.png',
    ['unique'] = false,
    ['useable'] = false,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = 'Seems useful'
},
['plant_pot'] = {
    ['name'] = 'plant_pot',
    ['label'] = 'Plant Pot',
    ['weight'] = 25,
    ['type'] = 'item',
    ['image'] = 'plant_pot.png',
    ['unique'] = false,
    ['useable'] = false,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = 'I could plant something in here'
},
['plant_shovel'] = {
    ['name'] = 'plant_shovel',
    ['label'] = 'Shovel',
    ['weight'] = 75,
    ['type'] = 'item',
    ['image'] = 'plant_shovel.png',
    ['unique'] = false,
    ['useable'] = false,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = 'This would be a nice weapon..'
},
['plant_shears'] = {
    ['name'] = 'plant_shears',
    ['label'] = 'Shears',
    ['weight'] = 15,
    ['type'] = 'item',
    ['image'] = 'plant_shears.png',
    ['unique'] = false,
    ['useable'] = false,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = 'Seems useful'
},
['rolling_paper'] = {
    ['name'] = 'rolling_paper',
    ['label'] = 'Rolling Paper',
    ['weight'] = 5,
    ['type'] = 'item',
    ['image'] = 'rolling_paper.png',
    ['unique'] = false,
    ['useable'] = false,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = nil
},
['regweed_seed'] = {
    ['name'] = 'regweed_seed',
    ['label'] = 'Weed Seed',
    ['weight'] = 10,
    ['type'] = 'item',
    ['image'] = 'regweed_seed.png',
    ['unique'] = false,
    ['useable'] = true,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = 'I should plant this'
},
['purplehaze_seed'] = {
    ['name'] = 'purplehaze_seed',
    ['label'] = 'Purple Haze Seed',
    ['weight'] = 10,
    ['type'] = 'item',
    ['image'] = 'purplehaze_seed_seed.png',
    ['unique'] = false,
    ['useable'] = true,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = 'I should plant this'
},
['bluedream_seed'] = {
    ['name'] = 'bluedream_seed',
    ['label'] = 'Blue Dream Seed',
    ['weight'] = 10,
    ['type'] = 'item',
    ['image'] = 'bluedream_seed.png',
    ['unique'] = false,
    ['useable'] = true,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = 'I should plant this'
},
['bananakush_seed'] = {
    ['name'] = 'bananakush_seed',
    ['label'] = 'Banana Kush Seed',
    ['weight'] = 10,
    ['type'] = 'item',
    ['image'] = 'bananakush_seed.png',
    ['unique'] = false,
    ['useable'] = true,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = 'I should plant this'
},
['regweed_bud'] = {
    ['name'] = 'regweed_bud',
    ['label'] = 'Weed Bud',
    ['weight'] = 15,
    ['type'] = 'item',
    ['image'] = 'regweed_bud.png',
    ['unique'] = false,
    ['useable'] = false,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = 'Is this legal?'
},
['purplehaze_bud'] = {
    ['name'] = 'purplehaze_bud',
    ['label'] = 'Purple Haze Bud',
    ['weight'] = 15,
    ['type'] = 'item',
    ['image'] = 'purplehaze_bud.png',
    ['unique'] = false,
    ['useable'] = false,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = 'Is this legal?'
},
['bluedream_bud'] = {
    ['name'] = 'bluedream_bud',
    ['label'] = 'Blue Dream Bud',
    ['weight'] = 15,
    ['type'] = 'item',
    ['image'] = 'bluedream_bud.png',
    ['unique'] = false,
    ['useable'] = false,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = 'Is this legal?'
},
['bananakush_bud'] = {
    ['name'] = 'bananakush_bud',
    ['label'] = 'Banana Kush Bud',
    ['weight'] = 15,
    ['type'] = 'item',
    ['image'] = 'bananakush_bud.png',
    ['unique'] = false,
    ['useable'] = false,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = 'Is this legal?'
},
['regweed_joint'] = {
    ['name'] = 'regweed_joint',
    ['label'] = 'Weed Joint',
    ['weight'] = 10,
    ['type'] = 'item',
    ['image'] = 'regweed_joint.png',
    ['unique'] = false,
    ['useable'] = true,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = nil
},
['bananakush_joint'] = {
    ['name'] = 'bananakush_joint',
    ['label'] = 'Banana Kush Joint',
    ['weight'] = 10,
    ['type'] = 'item',
    ['image'] = 'bananakush_joint.png',
    ['unique'] = false,
    ['useable'] = true,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = nil
},
['purplehaze_joint'] = {
    ['name'] = 'purplehaze_joint',
    ['label'] = 'Purple Haze Joint',
    ['weight'] = 10,
    ['type'] = 'item',
    ['image'] = 'purplehaze_joint.png',
    ['unique'] = false,
    ['useable'] = true,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = nil
},
['bluedream_joint'] = {
    ['name'] = 'bluedream_joint',
    ['label'] = 'Blue Dream Joint',
    ['weight'] = 10,
    ['type'] = 'item',
    ['image'] = 'bluedream_joint.png',
    ['unique'] = false,
    ['useable'] = true,
    ['shouldClose'] = true,
    ['combinable'] = nil,
    ['description'] = nil
},

Step 3 - Add Images

Very similar to step one, except this time we will be adding the images for each item we added above into our respective inventory directories for images. Navigate to lation_weed/install/images to find all the images or download the ZIP file attached below then follow the instructions

ox_inventory

Drag and drop the images into ox_inventory/web/images folder.

qb-inventory

Drag and drop the images into [qb]/qb-inventory/html/images folder.

qs-inventory

Drag and drop the images into qs-inventory/html/images folder.

Step 4 - Setup Config

The second to last step to get everything working for your unique server is to open the config.lua file and assign a proper value to Config.Target, as seen below:

-- Target system, available options are: 'ox_target', 'qb-target', 'qtarget', 'custom' & 'none'
-- 'custom' needs to be added to client/functions.lua
-- If 'none' then TextUI is used instead of targeting
Config.Target = 'none'

By default, the Config.Target value will be set to 'none' which means no target system will be used and instead TextUI interactions will be used. If you wish to use a targeting system instead, you must specify which target system you use from the available options listed.

Furthermore, there are countless other configurations that can be made in the config file to customize the script to your liking and fit your server's specific needs! Every option in the config is detailed with comments explaining the use & effects of each option - so please read diligently and carefully.

Step 5 - Ensure Resource

The final step is simple - drag and drop the lation_weed resource into your main resources directory or even a sub-folder. Open your server.cfg and add "ensure lation_weed" to the bottom. As mentioned above, resource start order is vitally important and you must ensure that lation_weed is started after all dependencies (and your framework).

Lastly - save, restart your server & enjoy the most premium weed growing script on FiveM!

Upgrading to Version 2+

If you're already an owner of the Advanced Weed Growing resource, you are in the right place. Expand the drop down menu below to learn how to properly upgrade to version 2.0.0+. If this is your first time installing Advanced Weed Growing, this section is not for you!

Get started upgrading to version 2+

First and foremost, upgrading to version 2.0.0+ or later from version 1.0.0+ will require the loss of all current plants due to data structure changes. It is recommended to inform your player base before completing this upgrade and give them the chance to finish their current harvests and encourage them to not plant after completing their last harvest(s).

When your ready to upgrade, it is simple. We first must drop (and therefore delete) our current database table by executing the following query:

DROP TABLE weed_plants;

This table will no longer be used since we completely revamped how we store data in the database. Our new structure is much more streamlined and performance friendly. Version 2.0.0+ of the resource will now automatically insert the necessary database table if it doesn't already exist, so no more work is necessary for you to complete regarding the database!

Next up, it is recommended to create a backup copy of your current lation_weed resource. In version 2.0.0+ the config file has been completely rewritten, so it is not possible to just copy and paste your old configurations into the new file. You will have to reconfigure your settings as necessary based on your old config, but without copy-pasting.

Once you have a backup of your current lation_weed resource, it will be required to completely remove (and/or delete) the entire lation_weed resource from your server. Lastly, it is highly recommended to now clear your server cache as well. From here, we will complete a completely fresh re-install starting from Step 1 above, and that's all!

Quick note from Lation: I'd like to thank every one of you who are current owner's of this resource for being a customer! It's through all your suggestions, support & more that brought version 2 to life! I truly hope you are excited about this update and hope your players enjoy it even more!

Last updated