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.


chevron-rightqs-yacht/config/main.luahashtag
--──────────────────────────────────────────────────────────────────────────────
--  Quasar Store · Configuration Guidelines
--──────────────────────────────────────────────────────────────────────────────
--  This configuration file defines all adjustable parameters for qs-yacht.
--  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, da, de, el, en, es, fa, fr, hi, hu, it, ja, ko, nl, pt, ro, ru, tr, zh-CN
Config.Path                        = 'nui://qs-yacht/web/'    -- [ADV]  Base NUI path (keep if you didn't move /web).
Config.ImagePath                   = Config.Path .. 'images/' -- [ADV]  Asset path for images.

--──────────────────────────────────────────────────────────────────────────────
-- 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]
Config.QBX                         = GetResourceState('qbx_core') == 'started'

--──────────────────────────────────────────────────────────────────────────────
-- 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',
    ['codem-inventory'] = 'codem'
}

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

--──────────────────────────────────────────────────────────────────────────────
-- Decoration & Stash Configuration                                            [EDIT]
-- [INFO] Controls decorating access and stash system per property.
--──────────────────────────────────────────────────────────────────────────────
Config.SpawnDistance               = 100.0 -- [EDIT] Object spawn radius (meters)
Config.MaximumDistanceForDecorate  = 350.0 -- [EDIT] Max decorate distance or false to disable
Config.DecorateOnlyAccessForOwner  = true  -- [EDIT] Only owner can decorate

Config.DefaultStashData            = {     -- [EDIT] Default stash size for houses
    maxweight = 1000000,
    slots = 30,
}

Config.Music                       = 'decorate' -- [EDIT] false to disable music
Config.MusicVolume                 = 0.05       -- [EDIT] Music volume (0.0–1.0)

--──────────────────────────────────────────────────────────────────────────────
-- 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.
    }
}

-- to disable the sound set this to false
Config.Sound                       = 'https://www.youtube.com/watch?v=EYekpTUKLNU&list=PLRBp0Fe2GpgkDw2aMG2lM5heA8cbLvOoN&index=14'
Config.SoundVolumes                = {
    base = 1.0,
    captain = 0.02,
    interior = 0.02,
}

Config.Panners                     = {
    base = {
        panningModel = 'HRTF',
        refDistance = 1.0,
        rolloffFactor = 1.2,
        distanceModel = 'exponential',
    },
    captain = {
        panningModel = 'HRTF',
        refDistance = 1.0,
        rolloffFactor = 3.5,
        distanceModel = 'exponential',
    },
    interior = {
        panningModel = 'HRTF',
        refDistance = 1.0,
        rolloffFactor = 3.5,
        distanceModel = 'exponential',
    },
}

--──────────────────────────────────────────────────────────────────────────────
-- Fallback Outfit (Naked Safety)                                              [EDIT]
-- [INFO] Applied if outfit fails to load or player is considered "naked".
--──────────────────────────────────────────────────────────────────────────────
Config.NakedPlayerClothes          = { -- [EDIT]
    Male = {
        ['hat']     = { item = 0, texture = 0 },
        ['glass']   = { item = 0, texture = 0 },
        ['mask']    = { item = 0, texture = 0 },
        ['t-shirt'] = { item = 15, texture = 0 },
        ['torso2']  = { item = 15, texture = 0 },
        ['arms']    = { item = 15, texture = 0 },
        ['pants']   = { item = 14, texture = 0 },
        ['shoes']   = { item = 34, texture = 0 },
        ['vest']    = { item = 0, texture = 0 }
    },
    Female = {
        ['hat']     = { item = 0, texture = 0 },
        ['glass']   = { item = 0, texture = 0 },
        ['mask']    = { item = 0, texture = 0 },
        ['t-shirt'] = { item = 2, texture = 0 },
        ['torso2']  = { item = 18, texture = 0 },
        ['arms']    = { item = 15, texture = 0 },
        ['pants']   = { item = 19, texture = 0 },
        ['shoes']   = { item = 35, texture = 0 },
        ['vest']    = { item = 0, texture = 0 }
    }
}

