UZ Scripts
Spawn Selector

Configuration

Customize spawn locations, interface languages, map behavior, and HUD integrations for Boyraz Spawn Selector.

Customize spawn locations, interface languages, map behavior, and third-party HUD integrations for your FiveM server.

Configuration File

Customize.lua

System Core

All settings live inside the Customize table in Customize.lua:

Customize = {
    Locale = 'en',
    Framework = nil,
    Map = { ClusterDistance = 3.5 },
    Client = { SetUI = function(visible) end },
    Locations = { }
}

General Settings

Locale

Sets the interface language for the spawn selector UI.

Prop

Type

Custom Language: Set to 'other' and provide your own translation file to add an unsupported language.

Framework

Defines the server framework. Leave as nil for auto-detection (recommended).

Framework = nil  -- Auto-detect (recommended)
-- or: 'QBCore', 'ESX', 'Qbox'

Auto-detection works reliably in most setups. Only set this manually if you experience detection issues.

ClusterDistance

Controls the visual grouping behavior of spawn points on the map interface. Determines how close two markers must be to merge into a single cluster.

Map = {
    ClusterDistance = 3.5  -- Default
}

Tip: Set a lower number for less clustering. Useful if you have multiple spawn points packed tightly in a specific area.


Client HUD Integration

Control UI visibility to prevent HUD overlap during the spawn selection phase. The SetUI function is triggered automatically.

SetUI = function(visible)
    -- Default integration with uz_PureHud
    if GetResourceState('uz_PureHud') == 'started' then
        exports['uz_PureHud']:SetHudVisibility(visible)
    end

    -- Add your server's specific HUD export/event below:
    -- exports['my_custom_hud']:ToggleDisplay(visible)
end,

If you don't hide your HUD during spawn selection, players may see overlapping UI elements.


Spawn Locations

Define the specific points where players can choose to spawn.

Structure

Prop

Type

Example

Locations = {
    {
        icon = 'fa-solid fa-city',
        name = 'Legion Square',
        coords = vec4(195.17, -933.77, 29.7, 144.5)
    },
    {
        icon = 'fa-solid fa-tree',
        name = 'Paleto Bay',
        coords = vec4(80.35, 6424.12, 31.67, 45.5)
    },
    {
        icon = 'Apartments.svg',
        name = 'Motels',
        coords = vec4(327.56, -205.08, 53.08, 163.5)
    }
}

SVG Setup: If using custom .svg files, ensure they are placed inside your resource's icons directory for the UI to render them.


Troubleshooting

On this page