Configuration

Config, Lang, NPC, Noti, Veh, Finish, Blips = {}, {}, {}, {}, {}, {}, {}
--  $$$$$$\   $$$$$$\  $$\   $$\ $$$$$$$$\ $$$$$$\  $$$$$$\  $$\   $$\ $$$$$$$\   $$$$$$\ $$$$$$$$\ $$$$$$\  $$$$$$\  $$\   $$\ 
-- $$  __$$\ $$  __$$\ $$$\  $$ |$$  _____|\_$$  _|$$  __$$\ $$ |  $$ |$$  __$$\ $$  __$$\\__$$  __|\_$$  _|$$  __$$\ $$$\  $$ |
-- $$ /  \__|$$ /  $$ |$$$$\ $$ |$$ |        $$ |  $$ /  \__|$$ |  $$ |$$ |  $$ |$$ /  $$ |  $$ |     $$ |  $$ /  $$ |$$$$\ $$ |
-- $$ |      $$ |  $$ |$$ $$\$$ |$$$$$\      $$ |  $$ |$$$$\ $$ |  $$ |$$$$$$$  |$$$$$$$$ |  $$ |     $$ |  $$ |  $$ |$$ $$\$$ |
-- $$ |      $$ |  $$ |$$ \$$$$ |$$  __|     $$ |  $$ |\_$$ |$$ |  $$ |$$  __$$< $$  __$$ |  $$ |     $$ |  $$ |  $$ |$$ \$$$$ |
-- $$ |  $$\ $$ |  $$ |$$ |\$$$ |$$ |        $$ |  $$ |  $$ |$$ |  $$ |$$ |  $$ |$$ |  $$ |  $$ |     $$ |  $$ |  $$ |$$ |\$$$ |
-- \$$$$$$  | $$$$$$  |$$ | \$$ |$$ |      $$$$$$\ \$$$$$$  |\$$$$$$  |$$ |  $$ |$$ |  $$ |  $$ |   $$$$$$\  $$$$$$  |$$ | \$$ |
-- \______/  \______/ \__|  \__|\__|      \______| \______/  \______/ \__|  \__|\__|  \__|  \__|   \______| \______/ \__|  \__|
-- Use "esx" or "qb"
Config.Framework = "qb"
-- If you are using one of the most recent versidons of ESX, set the script name. Default = "es_extended"
Config.ESXExport = "es_extended"
-- Default ESX: "esx:getSharedObject" | Default QB: "qb-core"
Config.Core = "qb-core"
-- Font type for drawtext default text. Default = 4. Set 0 to chinese language
Config.alertTextFont = 4
-- Interaction key to perform some actions
Config.interactionKey = "E"
-- Set the price for each treasure collected
Config.priceForItem = 100
-- How the male gender is displayed in your database
Config.genderMale = 0
-- How the female gender is displayed in your database
Config.genderFemale = 1
-- Set true if you want tu use cam when you pick up a box
Config.useCam = true
-- Set to true if you want to force to use the job clothes
Config.forceUseClothes = false
-- Prop to be used as treasure
Config.treasureProp = "ch_prop_ch_case_sm_01x"
-- Number of treasures that will spawn in the point
Config.treasuresAmountInZone = 30
-- Radius of space for which the treasures can be in the point
Config.treasuresRadiusInZone = 40
-- Minimum distance between treasures
Config.miniumDistanceBetweenTreasures = 4
-- Set to true if you want to freeze the boat when you are in the water
Config.freezeBoat = true

-- $$$$$$$\  $$\       $$$$$$\ $$$$$$$\  
-- $$  __$$\ $$ |      \_$$  _|$$  __$$\ 
-- $$ |  $$ |$$ |        $$ |  $$ |  $$ |
-- $$$$$$$\ |$$ |        $$ |  $$$$$$$  |
-- $$  __$$\ $$ |        $$ |  $$  ____/ 
-- $$ |  $$ |$$ |        $$ |  $$ |      
-- $$$$$$$  |$$$$$$$$\ $$$$$$\ $$ |      
-- \_______/ \________|\______|\__|

