Config Files

The script is fully configurable, allowing complete customization of its behavior and features. Below is a list of configuration files included in the resource.

op-multicharacter/config/MainConfig.lua

-- ──────────────────────────────────────────────────────────────────────────────
-- Dependency Check Helper                                                     
-- (Information) β–Ί Returns the first matching started resource alias from provided table.
-- (Information) β–Ί Used by Clothing / Notify detection above.
-- ──────────────────────────────────────────────────────────────────────────────
function scriptCheck(data)            -- Do not modify unless you know what you're doing.
    for k, v in pairs(data) do
        if GetResourceState(k):find('started') ~= nil then
            return v
        end
    end
    return false
end

-- ─────────────────────────────────────────────────────────────────────────
-- OTHERPLANET / OP Multicharacter - Main Configuration File
-- (Information) β–Ί This file controls language, clothing integration, currency,
--                 spawn selector, starter items, notifications and scenes.
-- (Information) β–Ί Do not rename fields or change structure unless you know
--                 exactly how the script reads this config.
-- ─────────────────────────────────────────────────────────────────────────

Config = {}

-- ─────────────────────────────────────────────────────────────────────────
-- Locale & Debug                                                             
-- (Information) β–Ί Locale controls which translation file is loaded.
-- (Information) β–Ί Debug enables extra prints/logs for troubleshooting.
-- ─────────────────────────────────────────────────────────────────────────
Config.Locale = "en" -- Supported: EN
Config.Debug  = true

-- ─────────────────────────────────────────────────────────────────────────
-- Clothing System Detection                                                  
-- (Information) β–Ί Automatically detects which clothing/appearance system you use.
-- (Information) β–Ί Add your resource name and internal alias to `availableClothing`
--                 if you want to support a new clothing script.
-- (Information) β–Ί Following clothing scripts will not start cutscene/spawn selector after character created: tgiann-clothing
-- ─────────────────────────────────────────────────────────────────────────
local availableClothing = {
    ['skinchanger']         = "skinchanger",
    ['crm-appearance']      = "crm-appearance",
    ['fivem-appearance']    = "fivem-appearance",
    ['illenium-appearance'] = "illenium-appearance",
    ['qb-clothing']         = "qb-clothing",
    ['rcore_clothing']      = "rcore_clothing",
    ['tgiann-clothing']     = "tgiann-clothing",
}
Config.Clothing = scriptCheck(availableClothing) or "none"

-- ─────────────────────────────────────────────────────────────────────────
-- Notify System Detection                                                  
-- (Information) β–Ί Automatically detects which notify system you use.
-- (Information) β–Ί Add your resource name and internal alias to `notifyScripts`
--                 if you want to support a new notify script
-- ─────────────────────────────────────────────────────────────────────────
local notifyScripts = { -- Notify libraries detection
    ['okokNotify'] = "okokNotify",
    ['vms_notify'] = "vms_notify",
    ['ox_lib'] = "ox_lib",
    ['brutal_notify'] = "brutal_notify",
    ['op-hud'] = "op_hud",
}
Config.Notify = scriptCheck(notifyScripts) or "none" -- Notify system: none / ESX / QBCORE / QBOX or auto detected from list 'notifyScripts'

-- ─────────────────────────────────────────────────────────────────────────
-- Currency Formatting                                                       
-- (Information) β–Ί Visual currency format used in UI (JS Intl.NumberFormat).
-- (Information) β–Ί Does not change actual economy, only how numbers are shown.
-- ─────────────────────────────────────────────────────────────────────────
Config.CurrencySettings = {
    -- https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat
    currency = "USD",
    style    = "currency",
    format   = "en-US"
}

-- ─────────────────────────────────────────────────────────────────────────
-- Start Cutscene                                                            
-- (Information) β–Ί Enables or disables the initial intro cutscene for players.
-- ─────────────────────────────────────────────────────────────────────────
Config.EnableStartCutScene = true
Config.CutSceneData = {
    welcomeTextHeader = "OTHERPLANET",
    welcomeTextDesc = "Welcome on the best server!"
}

