Config File

tgiCoreExports = exports["tgiann-core"]
config = tgiCoreExports:getConfig()

---@type string Key to open the chat input
config.chatKey = "T"

---@type string Key to toggle chat visibility mode (showWhenActive / alwaysShow / hide)
config.chatVisibilityKey = "L"

---@type string[] Command aliases to clear the chat history
config.clearCommand = { "clear", "temizle" }

---@type boolean Whether clicking outside the chat input closes it
config.closeOnOutsideClick = true

---@type boolean Whether to play keyboard sound effects while typing/deleting in chat
config.typingSound = true

---@type boolean Whether to show a chat message when a player joins the server
config.showJoinMessages = GetConvarInt('chat_showJoins', 1) == 0

---@type boolean Whether to show a chat message when a player leaves the server
config.showQuitMessages = GetConvarInt('chat_showQuits', 1) == 0

---@type number Update rate in milliseconds for indicators like emotes (me/do) and player ID display. Lower values may impact performance, while higher values may reduce the responsiveness of the indicators.
config.uiUpdateRate = 24

---@type boolean If true, when messages are sent using the chat:addMessage event or addMessage export without a tags parameter, the first value in args will be used as a tag.
config.defaultAddTag = true

---@type boolean Whether to show server print messages in chat (in addition to console)
config.showPrintsOnChat = false

---@type number Cache duration in seconds for Discord role data (used by discordTag feature)
config.discordTagCacheTime = 60

---@type string which category should be active by default when chat is opened (command, ooc, oocclosest, admin, pdchat, emschat, gang or any custom categories)
config.defaultChatCategory = "command"

