🔨Installation

This installation guide primarily focuses on the qb-core framework; however, please remember that the GFX Weed Script is also fully compatible with the ESX framework.

If you encounter any errors or difficulties during setup or usage, don’t hesitate to reach out to us. You can find our Discord link at the bottom of the installation document.

Installation Steps

1. Add Script to Server

  1. Place the following folders into your resources directory:

    • gfx_weed

    • gfx_weed_props

  2. Add the following lines to your server.cfg in this order:

    ensure gfx_weed_props
    ensure gfx_weed

2. Add Items to QB-Core

  1. Open the qb-core/shared/items.lua file.

  2. Add the following item rows to the items array:

        weed_skunk_seed              = { name = 'weed_skunk_seed', label = 'Skunk Seed', weight = 0, type = 'item', image = 'weed_seed.png', unique = false, useable = true, shouldClose = true, description = 'A weed seed of Skunk' },
        crack_baggy                  = { name = 'crack_baggy', label = 'Bag of Crack', weight = 0, type = 'item', image = 'crack_baggy.png', unique = false, useable = true, shouldClose = true, description = 'To get happy faster' },
        rolling_paper                = { name = 'rolling_paper', label = 'Rolling Paper', weight = 0, type = 'item', image = 'rolling_paper.png', unique = false, useable = false, shouldClose = true, description = 'Paper made specifically for encasing and smoking tobacco or cannabis.' },
        joint                        = { name = 'joint', label = 'Joint', weight = 0, type = 'item', image = 'joint.png', unique = false, useable = true, shouldClose = true, description = 'Sidney would be very proud at you' },
        fertilizer                   = { name = 'fertilizer', label = 'Plant Fertilizer', weight = 2000, type = 'item', image = 'weed_nutrition.png', unique = false, useable = true, shouldClose = true, description = 'Plant nutrition' },
        trimmer                      = { name = 'trimmer', label = 'Trimmer', weight = 2000, type = 'item', image = 'trimmer.png', unique = false, useable = true, shouldClose = true, description = 'Plant nutrition' },

3. Add Item Images

  1. Locate your qb-inventory/html/images/ folder.

  2. Add the following images (provided in the package) to the folder:

    • weed_skunk_seed.png

    • crack_baggy.png

    • rolling_paper.png

    • joint.png


4. Customize Configurations

Client Configuration (client_config.lua)

  • Adjust the theme colors, table settings, and plant growth parameters to fit your server’s needs.

Server Configuration (server_config.lua)

  • Update the Discord bot token if you are using Discord profile images for leaderboards.

  • Adjust item names or ped models based on your preferences.


5. Test the Script

  • Restart the server.

  • Verify that:

    • Items are available in the inventory.

    • Props spawn correctly.

    • Tables function as intended.

    • Weed growing, processing, and selling systems work seamlessly.


Dependencies

Ensure the following are installed and properly configured:

  • QB-Core Framework (or compatible ESX framework)

  • A notification system for in-game messages (optional but recommended).


Troubleshooting

  • Missing Items in Inventory: Ensure items are added to qb-core/shared/items.lua.

  • Props Not Loading: Confirm gfx_weed_props is started before gfx_weed.

  • Notification Errors: Update the notification function in the config files to your custom notification system.

For further assistance, contact the GFX Team! https://discord.gg/gfxdevelopment

Last updated