Configuration

This section includes all configurable files for the selected script. Most settings are configured automatically, but each config.lua file contains a header comment explaining the purpose and usage of every configuration type. Be sure to read the header of each file carefully to fully understand how to customize and adapt the system for QBCORE, ESX, or standalone environments, ensuring seamless integration with your server.


qs-shops-creator/config/main.lua
--──────────────────────────────────────────────────────────────────────────────
--  Quasar Store · Configuration Guidelines
--──────────────────────────────────────────────────────────────────────────────
--  This configuration file defines all adjustable parameters for qs-shops-creator.
--  Comments are standardized to indicate which parts are safe to edit.
--
--  • [EDIT] – Safe to modify. Adjust as needed for your server.
--  • [INFO] – Explains purpose or behavior of a variable/block.
--  • [ADV]  – Advanced settings. Edit only if you understand the logic.
--  • [CORE] – Core functionality. Avoid changes unless you are a developer.
--  • [AUTO] – Automatically handled. Never modify manually.
--
--  Always make a backup before editing configuration files.
--  Documentation: https://docs.quasar-store.com/
--──────────────────────────────────────────────────────────────────────────────

--──────────────────────────────────────────────────────────────────────────────
-- Language Selection                                                          [EDIT]
-- [INFO] Select your main language. Files are located in locales/*.
--        You can create your own locale if it doesn’t exist yet.
--──────────────────────────────────────────────────────────────────────────────
Config = {}

Config.Locale = 'en' -- [EDIT] Language code. Available: ar, bg, cs, da, de, el, en, es, fa, fr, hi, hu, it, ja, ko, nl, no, pl, pt, ro, ru, sl, sv, th, tr, zh-CN

--──────────────────────────────────────────────────────────────────────────────
-- Framework Detection                                                         [AUTO]
-- [INFO] Automatically detects your framework (ESX or QBCore).
-- [INFO] If renamed, edit the framework name here or create adapters inside:
--        client/custom/framework/* and server/custom/framework/*
--──────────────────────────────────────────────────────────────────────────────
local frameworks = {
    ['es_extended'] = 'esx',
    ['qb-core'] = 'qb',
    ['qbx_core'] = 'qb'
}

Config.Framework = DependencyCheck(frameworks) or 'none' -- [AUTO]

--──────────────────────────────────────────────────────────────────────────────
-- Inventory Detection                                                         [AUTO]
-- [INFO] Detects which inventory system is running.
-- [INFO] To integrate another, create an adapter inside client/custom/inventory/.
--──────────────────────────────────────────────────────────────────────────────
local inventories = {
    ['qs-inventory'] = 'qs',
    ['ox_inventory'] = 'ox',
    ['qb-inventory'] = 'qb',
    ['tgiann-inventory'] = 'tgiann'
}

Config.Inventory = DependencyCheck(inventories) or 'standalone' -- [AUTO]

--──────────────────────────────────────────────────────────────────────────────
-- Default Stash Data                                                          [EDIT]
-- [INFO] Defines the base stash capacity for created shops.
--──────────────────────────────────────────────────────────────────────────────
Config.DefaultStashData = {
    maxweight = 1000000, -- [EDIT] Maximum weight capacity.
    slots = 30,          -- [EDIT] Total number of item slots.
}

--──────────────────────────────────────────────────────────────────────────────
-- Currency & Intl Formatting                                                  [EDIT]
-- [INFO] Purely visual. Affects how prices/dates appear in the NUI.
--──────────────────────────────────────────────────────────────────────────────
Config.Intl = {
    locales = 'en-US',            -- [EDIT] Format locale (e.g. en-US, pt-BR, es-ES, fr-FR, etc.)
    options = {
        style = 'currency',       -- [EDIT] Display style: 'decimal', 'currency', 'percent', 'unit'
        currency = 'USD',         -- [EDIT] Currency code (e.g. USD, EUR, BRL, RUB, CNY)
        minimumFractionDigits = 0 -- [EDIT] Number of decimal places shown.
    }
}

--──────────────────────────────────────────────────────────────────────────────
-- Creator Job Permissions                                                     [EDIT]
-- [INFO] Define which jobs (and grades) can access the shop creator.
-- [INFO] Set grade=false to allow all grades.
--──────────────────────────────────────────────────────────────────────────────
Config.CreatorJobs = {
    {
        job = 'police',
        grade = { 1, 2, 3 } -- [EDIT] Specific grades allowed.
    },
    {
        job = 'ambulance',
        grade = false -- [EDIT] All grades allowed.
    }
}

--──────────────────────────────────────────────────────────────────────────────
-- Targeting Settings                                                          [EDIT]
-- [INFO] Define interaction method and hitbox dimensions.
--──────────────────────────────────────────────────────────────────────────────
Config.TargetWidth = 5.0  -- [EDIT] Interaction area width.
Config.TargetHeight = 5.0 -- [EDIT] Interaction area height.
Config.UseTarget = false  -- [EDIT] true = qb-target/ox_target | false = disable target system.

--──────────────────────────────────────────────────────────────────────────────
-- Creator Core Settings                                                       [EDIT]
-- [INFO] Configure minimum limits and editor behaviors.
--──────────────────────────────────────────────────────────────────────────────
Config.MinPointLength = 70.0 -- [EDIT] Minimum polygon length for area creation.

--──────────────────────────────────────────────────────────────────────────────
-- Free Mode Controls                                                          [EDIT]
-- [INFO] Defines movement and rotation keys used in creation mode.
--──────────────────────────────────────────────────────────────────────────────
Config.FreeModeKeys = {
    ChangeKey = Keys['LEFTCTRL'],       -- [EDIT] Toggle free mode controls.

    MoreSpeed = Keys['.'],              -- [EDIT] Increase movement speed.
    LessSpeed = Keys[','],              -- [EDIT] Decrease movement speed.

    MoveToTop = Keys['TOP'],            -- [EDIT] Move object upward.
    MoveToDown = Keys['DOWN'],          -- [EDIT] Move object downward.

    MoveToForward = Keys['TOP'],        -- [EDIT] Move object forward.
    MoveToBack = Keys['DOWN'],          -- [EDIT] Move object backward.
    MoveToRight = Keys['RIGHT'],        -- [EDIT] Move object to the right.
    MoveToLeft = Keys['LEFT'],          -- [EDIT] Move object to the left.

    RotateToTop = Keys['6'],            -- [EDIT] Rotate upward.
    RotateToDown = Keys['7'],           -- [EDIT] Rotate downward.
    RotateToLeft = Keys['8'],           -- [EDIT] Rotate to the left.
    RotateToRight = Keys['9'],          -- [EDIT] Rotate to the right.

    TiltToTop = Keys['Z'],              -- [EDIT] Tilt upward.
    TiltToDown = Keys['X'],             -- [EDIT] Tilt downward.
    TiltToLeft = Keys['C'],             -- [EDIT] Tilt left.
    TiltToRight = Keys['V'],            -- [EDIT] Tilt right.

    StickToTheGround = Keys['LEFTALT'], -- [EDIT] Snap object to ground.
}

--──────────────────────────────────────────────────────────────────────────────
-- Creator Default Icons                                                       [EDIT]
-- [INFO] Icon library used in the creator UI.
--──────────────────────────────────────────────────────────────────────────────
Config.CreatorDefaultIcons = {
    'FaStore', 'Fa6Gun', 'FaWineBottle', 'FaNotesMedical', 'FaCookieBite', 'FaWallet',
    'FaCar', 'FaHome', 'FaTshirt', 'FaGamepad', 'FaBook', 'FaMusic', 'FaCamera',
    'FaTools', 'FaGift', 'FaHeart', 'FaStar', 'FaArchive'
}

--──────────────────────────────────────────────────────────────────────────────
-- Creator Default Categories                                                  [EDIT]
-- [INFO] Defines default product categories and their UI styles.
--──────────────────────────────────────────────────────────────────────────────
Config.CreatorDefaultCategories = {
    {
        id = 'weapons',
        name = 'Weapons',
        description = 'Firearms, melee weapons, and ammunition',
        color = 'from-red-500/20 to-orange-500/20',
        borderColor = 'border-red-500/30',
        icon = 'Fa6Gun'
    },
    {
        id = 'food',
        name = 'Food & Drinks',
        description = 'Restaurant items, snacks, and beverages',
        color = 'from-green-500/20 to-emerald-500/20',
        borderColor = 'border-green-500/30',
        icon = 'FaCookieBite'
    },
    {
        id = 'medical',
        name = 'Medical',
        description = 'Health supplies, medicines, and medical equipment',
        color = 'from-blue-500/20 to-cyan-500/20',
        borderColor = 'border-blue-500/30',
        icon = 'FaNotesMedical'
    },
    {
        id = 'clothing',
        name = 'Clothing',
        description = 'Apparel, accessories, and fashion items',
        color = 'from-purple-500/20 to-pink-500/20',
        borderColor = 'border-purple-500/30',
        icon = 'FaTshirt'
    },
    {
        id = 'vehicles',
        name = 'Vehicles',
        description = 'Cars, motorcycles, and vehicle accessories',
        color = 'from-yellow-500/20 to-amber-500/20',
        borderColor = 'border-yellow-500/30',
        icon = 'FaCar'
    },
    {
        id = 'electronics',
        name = 'Electronics',
        description = 'Phones, computers, and electronic devices',
        color = 'from-indigo-500/20 to-blue-500/20',
        borderColor = 'border-indigo-500/30',
        icon = 'FaGamepad'
    },
    {
        id = 'tools',
        name = 'Tools & Equipment',
        description = 'Work tools, equipment, and hardware',
        color = 'from-teal-500/20 to-cyan-500/20',
        borderColor = 'border-teal-500/30',
        icon = 'FaTools'
    },
    {
        id = 'misc',
        name = 'Miscellaneous',
        description = 'General items and miscellaneous products',
        color = 'from-pink-500/20 to-rose-500/20',
        borderColor = 'border-pink-500/30',
        icon = 'FaStore'
    }
}

--──────────────────────────────────────────────────────────────────────────────
-- Editor / Action Controls                                                    [EDIT]
-- [INFO] Defines the control bindings used in polygon/creator editing mode.
--──────────────────────────────────────────────────────────────────────────────
ActionControls = {
    leftClick = { label = 'Left Click', codes = { 24 } },
    forward = { label = 'Forward +/-', codes = { 33, 32 } },            -- [INFO] Moves the object forward/backward.
    right = { label = 'Right +/-', codes = { 35, 34 } },                -- [INFO] Moves the object left/right.
    up = { label = 'Up +/-', codes = { 52, 51 } },                      -- [INFO] Adjusts vertical positioning.
    add_point = { label = 'Add Point', codes = { 24 } },                -- [INFO] Adds a new polygon point.
    undo_point = { label = 'Undo Last', codes = { 25 } },               -- [INFO] Reverts the last added point.
    rotate_z = { label = 'RotateZ +/-', codes = { 20, 73 } },           -- [INFO] Rotates the object around Z-axis.
    rotate_z_scroll = { label = 'RotateZ +/-', codes = { 17, 16 } },    -- [INFO] Rotates using scroll input.
    offset_z = { label = 'Offset Z +/-', codes = { 44, 46 } },          -- [INFO] Increases vertical offset.
    boundary_height = { label = 'Z Boundary +/-', codes = { 20, 73 } }, -- [INFO] Adjusts the Z-axis boundary.
    done = { label = 'Done', codes = { 191 } },                         -- [INFO] Confirms and finalizes creation.
    cancel = { label = 'Cancel', codes = { 194 } },                     -- [INFO] Cancels the current action.
}

--──────────────────────────────────────────────────────────────────────────────
-- Camera Options                                                              [EDIT]
-- [INFO] Adjusts free-camera movement speed and sensitivity.
--──────────────────────────────────────────────────────────────────────────────
CameraOptions = {
    lookSpeedX = 1000.0, -- [EDIT] Horizontal camera speed.
    lookSpeedY = 1000.0, -- [EDIT] Vertical camera speed.
    moveSpeed = 20.0,    -- [EDIT] General camera movement speed.
    climbSpeed = 10.0,   -- [EDIT] Vertical (up/down) speed.
    rotateSpeed = 20.0,  -- [EDIT] Camera rotation speed.
}

--──────────────────────────────────────────────────────────────────────────────
-- Debug Mode                                                                  [EDIT]
-- [INFO] Enables or disables verbose console logging. Keep off in production.
--──────────────────────────────────────────────────────────────────────────────
Config.Debug = true -- [EDIT]