Config.MaxYachtsPerPlayer          = 1
Config.MoneyType                   = 'bank'

Config.TebexPayment                = {
    enabled = false,
    enableBuyWithoutTebex = true, -- If true, players can buy yachts without tebex payment. With their own money. But they need to have enough money.
    bypassMaxOwnedCount = true,   -- If true, players can buy yachts even if they have the maximum number of yachts.

    -- If true, modifications will be free after the tebex transaction id is passed.
    -- But if you set false, the main price will be free and additional modifications prices need to be paid.
    modificationsFreeWithTebex = true,

    -- If you set this to 1, players can only buy 1 yacht per transaction id.
    maxYachtPerTransaction = 1
}

Config.Shops                       = {
    {
        location = vec4(-2185.0, -380.0, 12.3, 0.0),
        distance = 4.0,
        pedModel = 'a_f_m_bevhills_01',
        animation = {
            dict = 'mini@repair',
            name = 'fixing_a_ped',
        },
        blip = {
            sprite = 455,
            color = 3,
            scale = 0.8,
            name = 'Yacht Shop',
        }
    }
}

Config.ShopDefaultCamera           = {
    fov = 100.0,         -- [EDIT] Camera field of view
    distance = 50.0,     -- [EDIT] Camera distance from yacht (meters)
    heightOffset = 15.0, -- [EDIT] Camera height offset from yacht center
    rotationSpeed = 2.0, -- [EDIT] Mouse rotation sensitivity
    minPitch = -30.0,    -- [EDIT] Minimum vertical angle (degrees)
    maxPitch = 30.0,     -- [EDIT] Maximum vertical angle (degrees)
}

Config.ShopDefaultPrice            = 5000000 -- Base price on yacht. Modifications prices are added to this price.

-- Yacht sell calculation is: (modifications price + base price) * Config.YachtSellPercentage
Config.YachtSellPercentage         = 0.7 -- Percentage of total yacht value returned when selling to bank (0.7 = 70%)

