Configuration
Overview
shared/config.lua: language, theme, interaction, stash and dispatch defaultsshared/lists.lua: prop models and animations offered in the editorshared/config_minigames.lua: minigame definitionsserver/config_server.lua: skills, battlepass and Discord webhooks
Zones, categories, loot tables, world props, tools, cooldowns and the rotation settings live in the database and are edited from the admin panel.
General
1Config.Debug = false
2Config.Language = 'en'
3Config.Theme = 'default'
4Config.MainColor = nil
5Config.Command = 'mlloot'Debug: prints extra console outputLanguage: language file loaded from thelocales/folderTheme: admin panel theme.'default','wasteland','cyberpunk','noir'or'fantasy'MainColor: hex accent color.nilkeeps the theme colorCommand: opens the admin panel. Admin permission required
UI Theme
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 for this resource.nilfollows the shared theme set inml_bridgecolors: CSS hex values for single colors. Anynilvalue follows the shared theme
Admin Panel
1Config.Admin.MinimizeKey = 'F9'MinimizeKey: hides and restores the admin panel, so you can look at the world while editing. F1 to F12, or a single letter or digit
Interaction
1Config.Settings = {
2 Interaction = nil,
3 InteractionDistance = 2.0,
4 MaxLootDistance = 5.0,
5 MaxSpawnAttempts = 50,
6}Interaction:niluses the target resource when one is running and a press-E prompt otherwise.'target'or'textui'forces one of the twoInteractionDistance: range of the target option or prompt, in metersMaxLootDistance: maximum distance the server accepts for a loot claim, in metersMaxSpawnAttempts: placement retries for each random prop in a zone
Lootbox Stash
A prop set as a lootbox opens a stash instead of giving the items straight away.
1Config.Stash = {
2 Prefix = 'ml_loot',
3 DefaultLabel = 'Loot',
4 Slots = 20,
5 MaxWeight = 50000,
6}
7
8Config.AbandonedStashSeconds = 600Prefix: prefix of the stash IDsDefaultLabel: stash title when the prop has no label of its ownSlots: stash slotsMaxWeight: maximum weight in gramsAbandonedStashSeconds: an opened stash left idle this long is cleared and its prop counts as looted.0turns the check off
With ML Inventory, grid size, stash theme and the loot reveal delay are set per prop in the editor.
Dispatch
Zones and categories can override every default below from the admin panel.
1Config.Dispatch = {
2 Enabled = true,
3 DefaultCooldown = 180,
4 DefaultChance = 50,
5 Jobs = { 'police', 'sheriff' },
6 BlipSprite = 161,
7 BlipColor = 1,
8 BlipFlash = true,
9 DefaultMessage = 'Suspicious Activity',
10}Enabled: turns police alerts on or off for every zoneDefaultCooldown: seconds between two alerts from the same zoneDefaultChance: chance from 0 to 100 that a loot sends an alertJobs: jobs that receive the alertBlipSprite,BlipColor,BlipFlash: map blip of the alertDefaultMessage: alert text
Rotation and Startup Delay
Both are set in the Settings tab of the admin panel.
Each category keeps between a minimum and a maximum number of zones active and reshuffles them after a random interval. A category set to Always Active keeps every zone on and only refreshes the loot.
After a server start, zones stay closed for a random time between a minimum and a maximum, so loot opens once players have joined. Players who try to loot early see the time left. Set both values to 0 to turn the delay off.
Lists
1Config.PropModelList = {
2 'prop_cash_crate_01',
3 'prop_tool_box_02',
4}
5
6Config.AnimationsList = {
7 { label = _L('anim_search_bin'), anim = 'base', dict = 'amb@prop_human_bum_bin@base' },
8}PropModelList: models offered in the prop pickerAnimationsList: search animations offered per prop.label,anim(clip) anddict(dictionary)
Minigames
Minigames are picked per prop in the loot editor. The four ox_lib skill checks are always listed. Lockpick and thermite appear with bd-minigames, the scrambler with ps-ui.
1Config.AvailableMiniGames["my_custom_game"] = {
2 label = "My Custom Game",
3 Start = function(params)
4 return exports['my-minigames']:StartGame('hard')
5 end
6}Start returns true on success and false on failure.
Skills
1Config.Skills = {
2 Enabled = true,
3 Resource = 'ml_skills',
4 MaxXpPerLoot = 500,
5}Enabled:falseturns off XP rewards and skill requirementsResource: name of the skills resourceMaxXpPerLoot: highest XP the server grants for one loot, whatever the prop says
XP amounts and required skills are set per prop in the loot editor.
Battlepass
1Config.Battlepass = { Enabled = true }Enabled: withml_battlepassrunning, looting advances battlepass objectives.falseturns it off. Withoutml_battlepassthis setting does nothing
Discord Webhooks
1Config.DiscordWebhook = {
2 ZoneEdit = 'INSERT_WEBHOOK_LINK_HERE',
3 ZoneDelete = 'INSERT_WEBHOOK_LINK_HERE',
4 CategoryEdit = 'INSERT_WEBHOOK_LINK_HERE',
5 CategoryDelete = 'INSERT_WEBHOOK_LINK_HERE',
6 SettingsChange = 'INSERT_WEBHOOK_LINK_HERE',
7 LootCollect = 'INSERT_WEBHOOK_LINK_HERE',
8 ExploitDetected = 'INSERT_WEBHOOK_LINK_HERE',
9 PropEdit = 'INSERT_WEBHOOK_LINK_HERE',
10 LootTypeEdit = 'INSERT_WEBHOOK_LINK_HERE',
11 PropCategoryEdit = 'INSERT_WEBHOOK_LINK_HERE',
12}ZoneEdit,ZoneDelete: a zone is created, edited or deletedCategoryEdit,CategoryDelete: a category is edited or deletedSettingsChange: global settings changeLootCollect: a player loots a propExploitDetected: a claim fails a server check (distance, skipped minigame, malformed data)PropEdit: a world prop is created, edited or deletedLootTypeEdit: a loot type changesPropCategoryEdit: a world prop category changes
Set any webhook to false to disable that log entirely.