Blips.coord = vector3(3858.78, 4459.14, 1.83)
Blips.blip = 478
Blips.blipColor = 43
Blips.blipScale = 0.7
Blips.blipText = "Treasure Hunter Job"

-- $$\   $$\ $$$$$$$\   $$$$$$\  
-- $$$\  $$ |$$  __$$\ $$  __$$\ 
-- $$$$\ $$ |$$ |  $$ |$$ /  \__|
-- $$ $$\$$ |$$$$$$$  |$$ |      
-- $$ \$$$$ |$$  ____/ $$ |      
-- $$ |\$$$ |$$ |      $$ |  $$\ 
-- $$ | \$$ |$$ |      \$$$$$$  |
-- \__|  \__|\__|       \______/

-- Location where the NPC is positioned for job selection
NPC.location = vector4(3858.78, 4459.14, 1.83, 86.55)
-- Model of the NPC
NPC.model = "s_m_y_grip_01"

-- $$\    $$\ $$$$$$$$\ $$\   $$\ $$$$$$\  $$$$$$\  $$\       $$$$$$$$\ 
-- $$ |   $$ |$$  _____|$$ |  $$ |\_$$  _|$$  __$$\ $$ |      $$  _____|
-- $$ |   $$ |$$ |      $$ |  $$ |  $$ |  $$ /  \__|$$ |      $$ |      
-- \$$\  $$  |$$$$$\    $$$$$$$$ |  $$ |  $$ |      $$ |      $$$$$\    
--  \$$\$$  / $$  __|   $$  __$$ |  $$ |  $$ |      $$ |      $$  __|   
--   \$$$  /  $$ |      $$ |  $$ |  $$ |  $$ |  $$\ $$ |      $$ |      
--    \$  /   $$$$$$$$\ $$ |  $$ |$$$$$$\ \$$$$$$  |$$$$$$$$\ $$$$$$$$\ 
--     \_/    \________|\__|  \__|\______| \______/ \________|\________|

-- Location where the vehicle will spawn when the job is selected
Veh.location = vector4(3869.15, 4471.97, 0.0, 270.16)
-- Motor power. In Fivem the default is 1.0. If you see that the vehicle has a hard time carrying the load you can raise it.
Veh.torque = 2.0
-- Model of the vehicle
Veh.model = "tug"

-- Function for the delivery of vehicle keys to the user when spawning
function giveVehicleKeys(entity, plate)
    TriggerEvent('vehiclekeys:client:SetOwner', plate)
end

function removeVehicleKeys(entity, plate)
    -- TriggerEvent('vehiclekeys:client:RemoveOwner', plate)
end

-- If you want to use a custom fuel system set true and fill the function below
Config.useCustomFuel = false

function customFuel(vehicle)
    -- insert your trigger here for your fuel system
end

-- $$$$$$$$\ $$$$$$\ $$\   $$\ $$$$$$\  $$$$$$\  $$\   $$\ 
-- $$  _____|\_$$  _|$$$\  $$ |\_$$  _|$$  __$$\ $$ |  $$ |
-- $$ |        $$ |  $$$$\ $$ |  $$ |  $$ /  \__|$$ |  $$ |
-- $$$$$\      $$ |  $$ $$\$$ |  $$ |  \$$$$$$\  $$$$$$$$ |
-- $$  __|     $$ |  $$ \$$$$ |  $$ |   \____$$\ $$  __$$ |
-- $$ |        $$ |  $$ |\$$$ |  $$ |  $$\   $$ |$$ |  $$ |
-- $$ |      $$$$$$\ $$ | \$$ |$$$$$$\ \$$$$$$  |$$ |  $$ |
-- \__|      \______|\__|  \__|\______| \______/ \__|  \__|

Finish.location = vector4(3846.95, 4478.67, 1.0, 284.7)
Finish.markerType = 23
Finish.markerSize = vector3(10.0, 10.0, 10.0)
Finish.markerColor = vector3(0, 100, 58)
Finish.blipType = 427
Finish.blipScale = 0.7
Finish.blipColor = 43
Finish.blipText = "Finish Job"