Config.ModificationPrices          = {
    option = {
        { id = 0, label = 'The Orion',    price = 1000 },
        { id = 1, label = 'The Pisces',   price = 50000 },
        { id = 2, label = 'The Aquarius', price = 100000 },
    },
    tint = {
        { id = 0,  label = 'White',            price = 50000 },
        { id = 1,  label = 'Pearl White',      price = 50000 },
        { id = 2,  label = 'Silver',           price = 50000 },
        { id = 3,  label = 'Metallic Silver',  price = 50000 },
        { id = 4,  label = 'Blue Silver',      price = 50000 },
        { id = 5,  label = 'Rolled Steel',     price = 50000 },
        { id = 6,  label = 'Shadow Silver',    price = 50000 },
        { id = 7,  label = 'Midnight Silver',  price = 50000 },
        { id = 8,  label = 'Cast Iron Silver', price = 50000 },
        { id = 9,  label = 'Red',              price = 50000 },
        { id = 10, label = 'Torino Red',       price = 50000 },
        { id = 11, label = 'Formula Red',      price = 50000 },
        { id = 12, label = 'Lava Red',         price = 50000 },
        { id = 13, label = 'Blaze Red',        price = 50000 },
        { id = 14, label = 'Grace Red',        price = 50000 },
        { id = 15, label = 'Garnet Red',       price = 50000 },
    },
    interiorLighting = {
        { id = 0, label = 'Light Blue',  price = 75000 }, -- Açık Mavi
        { id = 1, label = 'White',       price = 75000 }, -- Beyaz
        { id = 2, label = 'Powder Blue', price = 75000 }, -- Buz Mavisi
        { id = 3, label = 'Purple',      price = 75000 }, -- Purple
    },
    exteriorLED = {
        { id = 0, label = 'Orange', price = 75000 }, -- Turuncu
        { id = 1, label = 'Blue',   price = 75000 }, -- Mavi
        { id = 2, label = 'Pink',   price = 75000 }, -- Pembe
        { id = 3, label = 'Green',  price = 75000 }, -- Yeşil
    },
    railing = {
        { id = 0, label = 'Chrome Fittings', price = 200000 },
        { id = 1, label = 'Gold Fittings',   price = 200000 },
    },
    flag = {
        { id = 0,  label = 'Scotland',       price = 150000 },
        { id = 1,  label = 'USA',            price = 150000 },
        { id = 2,  label = 'France',         price = 150000 },
        { id = 3,  label = 'Italy',          price = 150000 },
        { id = 4,  label = 'Sweden',         price = 150000 },
        { id = 5,  label = 'Argentina',      price = 150000 },
        { id = 6,  label = 'European Union', price = 150000 },
        { id = 7,  label = 'Finland',        price = 150000 },
        { id = 8,  label = 'Netherlands',    price = 150000 },
        { id = 9,  label = 'Portugal',       price = 150000 },
        { id = 10, label = 'South Korea',    price = 150000 },
        { id = 11, label = 'Australia',      price = 150000 },
        { id = 12, label = 'Germany',        price = 150000 },
        { id = 13, label = 'Switzerland',    price = 150000 },
        { id = 14, label = 'Belgium',        price = 150000 },
        { id = 15, label = 'Turkey',         price = 150000 },
        { id = 16, label = 'China',          price = 150000 },
        { id = 17, label = 'Hungary',        price = 150000 },
        { id = 18, label = 'New Zealand',    price = 150000 },
        { id = 19, label = 'Puerto Rico',    price = 150000 },
        { id = 20, label = 'Brazil',         price = 150000 },
        { id = 21, label = 'Japan',          price = 150000 },
        { id = 22, label = 'Jamaica',        price = 150000 },
        { id = 23, label = 'Mexico',         price = 150000 },
        { id = 24, label = 'Ireland',        price = 150000 },
        { id = 25, label = 'Croatia',        price = 150000 },
        { id = 26, label = 'Israel',         price = 150000 },
        { id = 27, label = 'Nigeria',        price = 150000 },
        { id = 28, label = 'Slovakia',       price = 150000 },
        { id = 29, label = 'Spain',          price = 150000 },
        { id = 30, label = 'Colombia',       price = 150000 },
        { id = 31, label = 'Austria',        price = 150000 },
        { id = 32, label = 'Wales',          price = 150000 },
        { id = 33, label = 'Czech Republic', price = 150000 },
        { id = 34, label = 'Liechtenstein',  price = 150000 },
        { id = 35, label = 'Palestine',      price = 150000 },
        { id = 36, label = 'South Africa',   price = 150000 },
        { id = 37, label = 'Canada',         price = 150000 },
        { id = 38, label = 'United Kingdom', price = 150000 },
        { id = 39, label = 'Norway',         price = 150000 },
        { id = 40, label = 'Russia',         price = 150000 },
        { id = 41, label = 'England',        price = 150000 },
        { id = 42, label = 'Denmark',        price = 150000 },
        { id = 43, label = 'Malta',          price = 150000 },
        { id = 44, label = 'Poland',         price = 150000 },
        { id = 45, label = 'Slovenia',       price = 150000 },
    },
    access = {
        { id = 0, label = 'Public',  price = 0 },
        { id = 1, label = 'Private', price = 0 },
    },
}

Config.ShopTime                    = 23

