> For the complete documentation index, see [llms.txt](https://unknown-development.gitbook.io/unknown-development/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://unknown-development.gitbook.io/unknown-development/scripts/unknown_hud.md).

# HUD

This script supports QBCore, Qbox and ESX

<mark style="color:$info;">Are you looking to enhance your FiveM server with a clean and immersive HUD experience? Look no further! Our HUD system delivers a modern, responsive, and visually polished interface designed to elevate long-term roleplay.</mark>

<table data-view="cards"><thead><tr><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td>Buy yours now</td><td><a href="https://unknown-development.tebex.io/package/hud">https://unknown-development.tebex.io/package/hud</a></td></tr><tr><td>Checkout all our scripts</td><td><a href="https://unknown-development.tebex.io/category/resources">https://unknown-development.tebex.io/category/resources</a></td></tr></tbody></table>

## Showcase

{% embed url="<https://www.youtube.com/watch?v=LEu25zo_yk8>" %}

## Config

{% tabs %}
{% tab title="config/config.lua" %}

```lua
Config = {}

-- ─── FRAMEWORK ──────────────────────────────────────────────
Config.Framework = 'qb' -- 'esx', 'qb' (choose 'qb' if you are using Qbox)

-- ─── GENERAL ──────────────────────────────────────────────
-- HUD update delay
Config.UpdateDelay = 100 -- (ms)
-- Speed Multiplier
Config.SpeedMultiplier = 3.6 -- KM/h = 3.6, MP/h = 2.23694

-- ─── FEATURES ──────────────────────────────────────────────
-- Do you want to use integrated watermark function?
Config.UseWatermark = true
-- Do you want to use integrated notify function?
Config.UseNotify = true
-- Do you want to use HUD announcements instead of txAdmin?
Config.txAdminIntegration = true

-- ─── LOCALE ──────────────────────────────────────────────
Config.Locale = 'en' -- 'en', 'lt'

-- ─── WEAPON NAMES ────────────────────────────────────────
Config.WeaponNames = {
    ['weapon_knife']             = 'Knife',
    ['weapon_nightstick']        = 'Nightstick',
    ['weapon_hammer']            = 'Hammer',
    ['weapon_bat']               = 'Bat',
    ['weapon_golfclub']          = 'Golf Club',
    ['weapon_crowbar']           = 'Crowbar',
    ['weapon_pistol']            = 'Colt 1911',
    ['weapon_combatpistol']      = 'Combat Pistol',
    ['weapon_appistol']          = 'AP Pistol',
    ['weapon_pistol50']          = 'Desert Eagle',
    ['weapon_microsmg']          = 'Micro SMG',
    ['weapon_smg']               = 'MP5',
    ['weapon_assaultsmg']        = 'Assault SMG',
    ['weapon_assaultrifle']      = 'AK-47',
    ['weapon_carbinerifle']      = 'M4A4',
    ['weapon_advancedrifle']     = 'Advanced Rifle',
    ['weapon_mg']                = 'MG',
    ['weapon_combatmg']          = 'Combat MG',
    ['weapon_pumpshotgun']       = 'Pump Shotgun',
    ['weapon_sawnoffshotgun']    = 'Sawed-Off Shotgun',
    ['weapon_assaultshotgun']    = 'Assault Shotgun',
    ['weapon_bullpupshotgun']    = 'Bullpup Shotgun',
    ['weapon_stungun']           = 'Taser',
    ['weapon_sniperrifle']       = 'Sniper Rifle',
    ['weapon_heavysniper']       = 'Heavy Sniper',
    ['weapon_grenadelauncher']   = 'Grenade Launcher',
    ['weapon_rpg']               = 'Rocket Launcher',
    ['weapon_minigun']           = 'Minigun',
    ['weapon_grenade']           = 'Grenade',
    ['weapon_stickybomb']        = 'Sticky Bomb',
    ['weapon_smokegrenade']      = 'Smoke Grenade',
    ['weapon_bzgas']             = 'BZ Gas',
    ['weapon_molotov']           = 'Molotov',
    ['weapon_fireextinguisher']  = 'Fire Extinguisher',
    ['weapon_petrolcan']         = 'Jerry Can',
    ['weapon_ball']              = 'Ball',
    ['weapon_snspistol']         = 'Beretta',
    ['weapon_bottle']            = 'Bottle',
    ['weapon_gusenberg']         = 'Thompson',
    ['weapon_specialcarbine']    = 'Beryl',
    ['weapon_heavypistol']       = 'M1911',
    ['weapon_bullpuprifle']      = 'AUG',
    ['weapon_dagger']            = 'Dagger',
    ['weapon_vintagepistol']     = 'Five-Seven',
    ['weapon_firework']          = 'Firework Launcher',
    ['weapon_musket']            = 'Musket',
    ['weapon_heavyshotgun']      = 'Heavy Shotgun',
    ['weapon_marksmanrifle']     = 'Marksman Rifle',
    ['weapon_hominglauncher']    = 'Homing Launcher',
    ['weapon_proxmine']          = 'Proximity Mine',
    ['weapon_snowball']          = 'Snowball',
    ['weapon_flaregun']          = 'Flare Gun',
    ['weapon_combatpdw']         = 'Combat PDW',
    ['weapon_marksmanpistol']    = 'Marksman Pistol',
    ['weapon_knuckle']           = 'Knuckledusters',
    ['weapon_hatchet']           = 'Hatchet',
    ['weapon_railgun']           = 'Railgun',
    ['weapon_machete']           = 'Machete',
    ['weapon_machinepistol']     = 'Machine Pistol',
    ['weapon_switchblade']       = 'Switchblade',
    ['weapon_revolver']          = 'Python',
    ['weapon_dbshotgun']         = 'Double Barrel Shotgun',
    ['weapon_compactrifle']      = 'AK-47M',
    ['weapon_autoshotgun']       = 'Auto Shotgun',
    ['weapon_battleaxe']         = 'Battle Axe',
    ['weapon_compactlauncher']   = 'Compact Launcher',
    ['weapon_minismg']           = 'Mini SMG',
    ['weapon_pipebomb']          = 'Pipe Bomb',
    ['weapon_poolcue']           = 'Pool Cue',
    ['weapon_wrench']            = 'Wrench',
    ['weapon_flashlight']        = 'Flashlight',
    ['gadget_parachute']         = 'Parachute',
    ['weapon_flare']             = 'Flare',
    ['weapon_doubleaction']      = 'Old Revolver',
}

-- ─── STRESS ──────────────────────────────────────────────
Config.DisableStress          = false
Config.StressChance           = 0.1
Config.MinimumStress          = 50
Config.MinimumSpeedUnbuckled  = 50
Config.MinimumSpeed           = 100

Config.WhitelistedJobs = {
    ['leo']       = true,
    ['ambulance'] = true,
}

Config.WhitelistedWeaponStress = {
    [`weapon_petrolcan`]        = true,
    [`weapon_hazardcan`]        = true,
    [`weapon_fireextinguisher`] = true,
}

Config.VehClassStress = {
    ['0']  = true,   -- Compacts
    ['1']  = true,   -- Sedans
    ['2']  = true,   -- SUVs
    ['3']  = true,   -- Coupes
    ['4']  = true,   -- Muscle
    ['5']  = true,   -- Sports Classics
    ['6']  = true,   -- Sports
    ['7']  = true,   -- Super
    ['8']  = true,   -- Motorcycles
    ['9']  = true,   -- Off Road
    ['10'] = true,   -- Industrial
    ['11'] = true,   -- Utility
    ['12'] = true,   -- Vans
    ['13'] = false,  -- Cycles
    ['14'] = false,  -- Boats
    ['15'] = false,  -- Helicopters
    ['16'] = false,  -- Planes
    ['18'] = false,  -- Emergency
    ['19'] = false,  -- Military
    ['20'] = false,  -- Commercial
    ['21'] = false,  -- Trains
}

Config.WhitelistedVehicles = {
    -- [`adder`] = true,
}

Config.Intensity = {
    ['blur'] = {
        [1] = { min = 50,  max = 60,  intensity = 1500 },
        [2] = { min = 60,  max = 70,  intensity = 2000 },
        [3] = { min = 70,  max = 80,  intensity = 2500 },
        [4] = { min = 80,  max = 90,  intensity = 2700 },
        [5] = { min = 90,  max = 100, intensity = 3000 },
    }
}

Config.EffectInterval = {
    [1] = { min = 50, max = 60,  timeout = math.random(50000, 60000) },
    [2] = { min = 60, max = 70,  timeout = math.random(40000, 50000) },
    [3] = { min = 70, max = 80,  timeout = math.random(30000, 40000) },
    [4] = { min = 80, max = 90,  timeout = math.random(20000, 30000) },
    [5] = { min = 90, max = 100, timeout = math.random(15000, 20000) },
}
```

{% endtab %}

{% tab title="config/watermark.js" %}

```js
// Watermark variants
// Example:
// { variant: 'default', label: 'Default' }, -- variant: the name of photo in web/logos folder, label: the name shown in the dropdown menu
window.WATERMARK_VARIANTS = [
    { variant: 'default', label: 'Default' },
];
```

{% endtab %}
{% endtabs %}

## Locales

{% tabs %}
{% tab title="locales/locales.js" %}

```js

const Locales = {
    en: {
        // Sidebar
        sidebar_title: 'HUD',
        tab_colors: 'Colors',
        tab_visibility: 'Visibility',
        tab_watermark: 'Watermark',
        tab_notify: 'Notifications',
        btn_close: 'Close',

        // Colors tab
        colors_title: 'Color settings',
        section_status: 'Status indicators',
        label_water: 'Water',
        label_food: 'Food',
        label_stamina: 'Stamina',
        label_health: 'Health',
        label_armor: 'Armor',
        label_stress: 'Stress',
        section_vehicle: 'Vehicle',
        label_fuel: 'Fuel',
        label_engine: 'Engine',
        btn_reset: 'Reset defaults',

        // Visibility tab
        visibility_title: 'Visibility',
        section_status_cards: 'Status cards',
        label_water_card: 'Water card',
        label_food_card: 'Food card',
        label_stamina_card: 'Stamina card',
        label_health_card: 'Health card',
        label_stress_card: 'Stress card',
        section_other: 'Other elements',
        label_job_card: 'Job card',
        label_weapon_ui: 'Weapon UI',

        // Watermark tab
        watermark_title: 'Watermark settings',
        section_style: 'Style',
        section_position: 'Position',
        wm_top_center: 'Top center',
        wm_top_left: 'Top left',
        section_size: 'Size',
        section_opacity: 'Opacity',
        label_wm_visible: 'Watermark visible',

        // Notify tab
        notify_title: 'Notification settings',
        section_notify_pos: 'Position',
        notify_top_left: 'Top left',
        notify_top_right: 'Top right',
        notify_center_left: 'Center left',
        notify_center_right: 'Center right',
        section_preview: 'Preview',

        // Notify preview
        preview_success_title: 'Success!',
        preview_success_desc: 'Action completed successfully.',
        preview_error_title: 'Error!',
        preview_error_desc: 'Failed to perform action.',
        preview_info_title: 'Information',
        preview_info_desc: 'This is an informational message.',
        preview_warning_title: 'Warning!',
        preview_warning_desc: 'Pay attention.',

        // Announcement defaults
        announcement_title: 'Title',
        announcement_desc: 'Description',
    },

    lt: {
        // Sidebar
        sidebar_title: 'HUD',
        tab_colors: 'Spalvos',
        tab_visibility: 'Matomumas',
        tab_watermark: 'Logotipas',
        tab_notify: 'Pranešimai',
        btn_close: 'Uždaryti',

        // Colors tab
        colors_title: 'Spalvų nustatymai',
        section_status: 'Statuso rodikliai',
        label_water: 'Vanduo',
        label_food: 'Maistas',
        label_stamina: 'Stamina',
        label_health: 'Gyvybė',
        label_armor: 'Šarvai',
        label_stress: 'Stresas',
        section_vehicle: 'Transporto priemonė',
        label_fuel: 'Degalai',
        label_engine: 'Variklis',
        btn_reset: 'Atstatyti numatytas',

        // Visibility tab
        visibility_title: 'Matomumas',
        section_status_cards: 'Statuso kortelės',
        label_water_card: 'Vandens kortelė',
        label_food_card: 'Maisto kortelė',
        label_stamina_card: 'Staminos kortelė',
        label_health_card: 'Gyvybės kortelė',
        label_stress_card: 'Streso kortelė',
        section_other: 'Kiti elementai',
        label_job_card: 'Darbo kortelė',
        label_weapon_ui: 'Ginklo UI',

        // Watermark tab
        watermark_title: 'Logotipo nustatymai',
        section_style: 'Stilius',
        section_position: 'Vieta',
        wm_top_center: 'Viršuje centre',
        wm_top_left: 'Viršuje kairėje',
        section_size: 'Dydis',
        section_opacity: 'Skaidrumas',
        label_wm_visible: 'Logotipas matomas',

        // Notify tab
        notify_title: 'Pranešimų nustatymai',
        section_notify_pos: 'Pozicija',
        notify_top_left: 'Viršuj kairėj',
        notify_top_right: 'Viršuj dešinėj',
        notify_center_left: 'Per vidurį kairėj',
        notify_center_right: 'Per vidurį dešinėj',
        section_preview: 'Peržiūra',

        // Notify preview
        preview_success_title: 'Sėkmingai!',
        preview_success_desc: 'Veiksmas atliktas sėkmingai.',
        preview_error_title: 'Klaida!',
        preview_error_desc: 'Nepavyko atlikti veiksmo.',
        preview_info_title: 'Informacija',
        preview_info_desc: 'Tai yra informacinis pranešimas.',
        preview_warning_title: 'Įspėjimas!',
        preview_warning_desc: 'Atkreipkite dėmesį.',

        // Announcement defaults
        announcement_title: 'Pavadinimas',
        announcement_desc: 'Aprašymas',
    }
};
//////////////////
// DO NOT TOUCH!!!
//////////////////
let currentLocale = 'lt';

function t(key) {
    const lang = Locales[currentLocale] || Locales['en'];
    return lang[key] || Locales['en'][key] || key;
}

function setLocale(locale) {
    if (Locales[locale]) {
        currentLocale = locale;
    } else {
        currentLocale = 'en';
    }
    applyLocale();
}

function applyLocale() {
    document.querySelectorAll('[data-locale]').forEach(el => {
        const key = el.getAttribute('data-locale');
        const text = t(key);
        if (text) el.textContent = text;
    });
}

```

{% endtab %}
{% endtabs %}
