⚙️Configuration

Configuration guide of Wallet System V2 System.


Config.lua

Config = {}

-- If you’re experiencing any issues with the framework, check the stg_lib/config.lua file (it’s already auto-detected).
Config.Locales = {}
Config.Language = "en" -- en, de, fr, es, pt, it, nl, pl, sv, ar, jp, zh
Config.Debug = false

Config.Nationality = "UNITED STATES" -- ESX users do not have nationality information, so this is used.
Config.MoneyType = "dollar" -- dollar or euro (If you want to add your own currency, you can change the images in the 'images' folder: money-dollar.png or money-euro.png)
Config.WalletSize = 1.3 -- Wallet scale size (recommended is 1.3)

Config.CountryName = "UNITED STATES OF AMERICA" -- Country name displayed on the card header (appears on all ID cards)
Config.CountryFlag = "us" -- Country flag code (ISO 3166-1 alpha-2 format: us, gb, de, de, fr, it, be, nl, pl, ca etc.) - displayed on ID cards
-- https://www.iban.com/country-codes

Config.WalletItems = { -- Item names that represent the wallet in your inventory (you also can add more wallet types images/wallets folder)
    "black_wallet",
    "purple_wallet",
    "brown_wallet"
}

-- Admin Panel Configuration
Config.Panel = {
    command = "panel",

    groupPermissions = {
        "god",
        "admin"
    },

    identifierPermissions = { -- you can learn your identifier by txadmin from the players list - IDs
        "steam:110000112345678", -- Example Steam identifier
        "license:1234567890abcdef1234567890abcdef12345678", -- Example Rockstar License identifier
        "discord:1234567890123456789", -- Example Discord identifier
    }
}

-- Static Cards Configuration
Config.StaticCards = {
    ["identity"] = {
        name = "identity",
        label = "Identity Card",
        title = "IDENTIFICATION CARD",
        background = "images/backgrounds/city.png",
        logo = "images/cityLogo.png",
        defaultColor = "#1a1a1a"
    },
    ["job"] = {
        name = "job",
        label = "Job Card",
        title = "JOB CARD",
        background = "images/backgrounds/city.png",
        logo = "images/cityLogo.png",
        defaultColor = "#2c3e50",
    },
    ["driver_license"] = {
        name = "driver_license",
        label = "Driver License",
        title = "DRIVER LICENSE",
        background = "images/backgrounds/city.png",
        logo = "images/logos/ls.png",
        defaultColor = "#3e2723",

        driving_license = true,

        licenses = {
            {
                label = "A",
                license_name = "driver" -- The license name given by the driving school script. (If set to false, it will be considered as already owned by the player)
            },
            {
                label = "B",
                license_name = "drive_b" -- The license name given by the driving school script. (If set to false, it will be considered as already owned by the player)
            },
            {
                label = "C",
                license_name = "drive_c" -- The license name given by the driving school script. (If set to false, it will be considered as already owned by the player)
            },
            {
                label = "D",
                license_name = "drive_d" -- The license name given by the driving school script. (If set to false, it will be considered as already owned by the player)
            }
        }
    },
    ["weapon_license"] = {
        name = "weapon_license",
        label = "Weapon License",
        title = "WEAPON LICENSE",
        background = "images/backgrounds/city.png",
        logo = "images/logos/ls.png",
        defaultColor = "#4a6c55ff",

        licenses = {
            {
                label = "Pistol",
                license_name = "weapon" -- If set to false, it will be considered as already owned by the player
            },
            {
                label = "Heavy Weapons",
                license_name = "heavy_weapon" -- If set to false, it will be considered as already owned by the player
            }
        }
    }
}

-- Animation and display times (in milliseconds)
Config.Time = {
    show_card = 5000,      -- Duration to display card before auto-closing
    show_money = 5000,     -- Duration to display money before auto-closing
    animation = 300        -- Scale animation duration (opening/closing transition)
}

-- Props used for animations
Config.Props = {
    show_card = "prop_cs_swipe_card",
    show_money = "prop_cash_pile_01"
}

-- Jobs that can access badges
Config.Badges = {
    "police",
    "ambulance"
}

-- Money Rain Configuration
Config.RainMoney = {
    active = true,
    amount = 100
}

-- Notification and Help Notify Functions
Config.Functions = {
    ["helpNotify"] = function(message, icon)
        lib.showTextUI(message, {
            position = "right-center",
            icon = icon,
            style = {
                borderRadius = 1,
                whiteSpace = 'pre-line'
            }
        })
    end,

    ["hideHelpNotify"] = function()
        lib.hideTextUI()
    end,

    ["notify"] = function(type, message)
        lib.notify({
            title = getMessage('notify_title'),
            description = message,
            type = type,
            duration = 5000,
        })
    end
}

-- Walk Control Configuration
Config.CanWalk = {
    active = true, -- true = Player can walk in wallet, false = Player cannot walk and below controls will be disabled

    disabledControls = {
        -- Movement
        -- 30, -- A/D (Left/Right)
        -- 31, -- W/S (Forward/Back)
        32, -- W (Forward)
        33, -- S (Back)
        34, -- A (Left)
        35, -- D (Right)

        -- Weapon & Attack
        24, -- Attack (Left Mouse)
        25, -- Aim (Right Mouse)
        140, -- Light Attack (R)
        141, -- Heavy Attack
        142, -- Alternative Attack

        -- Mouse Camera
        1, -- Camera Up/Down (Mouse Y)
        2, -- Camera Left/Right (Mouse X)

        -- Other Keys
        21, -- Sprint (Shift)
        22, -- Jump (Space)
        23, -- Enter Vehicle (F)
        44, -- Cover (Q)
        36, -- Crouch (Ctrl)
        37, -- Weapon Wheel (Tab)
    }
}

Last updated