---@type ChatCategory[]
config.chatCategories = {
    {
        label = "CATEGORY_OOC_LABEL",             -- translation key for category display name
        type = "ooc",                             -- unique identifier for the category
        icon = "comment",                         -- FontAwesome icon name
        command = { "ooc" },                      -- chat command(s) that trigger this category
        placeholder = "CATEGORY_OOC_PLACEHOLDER", -- translation key for input placeholder
        -- distance = 50.0,                         -- (optional) max distance for message delivery in meters
        -- permissions = { "admin" },               -- (optional) required ACE permissions
        -- jobs = { police = { 1, 2, 3 } },         -- (optional) required jobs. true = all grades, number[] = specific grades
        -- gangs = { whiteGang = true },            -- (optional) required gangs. true = all grades, number[] = specific grades
        maxLength = 200, -- maximum allowed message character length
        tags = {         -- tags displayed before messages
            { tag = "OOC (Global)", textColor = { 51, 51, 51 }, bgColor = { 255, 179, 102 } },
        },
        color = { 255, 179, 102 },       -- default message text color {r, g, b}
        showPlayerName = {
            active = true,               -- whether to show the player's name in chat
            censored = true,             -- whether to censor the name (e.g. "J*** D**")
            bgColor = { 255, 179, 102 }, -- override color for the name tag
            textColor = { 51, 51, 51 },  -- override text color for the name tag
        },
        showPlayerId = {
            active = false,              -- whether to show the player's ID in chat
            type = "citizenid",          -- "citizenid" or "serverId"
            bgColor = { 255, 179, 102 }, -- override color for the ID tag
            textColor = { 51, 51, 51 },  -- override text color for the ID tag
        },
        showPlayerJob = {
            active = false,              -- whether to show the player's job in chat
            showLabel = true,            -- whether to show the job label (e.g. "Police")
            showGrade = true,            -- whether to show the job grade (e.g. "Sergeant")
            bgColor = { 255, 179, 102 }, -- override color for the job tag
            textColor = { 51, 51, 51 },  -- override text color for the job tag
        },
        discordTag = {
            active = true, -- whether to show Discord role tags in chat
            maxShow = 2,   -- maximum number of Discord role tags to display
            roles = {      -- array of Discord roles to check and display
                { id = "1464588139979997234", tag = "Role VIP",     textColor = { 51, 51, 51 }, bgColor = { 255, 215, 0 } },
                { id = "813213133639254056",  tag = "Donator Role", textColor = { 51, 51, 51 }, bgColor = { 102, 204, 153 } },
            },
        },
    },
    {
        label = "CATEGORY_CLOSEST_LABEL",
        type = "oocclosest",
        icon = "users",
        placeholder = "CATEGORY_CLOSEST_PLACEHOLDER",
        distance = 50.0,
        maxLength = 300,
        tags = {
            { tag = "OOC (local)", textColor = { 51, 51, 51 }, bgColor = { 137, 196, 244 } },
        },
        color = { 137, 196, 244 },
        showPlayerName = {
            active = true,
            censored = true,
            bgColor = { 137, 196, 244 },
            textColor = { 51, 51, 51 },
        },
        showPlayerId = {
            active = true,
            type = "serverId",
            bgColor = { 137, 196, 244 },
            textColor = { 51, 51, 51 },
        },
        showPlayerJob = {
            active = false,
            showLabel = true,
            showGrade = false,
            bgColor = { 137, 196, 244 },
            textColor = { 51, 51, 51 },
        },
        discordTag = {
            active = false, -- whether to show Discord role tags in chat
            maxShow = 1,    -- maximum number of Discord role tags to display
            roles = {       -- array of Discord roles to check and display
                { id = "1464588139979997234", tag = "VIP", textColor = { 51, 51, 51 }, bgColor = { 255, 215, 0 } },
            },
        },
    },
    {
        label = "CATEGORY_ADMIN_LABEL",
        type = "admin",
        icon = "shield-alt",
        placeholder = "CATEGORY_ADMIN_PLACEHOLDER",
        permissions = { "command", "admin" },
        maxLength = 500,
        tags = {
            { tag = "Admin", textColor = { 51, 51, 51 }, bgColor = { 255, 105, 97 } },
        },
        color = { 255, 105, 97 },
        showPlayerName = {
            active = true,
            censored = false,
            bgColor = { 255, 105, 97 },
            textColor = { 51, 51, 51 },
        },
        showPlayerId = {
            active = false,
            type = "citizenid",
            bgColor = { 255, 105, 97 },
            textColor = { 51, 51, 51 },
        },
        showPlayerJob = {
            active = false,
            showLabel = true,
            showGrade = false,
            bgColor = { 255, 105, 97 },
            textColor = { 51, 51, 51 },
        },
        discordTag = {
            active = false, -- whether to show Discord role tags in chat
            maxShow = 1,    -- maximum number of Discord role tags to display
            roles = {       -- array of Discord roles to check and display
                { id = "1464588139979997234", tag = "VIP", textColor = { 51, 51, 51 }, bgColor = { 255, 215, 0 } },
            },
        },
    },
    {
        label = "CATEGORY_PD_LABEL",
        type = "pdchat",
        command = { "pdc" },
        icon = "briefcase",
        placeholder = "CATEGORY_JOB_PLACEHOLDER",
        jobs = { police = { 1, 2, 3, 4, 5, 6, 7, 8, 9 } }, --  only 9 ranks for police job
        maxLength = 300,
        tags = {
            { tag = "PD", textColor = { 51, 51, 51 }, bgColor = { 102, 178, 255 } },
        },
        color = { 102, 178, 255 },
        showPlayerName = {
            active = true,
            censored = false,
            bgColor = { 102, 178, 255 },
            textColor = { 51, 51, 51 },
        },
        showPlayerId = {
            active = false,
            type = "citizenid",
            bgColor = { 102, 178, 255 },
            textColor = { 51, 51, 51 },
        },
        showPlayerJob = {
            active = true,
            showLabel = true,
            showGrade = true,
            bgColor = { 102, 178, 255 },
            textColor = { 51, 51, 51 },
        },
        discordTag = {
            active = false, -- whether to show Discord role tags in chat
            maxShow = 1,    -- maximum number of Discord role tags to display
            roles = {       -- array of Discord roles to check and display
                { id = "1464588139979997234", tag = "VIP", textColor = { 51, 51, 51 }, bgColor = { 255, 215, 0 } },
            },
        },
    },
    {
        label = "CATEGORY_EMS_LABEL",
        type = "emschat",
        command = { "emsc" },
        icon = "briefcase",
        placeholder = "CATEGORY_JOB_PLACEHOLDER",
        jobs = { ambulance = true }, -- all ranks for ambulance jobs
        maxLength = 300,
        tags = {
            { tag = "EMS", textColor = { 51, 51, 51 }, bgColor = { 255, 89, 94 } },
        },
        color = { 255, 89, 94 },
        showPlayerName = {
            active = true,
            censored = false,
            bgColor = { 255, 89, 94 },
            textColor = { 51, 51, 51 },
        },
        showPlayerId = {
            active = false,
            type = "citizenid",
            bgColor = { 255, 89, 94 },
            textColor = { 51, 51, 51 },
        },
        showPlayerJob = {
            active = false,
            showLabel = true,
            showGrade = false,
            bgColor = { 255, 89, 94 },
            textColor = { 51, 51, 51 },
        },
        discordTag = {
            active = false, -- whether to show Discord role tags in chat
            maxShow = 1,    -- maximum number of Discord role tags to display
            roles = {       -- array of Discord roles to check and display
                { id = "1464588139979997234", tag = "VIP", textColor = { 51, 51, 51 }, bgColor = { 255, 215, 0 } },
            },
        },
    },
    {
        label = "CATEGORY_GANG_LABEL",
        type = "gang",
        icon = "users",
        placeholder = "CATEGORY_GANG_PLACEHOLDER",
        gangs = { whiteGang = true, greenGang = { 1, 2, 3, 4, 5, 6, 7, 8, 9 } }, -- all ranks for whiteGang gang, only 9 ranks for greenGang gang
        maxLength = 300,
        tags = {
            { tag = "Gang", textColor = { 51, 51, 51 }, bgColor = { 255, 153, 102 } },
        },
        color = { 255, 153, 102 },
        showPlayerName = {
            active = true,
            censored = false,
            bgColor = { 255, 153, 102 },
            textColor = { 51, 51, 51 },
        },
        showPlayerId = {
            active = false,
            type = "citizenid",
            bgColor = { 255, 153, 102 },
            textColor = { 51, 51, 51 },
        },
        showPlayerJob = {
            active = false,
            showLabel = true,
            showGrade = false,
            bgColor = { 255, 153, 102 },
            textColor = { 51, 51, 51 },
        },
        discordTag = {
            active = false, -- whether to show Discord role tags in chat
            maxShow = 1,    -- maximum number of Discord role tags to display
            roles = {       -- array of Discord roles to check and display
                { id = "1464588139979997234", tag = "VIP", textColor = { 51, 51, 51 }, bgColor = { 255, 215, 0 } },
            },
        },
    }
}