Config.YachtVehicles               = {
    enabled = true,
    respawnTime = 300000,
    spawnDistance = 400.0,
    vehicles = {
        {
            offset = vec3(-0.2508, -32.3, 0.8727),
            heading = 0.0,
            clearRadius = 3.5,
            spawnDistance = 400.0,
            livery = -1,
            flags = {
                dontSpawnIfPlayerInTaxiHeli = true,
            },
            -- Option-specific models
            models = {
                [0] = nil,
                [1] = 'swift2',
                [2] = 'supervolito2',
            },
        },
        -- Boat 1
        {
            offset = vec3(11.25, -55.8404, -11.0),
            heading = 340.8939,
            clearRadius = 2.4,
            spawnDistance = 300.0,
            livery = -1,
            flags = {
                setAnchor = true,
            },
            models = {
                [0] = 'tropic2',
                [1] = 'dinghy4',
                [2] = 'dinghy4',
            },
        },
        --  Jetski 1
        {
            offset = vec3(6.75, -63.0, -11.0),
            heading = 206.26,
            clearRadius = 1.4,
            spawnDistance = 200.0,
            livery = -1,
            flags = {
                setAnchor = true,
            },
            models = {
                [0] = 'seashark3',
                [1] = 'seashark3',
                [2] = 'seashark3',
            },
        },
        -- Jetski 2
        {
            offset = vec3(4.5, -63.0, -11.0),
            heading = 206.26,
            clearRadius = 1.4,
            spawnDistance = 200.0,
            livery = -1,
            flags = {
                setAnchor = true,
            },
            models = {
                [0] = nil,
                [1] = nil,
                [2] = 'seashark3',
            },
        },
        -- Boat 2
        {
            offset = vec3(-11.25, -55.8404, -11.0),
            heading = 20.0,
            clearRadius = 2.4,
            spawnDistance = 300.0,
            livery = -1,
            flags = {
                setAnchor = true,
            },
            models = {
                [0] = nil,        -- Option 0: Don't spawn (PYVF_DONT_SPAWN)
                [1] = 'speeder2', -- Option 1: SPEEDER2
                [2] = 'toro2',    -- Option 2: TORO2
            },
        },
        -- Jetski 3
        {
            offset = vec3(-4.5, -63.0, -11.0),
            heading = 153.7463,
            clearRadius = 1.4,
            spawnDistance = 200.0,
            livery = -1,
            flags = {
                setAnchor = true,
            },
            models = {
                [0] = nil,
                [1] = nil,
                [2] = 'seashark3',
            },
        },
        -- Jetski 4
        {
            offset = vec3(-6.75, -63.0, -11.0),
            heading = 153.7463,
            clearRadius = 1.4,
            spawnDistance = 200.0,
            livery = -1,
            flags = {
                setAnchor = true,
            },
            models = {
                [0] = nil,
                [1] = 'seashark3',
                [2] = 'seashark3',
            },
        },
    },
}

Config.FurnitureLimits             = {
    normal = 50,  -- Default limit
    upgrade = 150 -- Upgrade Limit
}

Config.DefaultLightIntensity       = 20.0 -- [EDIT] Default light intensity inside shells
Config.DefaultRequestModelTimeout  = 15000
Config.SellObjectCommision         = 0.3  -- [EDIT] Furniture sale commission (0.30 = 30%)

--──────────────────────────────────────────────────────────────────────────────
-- Yacht Upgrades Configuration                                                 [EDIT]
-- [INFO] Available upgrades for yachts
--──────────────────────────────────────────────────────────────────────────────
Config.Upgrades                    = {
    {
        name = 'furniture',
        title = 'Furniture Upgrade',
        description = 'Increase furniture limit from 50 to 150 items',
        price = 50000
    },
    {
        name = 'camera',
        title = 'Security Camera System',
        description = 'Install security camera system to monitor your yacht (up to 12 cameras)',
        price = 75000
    }
}

