Configuration


1. Configure cl_config.lua

In this section, you will configure the client-side configuration file cl_config.lua. Follow the instructions below to set it up according to your framework (ESX or QBcore).

Config = {}

Config.Header = {
    title = "RESMONSTUDIO",           -- Title displayed in the header
    name = "Welcomecar"               -- Name of the system in the header
}

Config.Options = {
    Language = 'en',                  -- System language ('en' for English, 'pl' for Polish, etc.)
    UseOldEsx = false,                -- Use old ESX method (true) or new ESX export method (false)

    Overextended = {
        Enabled = false,                -- Enable Overextended support for advanced features
        UseOXInventory = false,         -- Enable OX Inventory integration
        UseOxTarget = false,            -- Use OxTarget for interactions (requires ped/entity positions, not markers)
        TargetIcon = "fa-solid fa-car", -- Icon shown during OxTarget interactions
        TargetText = "Open Welcomecar"  -- Text displayed for OxTarget interactions
    },

    SharedObject = {
        client = "esx:getSharedObject",  -- ESX shared object event for client-side
        server = "esx:getSharedObject"   -- ESX shared object event for server-side
    },

    KeySystem = {
        EnableGiveKeys = false,    -- Enable or disable the key-giving feature
        KeySystem = "jaksam"       -- Key system type ("jaksam" or "msk")
    },

    AdvancedGarages = {
        UseAdvancedGarage = false,        -- Enable or disable advanced garage functionality
        AdvancedGarage = "Hayes Autos"    -- Garage to store the vehicle in if enabled
    },

    VehicleSpawning = {
        SpawnVehicle = false,  -- Automatically spawn the vehicle after granting it
        SpawnCoords = {
            coords = vector3(2533.01, -405.45, 92.58), -- Vehicle spawn location if enabled
            heading = 44.50 -- Vehicle spawn direction
        }
    },

    Positions = {
        [1] = {
            coords = vector3(2522.27, -413.39, 94.12), -- Location for opening the vehicle selection menu

            ped = { 
                enabled = false,           -- Enable or disable the ped
                model = "a_m_m_farmer_01", -- Ped model to spawn
                heading = 328.42           -- Direction the ped faces
            },

            entity = {                     -- Settings for Christmas Tree prop
                enabled = false,           -- Enable or disable the prop
                object = "xm_prop_base_staff_desk_02", -- Prop model
                heading = 137.21            -- Direction the prop faces
            },

            Marker = {
                enabled = true,            -- Enable or disable the marker
                Type = 21,                 -- Marker type (ID for the type of marker)
                Size = vector3(1.0, 1.0, 1.0), -- Size of the marker (X, Y, Z)
                Color = { r = 255, g = 0, b = 0, a = 144 }, -- RGBA color values for the marker
                BobUpAndDown = false,      -- Should the marker bob up and down (true/false)
                FaceCamera = true,         -- Should the marker always face the camera (true/false)
                Rotate = false,            -- Should the marker rotate (true/false)
                TextureDict = nil,         -- Optional texture dictionary for the marker (use nil if not needed)
                TextureName = nil,         -- Optional texture name for the marker (use nil if not needed)
                DrawOnEntities = false     -- Should the marker be drawn on entities (true/false)
            },

            Blip = {
                enabled = true,            -- Enable or disable the blip on the map
                id = 523,                  -- Blip ID (defines the type of blip icon)
                scale = 1.0,               -- Blip size/scale
                color = 75,                -- Blip color (ID for the color)
                Name = "Welcomecar",       -- Blip name (shown on the map)
            }
        },
        -- Add more positions here as needed
    },
}

Config.Vehicles = {
    [1] = { model = "cavalcade2" },  -- First vehicle option (model name)
    [2] = { model = "exemplar" },    -- Second vehicle option (model name)
    [3] = { model = "tailgater2" }   -- Third vehicle option (model name)
}

Config.Plate = {
    UseSpace = false,                 -- Option to include a space between letters and numbers on the license plate (true/false)
    Letters = 3,                      -- Number of letters on the plate (e.g., 'ABCD' if set to 4)
    Numbers = 3,                      -- Number of numbers on the plate (e.g., '1234' if set to 4)
    LetterCharset = "ABCDEFGHIJKLMNOPQRSTUVWXYZ", -- The set of characters that can be used for the letter portion of the plate
    NumberCharset = "0123456789",     -- The set of digits that can be used for the number portion of the plate
    MaxPlates = 9999999               -- Maximum number of unique plates that can be generated (affects randomness and uniqueness)
}

function ShowHelpNotify(msg, E)
    ESX.ShowHelpNotification(msg, E)
    -- exports["rs_hud"]:HelpNotify(msg, E)
end  

function Notify(msg)
    TriggerEvent('esx:showNotification', msg)
    -- TriggerEvent('rs_notify', 'Welcomecar', msg , 'info', 5000)
end

2. Configure sv_config.lua

In this section, you will configure the server-side configuration file sv_config.lua. Follow the instructions below to set it up according to your framework (ESX or QBcore)


3. Select Languages in sh_languages.lua

In the sh_languages.lua file, you can manage all available language options. To set your preferred language and its corresponding translations, navigate to cl_config.lua and specify your desired locale. This allows you to customize the different languages.

Last updated