-- $$\   $$\  $$$$$$\ $$$$$$$$\ $$$$$$\ $$$$$$$$\ $$$$$$\  $$$$$$\   $$$$$$\ $$$$$$$$\ $$$$$$\  $$$$$$\  $$\   $$\  $$$$$$\  
-- $$$\  $$ |$$  __$$\\__$$  __|\_$$  _|$$  _____|\_$$  _|$$  __$$\ $$  __$$\\__$$  __|\_$$  _|$$  __$$\ $$$\  $$ |$$  __$$\ 
-- $$$$\ $$ |$$ /  $$ |  $$ |     $$ |  $$ |        $$ |  $$ /  \__|$$ /  $$ |  $$ |     $$ |  $$ /  $$ |$$$$\ $$ |$$ /  \__|
-- $$ $$\$$ |$$ |  $$ |  $$ |     $$ |  $$$$$\      $$ |  $$ |      $$$$$$$$ |  $$ |     $$ |  $$ |  $$ |$$ $$\$$ |\$$$$$$\  
-- $$ \$$$$ |$$ |  $$ |  $$ |     $$ |  $$  __|     $$ |  $$ |      $$  __$$ |  $$ |     $$ |  $$ |  $$ |$$ \$$$$ | \____$$\ 
-- $$ |\$$$ |$$ |  $$ |  $$ |     $$ |  $$ |        $$ |  $$ |  $$\ $$ |  $$ |  $$ |     $$ |  $$ |  $$ |$$ |\$$$ |$$\   $$ |
-- $$ | \$$ | $$$$$$  |  $$ |   $$$$$$\ $$ |      $$$$$$\ \$$$$$$  |$$ |  $$ |  $$ |   $$$$$$\  $$$$$$  |$$ | \$$ |\$$$$$$  |
-- \__|  \__| \______/   \__|   \______|\__|      \______| \______/ \__|  \__|  \__|   \______| \______/ \__|  \__| \______/

function notifications(notitype, message, time)
    -- Change this trigger for your notification system keeping the variables
    TriggerEvent('codem-notification', message, time, notitype)
end

-- Notifications types:
Noti.info = 'info'
Noti.check = 'check'
Noti.error = 'error'

-- Notification time:
Noti.time = 5000

-- $$$$$$$$\  $$$$$$\  $$$$$$$\   $$$$$$\  $$$$$$$$\ $$$$$$$$\ 
-- \__$$  __|$$  __$$\ $$  __$$\ $$  __$$\ $$  _____|\__$$  __|
--    $$ |   $$ /  $$ |$$ |  $$ |$$ /  \__|$$ |         $$ |   
--    $$ |   $$$$$$$$ |$$$$$$$  |$$ |$$$$\ $$$$$\       $$ |   
--    $$ |   $$  __$$ |$$  __$$< $$ |\_$$ |$$  __|      $$ |   
--    $$ |   $$ |  $$ |$$ |  $$ |$$ |  $$ |$$ |         $$ |   
--    $$ |   $$ |  $$ |$$ |  $$ |\$$$$$$  |$$$$$$$$\    $$ |   
--    \__|   \__|  \__|\__|  \__| \______/ \________|   \__|

Config.useTarget = false

-- Function for the use of the target in entities (e.g., the npc delivering the job).
function entityTarget(entity, event, label)
    exports['qb-target']:AddTargetEntity(entity, {
        options = {{
            type = "client",
            event = event,
            icon = "fas fa-box-circle-check",
            label = label
        }},
        distance = 3.0
    })
end

-- Function for remove of target on items.
function removeTarget(element)
    exports['qb-target']:RemoveTargetModel(element)
end

