Accessible code

Shared = {
    Locale = 'en',

    commands = {
        deletePlant = {
            name = 'deleteplant',
            help = 'Command that allows you to delete closest plant to you',
            restricted = 'group.admin'
        },

        tpplant = {
            name = 'tpplant',
            help = 'Command that allows you to teleport to desired plant',
            restricted = 'group.admin'
        },

        plantShow = {
            name = 'plantshow',
            help = 'Command that allows you to turn on/off blips of weed\'s on minimap',
            restricted = 'group.admin'
        },
        
        plantInfo = {
            name = 'plantinfo',
            help = 'Command that allows you to get closest plant info',
            restricted = 'group.admin'
        },

        plantid = {
            name = 'plantid',
            help = 'Command that allows you to get cloest plant ID',
            restricted = 'group.admin'
        },

        placeplant = {
            name = 'placeplant',
            help = 'Command that allows you to place plant on desired location'
        },

        cornersell = {
            enabled = true,         -- if you dont want to use this cornersell, put this to false
            name = 'cornersell',
            help = 'Command that turns on/off corner selling',
            reward = 'black_money'  -- item that you will get upon selling weed
        }
    },

    math = {
        updateInterval      = 35000,            -- how often plants are updated in msec, would recomment not to go under 30000 msec (30 sec)

        /*
        in every updateInterval hydratation
        and feed will decrease by reduceHydration

        aka:
        every 35 sec hydratation and feed will decrease by
        3% and growth will increase by 2%
        */

        reduceHydration     = 3.0,
        reduceFeed          = 3.0,
        giveGrowth          = 2.0,

        giveWater           = 10.0, -- how much % plant will get upon watering
        giveFood            = 10.0, -- how much % plant will get upon feeding

        /*
        in every updateInterval if plants
        hydratation is above QualityLvl
        then it will give giveQuality else it will
        reduceQuality

        aka:
        in every 35 sec if hydratation and
        feed >= 65% then quality of plant will
        increase by 5% else it will decrease
        by 5%
        */

        QualityLvl          = 65.0,
        giveQuality         = 5.0,
        reduceQuality       = 5.0,


        /*
        on what growth % it will change to next stage

        aka if plants growth is 55% then it will go to stage II,
        same for stage III
        */

        stageII             = 55.0,
        stageIII            = 85.0,

        /*
        after plant reaches 100%, on harvest
        next math will be applied:

        quality / 2
        max 100 / 2 = 50
        min 10 / 2 = 10

        if you took well care of plant
        and it has 100% quality you will
        get 50 rewardItem
        */


        harvestMath = 2, -- plant quality / harvestMath will give final item, 100 quality / 2 = 50 cannabis, 10 quality / 2 = 5 cannabis
    },

    Gloves = {
        male = {
            ['32'] = true,
        },
        female = {
            
        }
    },

    fingerPrint = {                             -- when planting plant, if you don't have glowes that are down there at table you will leave fingerprints at plant which police can find, needs ox_inventory for storing metadata, fingerprints are leaved when you plant/feed/water plant
        enable = true,
        allowedJobs = {                         -- jobs that will be able to search for fingerprints
            ['police'] = true,
        },
        removeYourOwnPrints = true,             -- possibility to remove your own fingerprints on plants, future plant to add item required to remove
    },

    durations = {
        watering = 6000,                        -- 6 sec sec
        feedingPlant = 6000,                    -- 6 sec sec
        removingPrints = 7500,                  -- 7.5 sec
        searchingForPrints = 10000,             -- 10 sec
        fingerPrintScann = 10000,               -- 10 sec
    },

    fingerPrintScanner = {
        coords = vec3(461.642, -989.308, 24.915),
        TextUI = {
            position = "right-center",
            icon = 'fa-solid fa-fingerprint',
            style = {
                borderRadius = 5,
                backgroundColor = '',
                color = ''
            }
        },
        blip = {
            enable = true,                      -- if you want for fingerPrint.allowedJobs to see blip
            color = 30,                         -- https://docs.fivem.net/docs/game-references/blips/#blip-colors
            type = 211,                         -- https://docs.fivem.net/docs/game-references/blips/
            size = 0.6,
            text = 'Finger Print Scanner'
        }
    },

    useTarget = false,                              -- possibility to use third eye scipt
    targetType = 'qtarget',                         -- can be qb-target/qtarget/ox_target

    TextUI = {                                  -- if useTarget is disabled then you get text ui, currently looks like this: https://prnt.sc/lKUZnckZkEIg
        position = "right-center",
        icon = 'fa-solid fa-cannabis',
        style = {
            borderRadius = 5,
            backgroundColor = '#48BB78',
            color = 'white'
        }
    },

    notifyPosition = 'bottom',                  -- 'top' or 'top-right' or 'top-left' or 'bottom' or 'bottom-right' or 'bottom-left' or 'center-right' or 'center-left'

    WeedStages = {                              -- plants per stage, if you have custom prop for this just can put it here
        [1] = `bkr_prop_weed_01_small_01c`,
        [2] = `bkr_prop_weed_med_01a`,
        [3] = `bkr_prop_weed_lrg_01a`,
    },

    jobs = {                                    -- jobs that will be able to destroy plants
        ['police'] = true,
    },

    items = {
        pot = 'weedpot',
        fertilizer = 'fertilizer',              -- item used to increase growth of weed
        water = 'water',                        -- item used to to reduce thirst of plant,
        rewardItem = 'cannabis'                 -- when strain type is unknown it will give this item, when migratin from old version
    },


    -- if you are migrating from version before where no strains types existed, this price will be used when selling, when harvesting it will give item that you used before in items.rewardItem
    priceForUnknown = math.random(50, 90),

    strains = {
        ['p_haze'] = {              -- item name (you need to add this item to your inventory or framework)
            seed = 'p_haze_seed',   -- seed item name (you need to add this item to your inventory or framework)
            label = 'Purple Haze',  -- label that will be displayed in menu
            back = { 0, 2, 30 },    -- { minimum, maximum, give chance, min 0, max 2, chance 30% }, upon harvesting how much you should get seed
            --price = 150,            -- price per item, you can also use math.radnom() to get random price upon every script start, also supported price per day
            price = {
                ['Mon'] = math.random(50, 100),
                ['Tue'] = 110,
                ['Wed'] = 120,
                ['Thu'] = 130,
                ['Fri'] = 140,
                ['Sat'] = 150,
                ['Sun'] = 170,
            },
            sellChance = 50 -- % to sell item to npc
        }

        -- you can add more types here
    },

    maxPlants = 6,                              -- max plants per player, if you put false then this feature is disabled

    forbiddenPlantZones = {                     -- zone where people will not be able to plant weed, radius is around 500 units from center of this coords
        {coords = vec3(426.544, -979.332, 30.706)},
    },
}

Last updated