-- ─────────────────────────────────────────────────────────────────────────
-- Player Switch Function                                                           
-- (Information) β–Ί Enables or disables the player switch (Map zoom and zoom-out).
-- (Information) β–Ί If you disabled Spawn Selector you can also adjust start
-- coordinates here!
-- ─────────────────────────────────────────────────────────────────────────
Config.SwitchPlayer = {
    enable = true, -- This will work only if spawn selector is disabled!
    startCoords = vec4(-1037.6252, -2737.7544, 19.1693, 326.5721), -- This will work only if spawn selector is disabled!
    disableSwitchOnNewCharacter = true, -- Disables switch on new character
}

-- ─────────────────────────────────────────────────────────────────────────
-- Spawn Selector                                                             
-- (Information) β–Ί Controls the spawn menu that appears after character select.
-- (Information) β–Ί "isLastLocation = true" will use last saved coordinates.
-- (Information) β–Ί "spawnCoords = vec4(...)" defines static spawn locations.
-- ─────────────────────────────────────────────────────────────────────────
Config.SpawnSelector = {
    enable = true, 
    locations = {
        ["1"] = {
            isLastLocation = true,
            spawnCoords    = false,
            label          = "Last Location",
            image          = "https://img.gta5-mods.com/q95/images/felix-s-movie-like-reshade/3d87bc-GTA52019-11-0912-35-04_Easy-Resize.com.jpg"
        },
        ["2"] = {
            isLastLocation = false,
            spawnCoords    = vec4(-268.8336, -956.3636, 30.2231, 205.1087),
            label          = "Los Santos",
            image          = "https://cdn.mos.cms.futurecdn.net/9QfCTPwV3DkPuUgBHrorom-1200-80.jpg"
        },
        ["3"] = {
            isLastLocation = false,
            spawnCoords    = vec4(-19.8265, 6497.2964, 30.5491, 51.6798),
            label          = "Paleto Bay",
            image          = "https://c4.wallpaperflare.com/wallpaper/143/671/687/grand-theft-auto-online-grand-theft-auto-v-mountain-chiliad-chiliad-mountain-state-wilderness-state-wilderness-paleto-bay-los-santos-wallpaper-preview.jpg"
        },
        ["4"] = {
            isLastLocation = false,
            spawnCoords    = vec4(1527.3490, 3774.9458, 33.5113, 193.8923),
            label          = "Sandy Shores",
            image          = "https://img.gta5-mods.com/q75/images/sandy-shores-remaster-ymap/c276b2-SandyShores1-min.png"
        },
    }
}

-- ─────────────────────────────────────────────────────────────────────────
-- Server Branding (UI Text & Logos)                                          
-- (Information) β–Ί Controls server name, description and logo in the UI.
-- ─────────────────────────────────────────────────────────────────────────
Config.ServerDetails = {
    serverName        = "OTHERPLANET",
    serverCreatorDesc = "Create your new character and start journey on the best FiveM server.",
    serverLogo        = "https://data.otherplanet.dev/img/op-white.png"
}

-- ─────────────────────────────────────────────────────────────────────────
-- Starter Items                                                              
-- (Information) β–Ί Optional items/money granted to new characters.
-- (Information) β–Ί Works separately from itemShop in Config.Misc.
-- ─────────────────────────────────────────────────────────────────────────
Config.StarterItems = {
    enable = false,
    list = {
        {
            type      = "item",
            nameSpawn = "bread",
            quanity   = 3
        },
        {
            type      = "money", -- money, bank
            nameSpawn = "",      -- leave blank
            quanity   = 5000
        }
    }
}