---@type number Maximum number of head texts that can be stacked on a single player
config.headTextMaxStack = 4

---@type PlayerIdDisplay
config.playerIdDisplay = {
    active = true,  -- whether to show player IDs above heads when chat is open
    showOwn = true, -- whether to show your own ID above your head
    dist = 5.0,     -- max distance to display player IDs (meters)
    -- Template placeholders:
    --   {serverId}  - player's server ID (source)
    --   {name}      - player's character name
    --   {citizenid} - player's CitizenID
    --   {steamId}   - player's Steam hex ID
    --   {discordId} - player's Discord ID
    --   {fivemId}   - player's FiveM ID
    -- Supports \n for line breaks and HTML tags for inline styling
    -- Examples:
    --   "[{serverId}]"                        -> [1]
    --   "[{serverId}] {name}"                 -> [1] John Doe
    --   "{name}\n{serverId}"                  -> TGIANN\n3
    --   "{citizenid}\n<span style='font-size:1.4vh'>{serverId}</span>"
    template = "[{serverId}] {fivemId}",
    headText = {                             -- head text rendering settings
        bone = 31086,                        -- ped bone ID to attach to (31086 = head)
        offset = vector3(0.3, 0.0, 0.0),     -- offset from the bone position
        minScale = 0.3,                      -- minimum scale at max render distance
        maxRenderDist = 30.0,                -- maximum distance to render the text
        offsetCb = function(zOffset, offset) -- custom offset calculation callback
            return vector3(offset.x + zOffset, offset.y, offset.z)
        end,
    },
    cssStyle = { -- CSS styles for the ID display
        color = "#fff",
        fontSize = "1.8vh",
        fontWeight = "600",
        lineHeight = "1",
        textShadow = "0px 2px 2px rgba(0,0,0,0.8)",
        textAlign = "center",
        textTransform = "uppercase",
    },
}