-- $$$$$$$\  $$$$$$$\   $$$$$$\  $$\      $$\ $$$$$$$$\ $$\   $$\ $$$$$$$$\ 
-- $$  __$$\ $$  __$$\ $$  __$$\ $$ | $\  $$ |\__$$  __|$$ |  $$ |\__$$  __|
-- $$ |  $$ |$$ |  $$ |$$ /  $$ |$$ |$$$\ $$ |   $$ |   \$$\ $$  |   $$ |   
-- $$ |  $$ |$$$$$$$  |$$$$$$$$ |$$ $$ $$\$$ |   $$ |    \$$$$  /    $$ |   
-- $$ |  $$ |$$  __$$< $$  __$$ |$$$$  _$$$$ |   $$ |    $$  $$<     $$ |   
-- $$ |  $$ |$$ |  $$ |$$ |  $$ |$$$  / \$$$ |   $$ |   $$  /\$$\    $$ |   
-- $$$$$$$  |$$ |  $$ |$$ |  $$ |$$  /   \$$ |   $$ |   $$ /  $$ |   $$ |   
-- \_______/ \__|  \__|\__|  \__|\__/     \__|   \__|   \__|  \__|   \__|

function drawTxt(key, text, font, centre, x, y, scale, r, g, b, a)
    TriggerEvent("bit-interact:Start", key, text)

    -- default drawtxt: 

    --[[SetTextFont(font)
    SetTextProportional(0)
    SetTextScale(scale, scale)
    SetTextColour(r, g, b, a)
    SetTextDropShadow(0, 0, 0, 0, 255)
    SetTextEdge(1, 0, 0, 0, 255)
    SetTextDropShadow()
    SetTextOutline()
    SetTextCentre(centre)
    SetTextEntry("STRING")
    AddTextComponentString(text)
    DrawText(x, y)]]
end

-- $$\        $$$$$$\  $$\   $$\  $$$$$$\  $$\   $$\  $$$$$$\   $$$$$$\  $$$$$$$$\ 
-- $$ |      $$  __$$\ $$$\  $$ |$$  __$$\ $$ |  $$ |$$  __$$\ $$  __$$\ $$  _____|
-- $$ |      $$ /  $$ |$$$$\ $$ |$$ /  \__|$$ |  $$ |$$ /  $$ |$$ /  \__|$$ |      
-- $$ |      $$$$$$$$ |$$ $$\$$ |$$ |$$$$\ $$ |  $$ |$$$$$$$$ |$$ |$$$$\ $$$$$\    
-- $$ |      $$  __$$ |$$ \$$$$ |$$ |\_$$ |$$ |  $$ |$$  __$$ |$$ |\_$$ |$$  __|   
-- $$ |      $$ |  $$ |$$ |\$$$ |$$ |  $$ |$$ |  $$ |$$ |  $$ |$$ |  $$ |$$ |      
-- $$$$$$$$\ $$ |  $$ |$$ | \$$ |\$$$$$$  |\$$$$$$  |$$ |  $$ |\$$$$$$  |$$$$$$$$\ 
-- \________|\__|  \__|\__|  \__| \______/  \______/ \__|  \__| \______/ \________|

Lang.pickUp = "Pick up box"
Lang.buoy = "Catch hook"
Lang.openJobMenu = "Open job menu"
Lang.noJob = "You are not working as a treasure hunter, you cannot perform this action"
Lang.startJob = "You are now working as a treasure hunter"
Lang.finishJob = "You have finished your work as a treasure hunter, you have received a payment of"
Lang.noClothes = "You don't have the right clothes to start the job"
Lang.noClothesOff = "You must wear your work clothes during the working day"
Lang.noRope = "You don't have a rope to catch the treasure"
Lang.alreadyHook = "You already have a hook in your hand"