--──────────────────────────────────────────────────────────────────────────────
-- Shell / IPL / MLO Editor Controls                                           [EDIT]
-- [INFO] Keybinds used in edit modes for interiors and placement tools.
--──────────────────────────────────────────────────────────────────────────────
ActionControls                     = {
    leftClick              = { label = 'Left Click', codes = { 24 } },
    forward                = { label = 'Forward +/-', codes = { 33, 32 } },
    right                  = { label = 'Right +/-', codes = { 35, 34 } },
    up                     = { label = 'Up +/-', codes = { 52, 51 } },
    add_point              = { label = 'Add Point', codes = { 24 } },
    undo_point             = { label = 'Undo Last', codes = { 25 } },
    rotate_z               = { label = 'RotateZ +/-', codes = { 20, 73 } },
    rotate_z_scroll        = { label = 'RotateZ +/-', codes = { 17, 16 } },
    offset_z               = { label = 'Offset Z +/-', codes = { 44, 46 } },
    boundary_height        = { label = 'Z Boundary +/-', codes = { 20, 73 } },
    done                   = { label = 'Done', codes = { 191 } },
    cancel                 = { label = 'Cancel', codes = { 194 } },
    arrow_left             = { label = 'Previous', codes = { 174 } },
    arrow_right            = { label = 'Next', codes = { 175 } },
    -- Decorate (Modern Mode)
    place_object_on_ground = { label = 'Place Object on Ground', codes = { 47 } },
    toggle_free_mode       = { label = 'Toggle Free Mode', codes = { 167 } },
    toggle_cursor          = { label = 'Toggle Cursor', codes = { 166 } },
    toggle_editor_mode     = { label = 'Toggle Translate/Rotate', codes = { 311 } },
    toggle_gizmo_mode      = { label = 'Toggle Gizmo Mode', codes = { 244 } },
    toggle_free_camera     = { label = 'Toggle Free Camera', codes = { 170 } },
    focus_free_camera      = { label = 'Focus Object', codes = { 49 } },
    zoom                   = { label = 'Zoom +/-', codes = { 17, 16 } },

    -- DEPREACTED NEED TO CHECK
    set_any                = { label = 'Set', codes = { 24 } },
    set_position           = { label = 'Set Position', codes = { 24 } },
    add_garage             = { label = 'Add Garage', codes = { 24 } },
    increase_z             = { label = 'Z Boundary +/-', codes = { 180, 181 } },
    decrease_z             = { label = 'Z Boundary +/-', codes = { 21, 180, 181 } },
    change_player          = { label = 'Player +/-', codes = { 82, 81 } },
    change_shell           = { label = 'Change Shell +/-', codes = { 189, 190 } },
    select_player          = { label = 'Select Player', codes = { 191 } },
    change_outfit          = { label = 'Outfit +/-', codes = { 82, 81 } },
    delete_outfit          = { label = 'Delete Outfit', codes = { 178 } },
    select_vehicle         = { label = 'Vehicle +/-', codes = { 82, 81 } },
    spawn_vehicle          = { label = 'Spawn Vehicle', codes = { 191 } },
    leftApt                = { label = 'Previous Apartment', codes = { 174 } },
    rightApt               = { label = 'Next Apartment', codes = { 175 } },
    testPos                = { label = 'Test Pos', codes = { 47 } },
}

Config.DoorDistance                = 1.5   -- [EDIT] Interaction distance for doors
Config.DoorDuplicateDistance       = 3.0   -- [EDIT] Merge doors if closer than this

Config.DynamicDoors                = true  -- [EDIT] Enable dynamic doors?
Config.CreditToggleActiveInDefault = false -- [EDIT] Default credit toggle state

--──────────────────────────────────────────────────────────────────────────────
-- Free Camera Options                                                          [EDIT]
-- [INFO] Tuning for editor/preview camera movement.
--──────────────────────────────────────────────────────────────────────────────
CameraOptions                      = { -- [EDIT]
    lookSpeedX  = 1000.0,              -- Horizontal camera speed.
    lookSpeedY  = 1000.0,              -- Vertical camera speed.
    moveSpeed   = 20.0,                -- Free-move speed.
    climbSpeed  = 10.0,                -- Up/down speed.
    rotateSpeed = 20.0,                -- Rotation speed.
}

--──────────────────────────────────────────────────────────────────────────────
-- Effect Durations                                                             [EDIT]
-- [INFO] Duration for bong and alcohol effects in milliseconds.
-- [INFO] Default: 600000 (10 minutes). Adjust as needed.
--──────────────────────────────────────────────────────────────────────────────
Config.EffectDurations             = {
    bong = 600000,    -- [EDIT] Bong effect duration (milliseconds) - Default: 10 minutes
    alcohol = 600000, -- [EDIT] Alcohol effect duration (milliseconds) - Default: 10 minutes
}

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