---@type ChatOpenEmote
config.chatOpenEmote = {
    active = true, -- whether to show typing indicator above player's head
    headText = {   -- head text rendering settings
        bone = 31086,
        offset = vector3(0.3, 0.0, 0.0),
        minScale = 0.3,
        maxRenderDist = 30.0,
        offsetCb = function(zOffset, offset)
            return vector3(offset.x + zOffset, offset.y, offset.z)
        end,
    },
    texts = { -- texts to cycle through as typing indicator
        { text = "", time = 500 }, -- text: display text, time: duration in ms before next
        { text = "••", time = 500 },
        { text = "•••", time = 500 },
        { text = "••", time = 500 },
    },
    cssStyle = { -- CSS styles for the typing indicator
        color = "#fff",
        fontSize = "1.6vh",
        textShadow = "0 1px 0 black"
    },
    dist = 8.0 -- max distance for others to see the typing indicator (meters)
}

---@type EmoteCommand[]
config.emoteCommands = {
    {
        command = "me",                 -- command name(s) that trigger this emote (string or string[])
        desc = "EMOTE_ME_COMMAND_DESC", -- translation key for command description
        webhookKey = "emoteCommand",    -- (optional) webhook key from server/webhook.lua for Discord logging. If not set, no log will be sent.
        dist = 8.0,                     -- max distance for emote visibility (meters)
        -- anim = {                            -- (optional) animation to play before sending the result
        --     dict = "anim@some_dict",        --   animation dictionary name
        --     clip = "some_clip",             --   animation clip name
        --     flag = 49,                      --   animation flags (default: 0)
        --     duration = 3000,                --   duration in ms (omit to wait for anim to finish)
        -- },
        headText = { -- head text rendering settings
            bone = 31086,
            offset = vector3(0.3, 0.0, 0.0),
            minScale = 0.3,
            maxRenderDist = 30.0,
            offsetCb = function(zOffset, offset)
                return vector3(offset.x + zOffset, offset.y, offset.z)
            end,
        },
        cssStyle = { -- CSS styles for the head text display
            color = "#A8D8F0",
            fontSize = "1.6vh",
            fontStyle = "italic",
            background = "rgba(0, 0, 0, 0.5)",
            padding = "0.3vh 0.8vh",
            borderRadius = "0.3vh",
        },
        time = 10000,            -- duration in ms to show the head text
        template = "* {text} *", -- display template. Placeholders: {text}, {playerName}, {playerCensoredName}
        -- params = {               -- (optional) custom command parameters (defaults to single "message" param)
        --     { name = 'min', type = 'number', help = 'HELP_KEY', optional = true },
        -- },
        -- msgCb = function(args) -- (optional) custom callback to generate message text from args
        --     return args.message
        -- end,
        sendToChat = {     -- settings for also sending emote output to chat
            active = true, -- whether to send to chat
            tags = {       -- tags displayed before the message
                { tag = "ME", textColor = { 51, 51, 51 }, bgColor = { 168, 216, 240 } },
            },
            color = { 168, 216, 240 }, -- message text color
            showPlayerName = {         -- player name display settings
                active = true,
                censored = true,
                bgColor = { 168, 216, 240 },
                textColor = { 51, 51, 51 },
            },
            showPlayerId = { -- player ID display settings
                active = true,
                type = "citizenid",
                bgColor = { 168, 216, 240 },
                textColor = { 51, 51, 51 },
            },
            showPlayerJob = { -- player job display settings
                active = false,
                showLabel = true,
                showGrade = false,
                bgColor = { 168, 216, 240 },
                textColor = { 51, 51, 51 },
            },
            discordTag = { -- Discord role tag display settings
                active = false,
                maxShow = 4,
                roles = {
                    -- { id = "123456789", tag = "VIP", textColor = { 51, 51, 51 }, bgColor = { 255, 215, 0 } },
                },
            },
        },
    },
    {
        command = "do",
        desc = "EMOTE_DO_COMMAND_DESC",
        webhookKey = "emoteCommand",
        dist = 8.0,
        headText = {
            bone = 0,
            offset = vector3(0.0, 0.0, 0.0),
            minScale = 0.3,
            maxRenderDist = 30.0,
            offsetCb = function(zOffset, offset)
                return vector3(offset.x + zOffset, offset.y, offset.z)
            end,
        },
        cssStyle = {
            color = "#F4B8D0",
            fontSize = "1.6vh",
            fontStyle = "italic",
            background = "rgba(0, 0, 0, 0.5)",
            padding = "0.3vh 0.8vh",
            borderRadius = "0.3vh",
        },
        time = 10000,
        template = "* {playerName}: {text} *",
        sendToChat = {
            active = true,
            tags = {
                { tag = "DO", textColor = { 51, 51, 51 }, bgColor = { 244, 184, 208 } },
            },
            color = { 244, 184, 208 },
            showPlayerName = {
                active = true,
                censored = true,
                bgColor = { 244, 184, 208 },
                textColor = { 51, 51, 51 },
            },
            showPlayerId = {
                active = true,
                type = "citizenid",
                bgColor = { 244, 184, 208 },
                textColor = { 51, 51, 51 },
            },
            showPlayerJob = {
                active = false,
                showLabel = true,
                showGrade = false,
                bgColor = { 244, 184, 208 },
                textColor = { 51, 51, 51 },
            },
            discordTag = { -- Discord role tag display settings
                active = false,
                maxShow = 4,
                roles = {
                    -- { id = "123456789", tag = "VIP", textColor = { 51, 51, 51 }, bgColor = { 255, 215, 0 } },
                },
            },
        },
    },
    {
        command = { "dice", "zar" },
        desc = "EMOTE_DICE_COMMAND_DESC",
        dist = 10.0,
        anim = {
            dict = "anim@mp_player_intcelebrationmale@wank",
            clip = "wank",
            flag = 49,
            -- duration = 3000,
        },
        headText = {
            bone = 31086,
            offset = vector3(0.3, 0.0, 0.0),
            minScale = 0.3,
            maxRenderDist = 30.0,
            offsetCb = function(zOffset, offset)
                return vector3(offset.x + zOffset, offset.y, offset.z)
            end,
        },
        cssStyle = {
            color = "#FFD700",
            fontSize = "1.6vh",
            fontWeight = "bold",
            background = "rgba(0, 0, 0, 0.5)",
            padding = "0.3vh 0.8vh",
            borderRadius = "0.3vh",
        },
        time = 10000,
        template = "{text}",
        params = {
            { name = 'min', type = 'number', help = 'EMOTE_DICE_PARAM_MIN', optional = true },
            { name = 'max', type = 'number', help = 'EMOTE_DICE_PARAM_MAX', optional = true },
        },
        msgCb = function(args)
            local min = args.min or 1
            local max = args.max or 6
            return '🎲 ' .. math.random(min, max) .. " (" .. min .. "/" .. max .. ")"
        end,
        sendToChat = {
            active = true,
            tags = {
                { tag = "Dice", textColor = { 51, 51, 51 }, bgColor = { 255, 215, 0 } },
            },
            color = { 255, 215, 0 },
            showPlayerName = {
                active = true,
                censored = true,
                bgColor = { 255, 215, 0 },
                textColor = { 51, 51, 51 },
            },
            showPlayerId = {
                active = true,
                type = "citizenid",
                bgColor = { 255, 215, 0 },
                textColor = { 51, 51, 51 },
            },
            showPlayerJob = {
                active = false,
                showLabel = true,
                showGrade = false,
                bgColor = { 255, 215, 0 },
                textColor = { 51, 51, 51 },
            },
            discordTag = { -- Discord role tag display settings
                active = false,
                maxShow = 4,
                roles = {
                    -- { id = "123456789", tag = "VIP", textColor = { 51, 51, 51 }, bgColor = { 255, 215, 0 } },
                },
            },
        },
    },
    {
        command = { "rps", "tkm" },
        desc = "EMOTE_RPS_COMMAND_DESC",
        dist = 10.0,
        headText = {
            bone = 31086,
            offset = vector3(0.3, 0.0, 0.0),
            minScale = 0.3,
            maxRenderDist = 30.0,
            offsetCb = function(zOffset, offset)
                return vector3(offset.x + zOffset, offset.y, offset.z)
            end,
        },
        cssStyle = {
            color = "#9B59B6",
            fontSize = "1.6vh",
            fontWeight = "bold",
            background = "rgba(0, 0, 0, 0.5)",
            padding = "0.3vh 0.8vh",
            borderRadius = "0.3vh",
        },
        time = 10000,
        template = "{text}",
        params = {
            { name = 'choice', type = 'number', help = 'EMOTE_RPS_PARAM_CHOICE', optional = true },
        },
        msgCb = function(args)
            local rpsItems = { '' .. t("RPS_ROCK"), '' .. t("RPS_PAPER"), '✌️ ' .. t("RPS_SCISSORS") }
            local choice = args.choice
            if choice and choice >= 1 and choice <= 3 then
                return rpsItems[choice]
            end
            return rpsItems[math.random(1, 3)]
        end,
        sendToChat = {
            active = true,
            tags = {
                { tag = "RPS", textColor = { 51, 51, 51 }, bgColor = { 155, 89, 182 } },
            },
            color = { 155, 89, 182 },
            showPlayerName = {
                active = true,
                censored = true,
                bgColor = { 155, 89, 182 },
                textColor = { 51, 51, 51 },
            },
            showPlayerId = {
                active = true,
                type = "citizenid",
                bgColor = { 155, 89, 182 },
                textColor = { 51, 51, 51 },
            },
            showPlayerJob = {
                active = false,
                showLabel = true,
                showGrade = false,
                bgColor = { 155, 89, 182 },
                textColor = { 51, 51, 51 },
            },
            discordTag = { -- Discord role tag display settings
                active = false,
                maxShow = 4,
                roles = {
                    -- { id = "123456789", tag = "VIP", textColor = { 51, 51, 51 }, bgColor = { 255, 215, 0 } },
                },
            },
        },
    }
}

