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

# Config Files

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

```lua
Config = {}

Config.Framework = 'auto' -- auto / qb / qbx / esx
Config.InteractKey = 38 -- E
Config.InteractDistance = 2.2
Config.KeepUiOpenDistance = 4.0
Config.ScanInterval = 250
Config.PlaytimeSaveInterval = 60 -- seconds

Config.Ui = {
    cardLeft = 22,
    cardBottom = 26,
    radialLeft = 56,
    radialTop = 50
}

Config.RelationKeys = {
    Accept = 246, -- Y
    Decline = 249 -- N
}

Config.JobReview = {
    Enabled = true,             -- enable/disable automatic job reviews
    IntervalDays = 5,           -- how many real days before it appears again
    CheckIntervalSeconds = 600, -- how often the server checks if a review should open
    ExcludedJobs = {
        'unemployed'
    }
}

Config.Admin = {
    Command = 'scoreadmin',
    AllowedLicenses = {
        'license:c70da7d1b951554d2f69aae6632823642b0fa939',
        'license:yyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy'
    },

    ShowAvatars = true -- true = show avatars in admin panel / false = hide them
}

Config.StaffReview = {
    RequestCooldown = 60 -- seconds before the same admin can use /review again on the same player
}

Config.Discord = {
    enabled = true,
    botToken = 'YOUR_TOKEN_HERE',
    useAvatarDecoration = false
}

Config.Locale = {
    prompt = 'Interactions',
    profile = 'Open profile',
    like = 'Give like',
    rate = 'Rate player',
    relation = 'View relationship',

    cache = 'Search',
    open_profile = 'Open profile',
    give_like = 'Give like',
    rate_player = 'Rate player',

    admin_title = 'Admin Panel',
    admin_subtitle = 'View all saved profiles, their score, likes, and relationship status.',
    admin_refresh = 'Refresh',
    admin_close = 'Close',
    admin_profiles = 'Profiles',
    admin_online = 'Online',
    admin_marriages = 'Marriages',
    admin_pending = 'Pending',
    admin_total_likes = 'Total likes',
    admin_search_placeholder = 'Search by name, citizenid, license, relationship, or partner...',
    admin_no_results = 'There are no profiles to display with that filter.',
    admin_view_notes = 'View notes',
    admin_notes_title = 'Player Notes',
    admin_notes_title_prefix = 'Notes from',
    admin_notes_no_info = 'No information',
    admin_notes_empty = 'This player does not have any written notes yet.',
    admin_back = 'Back',
    admin_online_status = 'Online',
    admin_offline_status = 'Offline',
    admin_single = 'Single',
    admin_married = 'Married',
    admin_pending_relation = 'Pending',
    admin_total_average = 'total average',
    admin_played_hours = 'hours played',

    admin_table_player = 'Player',
    admin_table_score = 'Score',
    admin_table_likes = 'Likes',
    admin_table_reviews = 'Reviews',
    admin_table_relation = 'Relationship',
    admin_table_partner = 'Partner',
    admin_table_status = 'Status',
    admin_table_action = 'Action',

    admin_results_word = 'results',
    admin_points = 'points',
    admin_player_generic = 'Player',
    admin_unknown_player = 'No name',
    admin_no_date = 'No date',
    admin_id_prefix = 'ID',

    note_modal_title = 'Explain your rating',
    note_modal_subtitle = 'Write a short opinion related to the score.',
    note_modal_label = 'Your comment',
    note_modal_placeholder = 'Write your explanation here...',
    note_modal_send = 'Send',

    note_error_invalid_rating_title = 'Invalid rating',
    note_error_invalid_rating_message = 'You must select a rating first.',

    note_error_required_title = 'Note required',
    note_error_required_message = 'Write a clearer explanation.',

    toast_success_title = 'Action completed',
    toast_error_title = 'Warning',
    toast_info_title = 'Information',
    rating_question = 'From 1 to 10, how good of a player do you think they are?',

    relation_title = 'Relationship',
    relation_back = 'Back',
    relation_status_label = 'Relationship status:',
    relation_single_status = 'Single',
    relation_married_status = 'Married',
    relation_pending_status = 'Pending',
    relation_waiting_status = 'Waiting for response',
    relation_request_btn = 'Ask to be partners',
    relation_request_sent_btn = 'Request sent',
    relation_divorce_btn = 'Request divorce',
    relation_accept_btn = 'Accept (Y)',
    relation_decline_btn = 'Decline (N)',
    relation_popup_title = 'Relationship Request',
    relation_popup_hint = 'Press <strong>Y</strong> to accept or <strong>N</strong> to decline.',
    relation_popup_body = '{name} asked you to be partners. Do you want to accept the request?',
    relation_note_single = 'Send a request to this player. If they accept, both of you will become married.',
    relation_note_married = 'If you press this button, the current relationship with this player will be removed.',
    relation_note_outgoing = 'You have already sent a relationship request to this player.',
    relation_note_incoming = 'You have a pending request from <strong style="color:#fff;">{name}</strong>. You can accept or decline it.',
    relation_other_player = 'another player',
    relation_unknown_player = 'A player',
    relation_with = 'with',
    relation_from = 'from',
    relation_key_accept = 'Accept',
    relation_key_decline = 'Decline',

    app_profile_tag = 'PROFILE',
    app_loading = 'Loading...',
    app_joined_label = 'Joined',
    app_hours_label = 'Hours played',
    app_player_label = 'Player',
    app_likes_label = 'Likes',
    app_points_label = 'Points',
    app_user_fallback = 'User',
    app_job_fallback = 'USER',
    app_unknown_player = 'A player',

    review_modal_title = 'Explain your rating for this player',
    review_sent_title = 'Review sent',
    review_sent_message_one = 'You gave the player {rating} point.',
    review_sent_message_many = 'You gave the player {rating} points.',

    toast_profile_load_error = 'Could not load this player profile.',
    toast_like_self_error = 'You cannot like yourself.',
    toast_like_success = 'You liked this player.',
    toast_like_received = '{name} gave you a like.',
    toast_like_already = 'You already liked this player.',

    toast_relation_load_error = 'Could not load the relationship status.',
    toast_relation_request_self = 'You cannot send a request to yourself.',
    toast_relation_already_active = 'You already have an active relationship.',
    toast_relation_target_active = 'That player already has an active relationship.',
    toast_relation_pending_exists = 'There is already a pending request between you.',
    toast_relation_request_sent = 'Request sent successfully.',
    toast_relation_request_received = '{name} asked you to be partners.',
    toast_relation_no_pending = 'There is no pending request from this player.',
    toast_relation_declined_self = 'You declined the request.',
    toast_relation_declined_other = '{name} declined your request.',
    toast_relation_married_self = 'You are now married to {name}.',
    toast_relation_married_other = 'You are now married to {name}.',
    toast_relation_divorce_no_active = 'You do not have an active relationship with this player.',
    toast_relation_divorce_self = 'You divorced {name}.',
    toast_relation_divorce_other = '{name} requested a divorce.',

    toast_review_self_error = 'You cannot rate yourself.',
    toast_review_invalid_range = 'The rating must be between 1 and 10.',
    toast_review_invalid_note = 'You must write a valid explanation.',
    toast_review_success = 'You gave the player {rating} points.',
    toast_review_received = '{name} rated you with {rating} points. Comment: {note}',

    toast_admin_no_permission_open = 'You do not have permission to open the admin panel.',
    toast_admin_no_permission_view = 'You do not have permission to view the admin panel.',
    toast_admin_no_permission_notes = 'You do not have permission to view notes.',
    toast_admin_invalid_citizenid = 'Invalid CitizenID.',
    toast_admin_profile_not_found = 'That player profile could not be found.',

    chat_relation_title = 'Relationship',
    chat_relation_married = '{name1} and {name2} got married.',
    chat_relation_divorced = '{name1} and {name2} got divorced.',

    toast_relation_request_cooldown = 'You must wait {seconds} seconds before sending another relationship request.',

    generic_no_name = 'No name',
    generic_player = 'A player',

    admin_tab_players = 'Players',
    admin_tab_staff = 'Staff',
    admin_staff_average = 'staff average',
    admin_staff_reviews = 'Staff reviews',
    admin_staff_notes_title_prefix = 'Staff notes for',

    staff_review_kicker = 'Staff Review',
    staff_review_title = 'Evaluate Player',
    staff_review_subtitle = 'Leave an internal staff review for the selected player.',
    staff_review_rating_label = 'Score',
    staff_review_note_label = 'Note',
    staff_review_note_placeholder = 'Write what the player did, how they helped, or why this review was given...',
    staff_review_cancel = 'Cancel',
    staff_review_submit = 'Send Review',

    toast_staff_review_no_permission = 'You do not have permission to use staff reviews.',
    toast_staff_review_invalid_target = 'The selected player is not valid.',
    toast_staff_review_success = 'Staff review sent to {name} with rating {rating}/10.',
    toast_staff_review_received = '{name} left you a staff review ({rating}/10).',
    toast_staff_review_request_cooldown = 'You must wait {seconds} seconds before sending another staff review request to this player.',

    admin_tab_jobs = 'Jobs',
    admin_jobs_average = 'job average',
    admin_jobs_reviews = 'Job reviews',
    admin_jobs_notes_title_prefix = 'Job notes for',
    admin_table_job = 'Job',
    admin_table_last_review = 'Last review',

    job_review_kicker = 'Job Review',
    job_review_title = 'Evaluate your job',
    job_review_subtitle = 'Tell us briefly how your current job is going.',
    job_review_rating_label = 'Score',
    job_review_note_label = 'Note',
    job_review_note_placeholder = 'Write how this job is going, what should improve, or what you think about it...',
    job_review_cancel = 'Cancel',
    job_review_submit = 'Send Review',

    toast_job_review_success = 'Your review for {job} was sent successfully.',
    toast_job_review_invalid_job = 'Your current job is not valid for reviews.',
    toast_job_review_not_pending = 'There is no pending job review right now.',
    toast_job_review_disabled = 'Job reviews are currently disabled.'
}

local function L(key, vars)
    local text = (Config.Locale and Config.Locale[key]) or key

    if vars then
        for k, v in pairs(vars) do
            text = text:gsub('{' .. k .. '}', tostring(v))
        end
    end

    return text
end

Config.Labels = {
    prompt = L('prompt'),
    profile = L('profile'),
    like = L('like'),
    rate = L('rate'),
    relation = L('relation')
}

Config.RadialActions = {
    top = {
        id = 'cache',
        icon = 'fa fa-search-plus',
        label = L('cache'),
        actionType = 'export',
        resource = 'your_script',
        exportName = 'OpenCacheMenu',
        args = {
            'targetServerId'
        }
    },

    right = {
        id = 'like',
        icon = 'fa fa-thumbs-up',
        label = L('give_like'),
        actionType = 'builtin_like'
    },

    bottom = {
        id = 'rate',
        icon = 'fa fa-star',
        label = L('rate_player'),
        actionType = 'builtin_rate'
    },

    left = {
        id = 'profile',
        icon = 'fa fa-address-card',
        label = L('open_profile'),
        actionType = 'builtin_profile'
    }
}
```

{% endtab %}
{% endtabs %}
