Configuration
Overview
shared/config.lua: language, admin command, theme, trader spawning, purchase safety and export accessshared/ped_models.lua,shared/animations.lua: models and animations offered in the trader editorserver/config_server.lua: Discord webhooks
Shops, traders, items, prices, stock, categories, positions and opening hours live in the database and are edited from the admin panel.
General
shared/config.lua
1Config.Settings = {
2 Locale = 'en',
3 Debug = false,
4 AdminCommand = 'shopadmin',
5 Theme = 'classic',
6 MainColor = '#e58c3b',
7 ShopLayout = 'new',
8 PedSpawnDistance = 100.0,
9 EnableBlips = true,
10 TargetLabelSource = 'title',
11 PurchaseMaxDistance = 8.0,
12 MaxCartEntries = 50,
13}
14
15Config.Admin.MinimizeKey = 'F9'Locale: language file loaded from thelocales/folderDebug: prints extra console outputAdminCommand: opens the admin panel. Admin permission requiredTheme: theme of the player shop.'classic','wasteland','cyberpunk','noir'or'fantasy'MainColor: accent color of the player shop, as a CSS hex valueShopLayout:'new'opens the shop as a side panel,'default'as a full screen windowPedSpawnDistance: meters at which trader NPCs spawn and despawn around the playerEnableBlips:falsehides every trader blip. Sprite, color and scale are set per trader in the admin panelTargetLabelSource: trader field shown on the target option.'title'or'name'PurchaseMaxDistance: highest distance in meters between player and trader for a purchase. The server checks it on every purchaseMaxCartEntries: highest number of different items in one cartMinimizeKey: hides and restores the admin panel. F1 to F12, or a single letter or digit
Trader Beep
shared/config.lua
1Config.Settings.PedBeep = {
2 enabled = false,
3 soundName = 'CONFIRM_BEEP',
4 soundSet = 'HUD_MINI_GAME_SOUNDSET',
5 cooldownMs = 30000,
6}enabled: plays a sound once when the player walks near a tradersoundName,soundSet: GTA frontend sound to playcooldownMs: milliseconds before the same trader can beep again
UI Theme
shared/config.lua
1Config.UITheme = {
2 preset = nil,
3 colors = {
4 primary = nil,
5 accent = nil,
6 background = nil,
7 surface = nil,
8 text = nil,
9 },
10}preset: theme preset of the admin panel.'default','wasteland','cyberpunk','noir'or'fantasy'.nilfollows the shared theme set inml_bridgecolors: CSS hex values for single colors. Anynilvalue follows the shared theme
Shops Without a Trader
The server refuses a purchase when no trader of that shop is near the player, which blocks buying from across the map. List a shop here to open it from a phone app, an item or another resource.
shared/config.lua
1Config.AllowVirtualShop = {
2 ['phone_blackmarket'] = true,
3}AllowVirtualShop: shop IDs that skip the distance check. Job, opening hours and skill checks still apply
Discounts
shared/config.lua
1Config.MaxDiscountPercent = 99MaxDiscountPercent: highest total discount on one item, after job, skill and custom discounts are added up.100allows free items
Export Access
shared/config.lua
1Config.AdminExportResources = {
2 'ml_missions',
3}AdminExportResources: resources allowed to callSetItemStock,AddItemStockandTriggerShopRefresh. The list ships empty, which blocks all of them. Read exports are open to every resource
Open Exports
Config.Settings.OpenExports = true lets any resource change stock. Keep the list instead.
Lists
shared/config.lua
1Config.BlipColors = {
2 [0] = 'White',
3 [1] = 'Red',
4 [2] = 'Green',
5}BlipColors: blip colors offered in the trader editor, as GTA color ID and label
shared/config.lua
1Config.AdminStaticData = {
2 PedModels = { 's_m_m_strvend_01', 'a_m_m_bevhills_02', 'a_m_o_soucent_01' },
3 PedScenarios = { 'WORLD_HUMAN_STAND_MOBILE', 'WORLD_HUMAN_SMOKING' },
4 Animations = {
5 { dict = 'amb@world_human_clipboard@male@idle_a', clip = 'idle_a' },
6 },
7}PedModels,PedScenarios: quick picks in the trader editorAnimations: animation suggestions in the trader editor, asdictandclip
The full model and animation catalogs are in shared/ped_models.lua and shared/animations.lua.
Discord Webhooks
server/config_server.lua
1Config.DiscordWebhook = {
2 StaffActions = 'INSERT_WEBHOOK_LINK_HERE',
3 PlayerActions = 'INSERT_WEBHOOK_LINK_HERE',
4 Purchases = 'INSERT_WEBHOOK_LINK_HERE',
5 TraderManagement = 'INSERT_WEBHOOK_LINK_HERE',
6 ItemManagement = 'INSERT_WEBHOOK_LINK_HERE',
7 StockChanges = 'INSERT_WEBHOOK_LINK_HERE',
8 CategoryChanges = 'INSERT_WEBHOOK_LINK_HERE',
9 ExploitDetected = 'INSERT_WEBHOOK_LINK_HERE',
10}StaffActions: traders and items created, edited, paused or deletedPlayerActions: a player opens a shopPurchases: every purchase with items and costsStockChanges: stock edits and restocksCategoryChanges: categories saved or deletedExploitDetected: a request fails a server check, such as buying from too far awayTraderManagement,ItemManagement: not used. Trader and item edits go toStaffActions
Set any webhook to false to disable that log entirely. The log destination (Discord, ox_lib or FiveManage) is set once in ml_bridge with Config.LogProvider.