---@type DiscordConfig
config.discord = {
    active = true,          -- whether Discord integration is enabled
    pollInterval = 15000,   -- polling interval in ms to check for new messages
    channels = {            -- array of Discord channels to monitor
        {
            channelId = "", -- Discord channel ID to poll messages from
            -- permissions = { "admin" },      -- (optional) required ACE permissions to see messages
            -- jobs = { police = true },       -- (optional) required jobs to see messages
            -- gangs = { whiteGang = true },   -- (optional) required gangs to see messages
            tags = { -- tags displayed before Discord messages
                { tag = "Discord", textColor = { 51, 51, 51 }, bgColor = { 88, 101, 242 } },
            },
            color = { 200, 200, 200 }, -- message text color {r, g, b}
        },
        {
            channelId = "",
            permissions = { "admin", "command" },
            tags = {
                { tag = "Discord Admin", textColor = { 51, 51, 51 }, bgColor = { 242, 101, 101 } },
            },
            color = { 200, 200, 200 },
        },
        {
            channelId = "",
            jobs = { police = true },
            tags = {
                { tag = "Discord PD", textColor = { 51, 51, 51 }, bgColor = { 101, 242, 101 } },
            },
            color = { 200, 200, 200 },
        },
        {
            channelId = "",
            jobs = { ambulance = true },
            tags = {
                { tag = "Discord EMS", textColor = { 51, 51, 51 }, bgColor = { 242, 242, 101 } },
            },
            color = { 200, 200, 200 },
        },
        {
            channelId = "",
            gangs = { whiteGang = true },
            tags = {
                { tag = "Discord Gang", textColor = { 51, 51, 51 }, bgColor = { 242, 101, 242 } },
            },
            color = { 200, 200, 200 },
        }
    }
}