-- ─────────────────────────────────────────────────────────────────────────
-- Miscellaneous Settings                                                     
-- (Information) β–Ί General behaviour: notifications, character slots and
--                 optional item shop available on character creation.
-- ─────────────────────────────────────────────────────────────────────────
Config.Misc = {
    DefaultCharsAmount = 3,
    AllowCharacterDelete = true, 
    itemShop = {
        enable = true,
        money  = 6500, -- Starting budget for shop purchases
        items  = {
            {
                type      = "item",
                nameSpawn = "bread",
                label     = "Sandwich",
                price     = 500,
                maxQuanity = 5,
                image     = "https://data.otherplanet.dev/fivemicons/%5bfood%5d/hornsandwich.png",
            },
            {
                type      = "item",
                nameSpawn = "water",
                label     = "Water",
                price     = 250,
                maxQuanity = 5,
                image     = "https://data.otherplanet.dev/fivemicons/%5bfood%5d/water_bottle.png",
            },
            {
                type      = "item",
                nameSpawn = "phone",
                label     = "Phone",
                price     = 1500,
                maxQuanity = 1,
                image     = "https://data.otherplanet.dev/fivemicons/%5belectronics%5d/ifruit_blue.png",
            },
            {
                type      = "item",
                nameSpawn = "energydrink",
                label     = "Energy Drink",
                price     = 750,
                maxQuanity = 3,
                image     = "https://data.otherplanet.dev/fivemicons/%5bfood%5d/sprunk.png",
            },
            {
                type      = "car",
                nameSpawn = "blista",
                label     = "Blista",
                price     = 2000,
                maxQuanity = 1,
                image     = "https://cdn.majestic-files.com/public/master/static/img/vehicles/blista.png",
            },
            {
                type      = "car",
                nameSpawn = "bmx",
                label     = "BMX",
                price     = 800,
                maxQuanity = 1,
                image     = "https://cdn.majestic-files.com/public/master/static/img/vehicles/bmx.png",
            },
        }
    }
}