-- $$$$$$\  $$\       $$$$$$\ $$$$$$$$\ $$\   $$\ $$$$$$$$\  $$$$$$\  
-- $$  __$$\ $$ |     $$  __$$\\__$$  __|$$ |  $$ |$$  _____|$$  __$$\ 
-- $$ /  \__|$$ |     $$ /  $$ |  $$ |   $$ |  $$ |$$ |      $$ /  \__|
-- $$ |      $$ |     $$ |  $$ |  $$ |   $$$$$$$$ |$$$$$\    \$$$$$$\  
-- $$ |      $$ |     $$ |  $$ |  $$ |   $$  __$$ |$$  __|    \____$$\ 
-- $$ |  $$\ $$ |     $$ |  $$ |  $$ |   $$ |  $$ |$$ |      $$\   $$ |
-- \$$$$$$  |$$$$$$$$\ $$$$$$  |  $$ |   $$ |  $$ |$$$$$$$$\ \$$$$$$  |
-- \______/ \________|\______/   \__|   \__|  \__|\________| \______/

if Config.Framework == "esx" then
    Clothes = {
        male = {
            ['tshirt_1'] = 15,
            ['tshirt_2'] = 0,
            ['torso_1'] = 15,
            ['torso_2'] = 0,
            ['decals_1'] = 0,
            ['decals_2'] = 0,
            ['arms'] = 40,
            ['pants_1'] = 16,
            ['pants_2'] = 2,
            ['shoes_1'] = 34,
            ['shoes_2'] = 0,
            ['helmet_1'] = 0,
            ['helmet_2'] = 0,
            ['chain_1'] = 0,
            ['chain_2'] = 0,
            ['ears_1'] = 0,
            ['ears_2'] = 0
        },
        female = {
            ['tshirt_1'] = 3,
            ['tshirt_2'] = 0,
            ['torso_1'] = 15,
            ['torso_2'] = 11,
            ['decals_1'] = 0,
            ['decals_2'] = 0,
            ['arms'] = 32,
            ['pants_1'] = 15,
            ['pants_2'] = 11,
            ['shoes_1'] = 35,
            ['shoes_2'] = 0,
            ['helmet_1'] = 0,
            ['helmet_2'] = 0,
            ['chain_1'] = 0,
            ['chain_2'] = 0,
            ['ears_1'] = 0,
            ['ears_2'] = 0
        }
    }
elseif Config.Framework == "qb" then
    Clothesmale = {
        outfitData = {
            ['pants'] = {
                item = 16,
                texture = 2
            },
            ['arms'] = {
                item = 40,
                texture = 0
            },
            ['t-shirt'] = {
                item = 15,
                texture = 0
            },
            ['vest'] = {
                item = 0,
                texture = 0
            },
            ['torso2'] = {
                item = 15,
                texture = 0
            },
            ['shoes'] = {
                item = 34,
                texture = 0
            },
            ['accessory'] = {
                item = 0,
                texture = 0
            },
            ['bag'] = {
                item = 0,
                texture = 0
            },
            ['hat'] = {
                item = 0,
                texture = 0
            },
            ['glass'] = {
                item = 0,
                texture = 0
            },
            ['mask'] = {
                item = 0,
                texture = 0
            }
        }
    }
    Clothesfemale = {
        outfitData = {
            ['pants'] = {
                item = 15,
                texture = 11
            },
            ['arms'] = {
                item = 32,
                texture = 0
            },
            ['t-shirt'] = {
                item = 3,
                texture = 0
            },
            ['vest'] = {
                item = 0,
                texture = 0
            },
            ['torso2'] = {
                item = 15,
                texture = 11
            },
            ['shoes'] = {
                item = 35,
                texture = 0
            },
            ['accessory'] = {
                item = 0,
                texture = 0
            },
            ['bag'] = {
                item = 0,
                texture = 0
            },
            ['hat'] = {
                item = 0,
                texture = 0
            },
            ['glass'] = {
                item = 0,
                texture = 0
            },
            ['mask'] = {
                item = 0,
                texture = 0
            }
        }
    }

end

-- ZONES
Zones = {
    [1] = vector3(4278.4, 4477.52, -1.03),
    [2] = vector3(4099.89, 4722.47, 0.87),
    [3] = vector3(3984.05, 5104.59, -1.09),
    [4] = vector3(4311.02, 4120.05, 0.67)
}

Last updated