Configuration reference
There are two files. Both stay readable after escrow.
There are two files. Both stay readable after escrow.
| File | Who sees it | What goes in it |
|---|---|---|
config.lua | every player (it is sent to clients) | shops, the shelf, categories, payment accounts, the admin ACE |
server/config.lua | the server only | prices, the weekly re-price, revenue, uses, retention, logging |
Never move a price, share, floor or webhook into config.lua. Every value is checked at start-up. A mistake prints a red [cc_boutique] config: ... line that names the setting, and the boutique stays closed until it is fixed.
config.lua
General
| Setting | Default | |
|---|---|---|
Config.Debug | false | extra console lines: what was detected, every 10 minutes |
Config.Locale | 'en' | the language file in locales/. The replicated convar setr cc_boutique_locale "de" overrides it |
Config.PedSpawnDistance | 60.0 | metres. Shop assistants exist only within this range of a player |
Config.TargetIcon | 'fa-solid fa-gem' | Font Awesome icon for ox_target / qb-target |
Config.AdminAce | 'cc_boutique.admin' | the ACE for the admin commands |
Config.Shops
A list. Each counter sells the same shelf at the same prices.
| Field | Example | |
|---|---|---|
label | 'Maison Vinewood' | blip name, and {shop} in the target label |
coords | vec4(295.08, 186.30, 104.37, 160.0) | where the assistant stands. Use /boutique_where |
ped | 's_f_y_shop_high' or false | the assistant's model, or none |
reach | 4.0 | metres. The server refuses a purchase from further away (0-25) |
radius | 1.6 | the interaction sphere |
blip | { sprite = 617, colour = 46, scale = 0.8 } or false | map blip |
Config.Items
The shelf, in display order.
| Field | ||
|---|---|---|
id | required | the inventory item name. Must also be in ServerConfig.Prices and your inventory |
label | required | the name shown in the shop and in notifications |
category | required | one of Config.Categories |
use | required | 'title', 'decor' or 'keepsake' (see below) |
image | required | a file in web/img/ |
wide | optional | true shows the picture landscape (paintings) |
To add a piece: add a line here, a price in server/config.lua, the item in your inventory, and an image in web/img/. For a title piece, also add "title." to the locale.
Config.Categories
The tabs in order, for example { 'watches', 'jewellery', 'art' }. Each needs "cat." in the locale. "Everything" is always first.
Config.Payments
The accounts a buyer can choose, in order: { account = 'bank', label = 'ui.pay.bank' }. account is one of cc_lib's account names: cash, bank or black (dirty money). cc_lib maps them to your framework's names (ESX money / black_money, QBCore cash ...), so they are the same on every server. label is a locale key. The page sends only the position in this list, and the server reads the account from its own copy.
server/config.lua
ServerConfig.Prices
One entry per shelf id.
| Field | ||
|---|---|---|
share | 25 | % of the median wealth one piece costs ('wealth' mode) |
floor | 50000 | the lowest price. In 'fixed' mode this is the price |
title | 'gold_standard' | use = 'title' pieces: the title key (cc_coins). Its display name is title.<key> in the locale |
decor | 'lux_art_oils' | use = 'decor' pieces: the furniture catalogue id (tcc-housing) |
ServerConfig.Pricing
| Setting | Default | |
|---|---|---|
mode | 'wealth' | 'wealth': a share of the median with a weekly cap. 'fixed': always floor |
medianSource | 'auto' | 'auto' and 'ledger': cc_ledger when it has a snapshot, else fallbackMedian. 'fixed': always fallbackMedian. A cc_boutique:median hook overrides all of them |
fallbackMedian | 500000 | $. What a typical active player is worth on your server |
maxStep | 10 | % a price may move in one week (0-100). 0 freezes prices after the first week |
roundTo | 500 | prices round to this |
weekStartsOn | 1 | 0 = Sunday ... 6 = Saturday |
hour | 5 | local server hour on that day when the new week's prices are set |
checkMinutes | 10 | how often the server checks for a new week |
How a week is priced: target = max(floor, round(median × share / 100)). The new price moves from last week's price toward the target by at most maxStep %. The first price ever is the target itself. Prices are stored, so a restart never changes them. /boutique_reprice re-prices the current week from last week's price, so it cannot get round the cap.
ServerConfig.Revenue
| Setting | Default | |
|---|---|---|
mode | 'none' | 'none': the money is destroyed (a sink). 'society': paid to a job account through cc_lib. 'cc_government': paid into the treasury |
society | 'government' | 'society' mode: the job or society name |
source | 'luxury' | 'cc_government' mode: the Collect() source key |
maxPerCall | 5000000 | 'cc_government' mode: the most one Collect() call moves (large sales are split) |
If a payout is refused, the sale still stands and the money stays destroyed. It is never given back to anyone.
ServerConfig.Uses
| Setting | Default | |
|---|---|---|
titles | 'auto' | 'auto' or 'cc_coins': cc_coins when running. 'none': title pieces are keepsakes |
decor | 'auto' | 'auto' or 'tcc-housing': tcc-housing when running. 'none': art pieces are keepsakes |
ServerConfig.Sales, Logging, Reason
| Setting | Default | |
|---|---|---|
Sales.keepDays | 365 | sales records older than this are purged daily, 5,000 rows at a time. 0 keeps them forever |
Logging.webhookConvar | 'cc_boutique_webhook' | the convar holding a Discord webhook. Set it with set, never setr |
Logging.username | 'Boutique' | the webhook's display name |
Logging.console | true | also print sales to the console |
Reason | 'cc_boutique:sale' | the reason attached to every money movement |
Locales
locales/en.json holds every string, including the shop's name on the page (ui.brand, ui.name, ui.tag). To translate:
- Copy it to
locales/xx.jsonand translate the values. Keep the keys and the{placeholders}. - Set
Config.Locale = 'xx'.
Any key you leave out falls back to English.
Theme
The colours are CSS variables at the top of web/style.css (:root { --accent: ... }). There is a dark block and a light block ([data-cc-theme="light"]). Change --accent and --accent-hover to rebrand.