---@type AutoMessages
config.autoMessages = {
    active = true,              -- whether auto messages are enabled
    messages = {                -- array of auto messages to broadcast periodically
        {
            interval = 3600000, -- interval in ms between each broadcast (3600000 = 1 hour)
            tags = {            -- tags displayed before the message
                { tag = "Auto Message", textColor = { 51, 51, 51 }, bgColor = { 88, 166, 255 } },
            },
            color = { 88, 166, 255 },                       -- message text color {r, g, b}
            args = { "Test message for auto message (1)" }, -- message text(s)
        },
        {
            interval = 600000, -- 10 dakika (600000)
            tags = {
                { tag = "Test", textColor = { 51, 51, 51 }, bgColor = { 102, 204, 153 } },
            },
            color = { 102, 204, 153 },
            args = { "Test message for auto message (2)" },
        },
    }
}

---@type WelcomeMessages
config.welcomeMessages = {
    active = true,   -- whether welcome messages are enabled
    messages = {     -- array of messages shown when a player joins
        {
            tags = { -- tags displayed before the message
                { tag = "Welcome", textColor = { 51, 51, 51 }, bgColor = { 102, 204, 153 } },
            },
            color = { 255, 255, 255 },                       -- message text color {r, g, b}
            args = { "Welcome to the TGIANN Test server!" }, -- message text(s)
        },
        {
            tags = {
                { tag = "Info", textColor = { 51, 51, 51 }, bgColor = { 88, 166, 255 } },
            },
            color = { 255, 255, 255 },
            args = { "You can use all admin commands while on the test server." },
        },
        {
            tags = {
                { tag = "Info", textColor = { 51, 51, 51 }, bgColor = { 88, 166, 255 } },
            },
            color = { 255, 255, 255 },
            args = { "Use the /items command to access all items." },
        },
        {
            tags = {
                { tag = "Info", textColor = { 51, 51, 51 }, bgColor = { 88, 166, 255 } },
            },
            color = { 255, 255, 255 },
            args = { "If you need config files for scripts, visit docs.tgiann.com for detailed information." },
        },
    }
}

---@type table txAdmin event settings
config.txAdmin = {
    announcement = {
        active = true,
        tagBgColor = { 255, 190, 60 },
        tagTextColor = { 51, 51, 51 },
    },
    scheduledRestart = {
        active = true,
        tagBgColor = { 255, 105, 97 },
        tagTextColor = { 51, 51, 51 },
    },
    directMessage = {
        active = true,
        tagBgColor = { 100, 180, 255 },
        tagTextColor = { 51, 51, 51 },
    },
}

---@type table<string, table<string, string>> Language translations, populated by language files
config.langs = {}

Last updated