Configuration
Gameplay settings are in shared/config.lua. Server-only settings (admins, webhooks, gang creation) are in server/server.lua. Restart the resource after any change.
General
| Option | Default | Description |
|---|---|---|
Config.Framework | "auto" | qbx, qb, esx, vrp or auto. |
Config.Inventory | "auto" | Inventory to use. |
Config.Target | "auto" | ox_target, qb-target or auto. |
Config.Locale | "en" | "en" or "ar". |
Config.Debug | false | Prints debug output. |
Spray items
lua
Config.Items = {
spray = { item = "moh_alphaspray", label = "Alpha Spray", minGrade = 0 },
king = { item = "moh_kingspray", label = "King Spray", minGrade = 1, zoneRadius = 120.0 },
remover = { item = "moh_sprayremove", label = "Spray Remover" },
policeRemover = { item = "moh_policesprayremove", label = "Police Spray Remover" },
laptop = { item = "moh_ganglap", label = "Gang Laptop", allowNoGang = true }
}minGrade is the lowest gang grade allowed to place that spray.
Territory zones
| Option | Default | Description |
|---|---|---|
Config.ZoneRadius | 100.0 | Radius of an Alpha Spray zone. |
Config.Items.king.zoneRadius | 120.0 | Radius of a King Spray zone. |
Config.SprayPlacement.connectionPadding | 2.0 | Extra meters allowed when connecting a new spray to an existing zone. |
Config.SprayDailyLimit | 2 per 24h | Sprays a gang can place per day. |
Config.SprayTime | 15000 | Time to place a spray (ms). |
Config.SprayRemoveTime | 12000 | Time to remove a spray (ms). |
Survival reward
lua
Config.SprayChainReward = {
enabled = true,
surviveHours = 48, -- a spray must survive this long
amount = 20000, -- reward to the gang
}Adjusting a spray
Each spray can be adjusted once by the gang leader after it's placed. Limits are in Config.SprayAdjust.
Spray images
lua
Config.SpraySetup = {
bossOnly = true, -- only the boss can change the gang image
allowDiscordImage = true,
allowedImageDomains = {}, -- e.g. { 'i.imgur.com' } to only allow certain sites
}Images must be direct HTTPS links to a PNG or JPG file.
Spray wars
lua
Config.SprayRemoval = {
delayMinutes = 1, -- wait before the attack starts
defendMinutes = 20, -- time the defenders have
attackerLockMinutes = 30, -- attacker cooldown after removing a spray
thirdPartyLockMinutes = 30,
startRequiresItem = true, -- need a Spray Remover to start
onlineRequirement = {
enabled = true,
attacker = 0, -- min. online members per side
defender = 0
}
}Warzone robbery
lua
Config.WarzoneRobbery = {
enabled = true,
maxDistance = 2.5,
transferCash = true,
cashAccount = 'cash',
durationMs = { min = 5000, max = 7000 },
inventoryMaxSeconds = 60,
}War map for the Mafia
Players with this job or gang see every active war on the map:
lua
Config.MafWarMap = {
enabled = true,
job = 'maf',
gang = 'maf',
color = 5,
}Police raids
The police can clean gang sprays with the Police Spray Remover.
| Option | Default | Description |
|---|---|---|
enabled | true | Turns police raids on. |
job | "police" | Police job name. |
minGrade | 8 | Lowest grade allowed to raid. |
minOnline | 5 | Police that must be online. |
cooldownMinutes | 60 | Cooldown between raids. |
blockGangAttacks | true | Gangs can't attack a spray during a police raid. |
dispatch.resource | "cd_dispatch" | Dispatch resource for the alert. |
NPC seller
lua
Config.NpcSeller = {
enabled = true,
ped = "s_m_y_dealer_01",
coords = vector4(114.39, -1961.23, 21.33, 24.99),
dailyLimit = { enabled = true, count = 8, hours = 24 },
items = {
{ key = "spray", label = "Alpha Spray", item = "moh_alphaspray", price = 50000, requiresGang = true },
{ key = "remover", label = "Spray Remover", item = "moh_sprayremove", price = 25000, requiresGang = true },
}
}Gang funds
lua
Config.ManagementFunds = {
table = "moh_gang_funds",
moneyType = "cash",
maxTransfer = 10000000
}Phone notifications
lua
Config.EnablelbphoneNotifications = true
Config.Notificationsettings = {
resource = "lb-phone",
title = "Gang Spray",
sound = { enabled = true, volume = 0.5 }
}Server settings
In server/server.lua:
lua
ServerConfig = {
GangCreation = {
enabled = true,
maxGangs = 128,
requireTablet = true,
grades = {
['0'] = { name = 'Member' },
['1'] = { name = 'Manager', isboss = true },
['2'] = { name = 'CoLeader', isboss = true },
['3'] = { name = 'Leader', isboss = true },
},
},
Webhooks = {
Default = 'https://discord.com/api/webhooks/...',
Purchases = '', Security = '', Admin = '', Management = '',
Economy = '', Robbery = '', Gang = '', Police = '',
War = '', SprayChanges = '',
},
}Empty webhook categories use Default.
vRP
lua
Config.VRP = {
version = 'auto', -- 'vrp1', 'vrp2' or 'auto'
policePermission = 'police.service',
policeManagementPermission = 'police.manage',
policeJobName = 'police',
}