-- ─────────────────────────────────────────────────────────────────────────
-- Scenes Configuration                                                       
-- (Information) β–Ί Defines cinematic scenes used for character selection.
-- (Information) β–Ί Includes camera paths, characters placements, props,
--                 vehicles and weather presets per scene.
-- ─────────────────────────────────────────────────────────────────────────
Config.Scenes = {
    ["xmas"] = {
        SceneCoords = vec4(173.6660, -912.0629, 31.3267, 258.4043), -- Player will be teleported to this coords! This is really important.
        InitialCamTime          = 7.0,
        InitialCamCoords        = vec4(190.3594, -941.9056, 35.9057, 47.8419),
        InitialCamLookAtCoords  = vec4(165.9147, -919.8946, 32.8227, 47.9994),

        charactersPlacement = {
            {
                coords    = vec4(163.3140, -926.8589, 30.6239, 218.1640),
                animation = {
                    Dict = "anim@scripted@player@fix_astu_ig8_weed_smoke_v1@male@",
                    Lib = "male_pos_a_p2_base"
                },
                prop = false,
                weapon = false,
                camera = {
                    toCoords = vec4(169.6110, -926.8345, 31.3267, 75.3578),
                    zoom     = 20.0,
                    duration = 3.0,
                },
                insideVehicle     = false, -- unique identifier of vehicle which you add in vehicles section.
                insideVehicleSeat = 0,       -- 1-4 Seat in vehicle
            },
            {
                coords = vec4(165.9431, -918.2198, 30.3717, 192.0681),
                animation = {
                    Dict = "anim@scripted@freemode@ig7_office_cell_floor@heeled@",
                    Lib  = "base_pose_01"
                },
                prop = false,
                weapon = false,
                camera = {
                    toCoords = vec4(168.6161, -925.0262, 31.3221, 11.7331),
                    zoom     = 50.0,
                    duration = 3.0,
                },
                insideVehicle     = false,
                insideVehicleSeat = 0,
            },
            {
                coords = vec4(173.1998, -917.3516, 30.3267, 151.3287),
                animation = {
                    Dict = "amb@world_human_aa_coffee@base",
                    Lib  = "base"
                },
                prop = {
                    Prop = "pata_christmasfood1",
                    PropBone = 28422,
                    PropPlacement = {
                        0.0100,
                        -0.1100,
                        -0.1300,
                        0.0,
                        0.0,
                        0.0
                    }
                },
                weapon = false,
                camera = {
                    toCoords = vec4(165.6446, -922.1199, 32.7531, 302.8799),
                    zoom     = 40.0,
                    duration = 3.0,
                },
                insideVehicle     = false,
                insideVehicleSeat = 0,
            },
        },
        newCharacter = {
            -- Coords where you will create new character
            coords = vec4(-763.3376, 329.4693, 198.4861, 183.4883)
        },
        vehicles = {},
        customProps = {},
        weather = {
            hour    = 21,
            minute  = 0,
            weather = "XMAS", 
            -- EXTRASUNNY
            -- CLEAR
            -- CLOUDS
            -- SMOG
            -- FOGGY
            -- OVERCAST
            -- RAIN
            -- THUNDER
            -- CLEARING
            -- NEUTRAL
            -- SNOW
            -- BLIZZARD
            -- SNOWLIGHT
            -- XMAS
            -- HALLOWEEN
        }
    },
    --[[["scene_1"] = {
        SceneCoords = vec4(49.2859, 7184.5527, 2.4002, 64.6467), -- Player will be teleported to this coords! This is really important.
        InitialCamTime          = 7.0,
        InitialCamCoords        = vec4(34.9546, 7199.9526, 10.2047, 248.3370),
        InitialCamLookAtCoords  = vec4(66.0174, 7188.3491, 1.4332, 59.7735),

        charactersPlacement = {
            {
                coords = vec4(67.7456, 7194.3882, 1.5501, 42.4638),
                animation = {
                    Dict = "missdocksshowoffcar@idle_a",
                    Lib  = "idle_b_5"
                },
                prop = false,
                weapon = false,
                camera = {
                    toCoords = vec4(64.6069, 7200.0630, 2.8786, 227.4351),
                    zoom     = 20.0,
                    duration = 2.0,
                },
                insideVehicle     = false,
                insideVehicleSeat = 0,
            },
            {
                coords    = vec4(66.0174, 7188.3491, 1.4332, 59.7735),
                animation = false,
                prop = false,
                weapon = false,
                camera = {
                    toCoords = vec4(61.9422, 7192.1289, 2.8725, 227.2279),
                    zoom     = 20.0,
                    duration = 3.0,
                },
                insideVehicle     = "veh25", -- unique identifier of vehicle which you add in vehicles section.
                insideVehicleSeat = 1,       -- 1-4 Seat in vehicle
            },
            {
                coords = vec4(59.7110, 7183.2471, 1.6228, 322.9862),
                animation = {
                    Dict = "amb@world_human_drinking@coffee@male@idle_a",
                    Lib  = "idle_c"
                },
                prop = {
                    Prop = "ba_prop_battle_whiskey_bottle_2_s",
                    PropBone = 28422,
                    PropPlacement = {
                        0.0,
                        0.0,
                        0.05,
                        0.0,
                        0.0,
                        0.0
                    }
                },
                weapon = false,
                camera = {
                    toCoords = vec4(60.7500, 7188.7920, 2.8235, 170.8597),
                    zoom     = 20.0,
                    duration = 3.0,
                },
                insideVehicle     = false,
                insideVehicleSeat = 0,
            },
        },

        newCharacter = {
            -- Coords where you will create new character
            coords = vec4(-763.3376, 329.4693, 198.4861, 183.4883)
        },

        vehicles = {
            ["veh25"] = {
                model = "blazer2",
                settings = {}, -- Vehicle settings from getVehicleProperties!
                coords = vec4(66.8167, 7188.5024, 2.3827, 90.3962),
            }
        },

        customProps = {
            {
                name  = "xm_prop_base_tripod_lampb",
                coords = vec4(69.9330, 7188.8125, 1.1861, 274.8404),
            },
            {
                name  = "xm_prop_base_tripod_lampb",
                coords = vec4(67.5469, 7186.2432, 1.2403, 179.5323),
            },
        },
        weather = {
            hour    = 23,
            minute  = 0,
            weather = "SMOG", 
            -- EXTRASUNNY
            -- CLEAR
            -- CLOUDS
            -- SMOG
            -- FOGGY
            -- OVERCAST
            -- RAIN
            -- THUNDER
            -- CLEARING
            -- NEUTRAL
            -- SNOW
            -- BLIZZARD
            -- SNOWLIGHT
            -- XMAS
            -- HALLOWEEN
        }
    }--]]
}

-- ──────────────────────────────────────────────────────────────────────────────
-- HUD Switch                                                    
-- (Information) β–Ί Function will toggle hud when needed to provide best user experience!
-- ──────────────────────────────────────────────────────────────────────────────

Config.SwitchHud = function(toggle)
    if toggle then
        DisplayRadar(true)
        -- Display HUD
    else
        DisplayRadar(false)
        -- Hide HUD
    end
end

Useful Articles

How to create discord webhooks for Logs

Last updated