Skip to content

ANPR Configuration Reference

This document provides a comprehensive reference for every configuration option in shared/config.lua. All gameplay mechanics, speed calibrations, camera streaming distances, Discord embeds, and integration bridges are managed from this single file.


Section Parameter Scope Key Settings
1. General & Commands Prop models, client commands, UI test modes Config.PoleModel, Config.OpenCommand, Config.PlaceCommand
2. Permissions & Admin Job access controls, admin menu, ACE checks Config.AllowedJobs, Config.AdminRoles, Config.AdminAcePermission
3. NUI & Language Interface language, officer headers, plate styles Config.Language, Config.DefaultOfficer, Config.PlateStyle
4. Speed Calibration Measurement units, multipliers, speed thresholds Config.SpeedUnit, Config.SpeedMultiplier, Config.SpeedingThreshold
5. Props & Streaming Prop streaming radius, tick intervals Config.PoleSpawnDistance, Config.StreamingCheckInterval
6. Scanning & Cooldowns Tick rates, minimum velocity, scan distances Config.ScanInterval, Config.ScanDistance, Config.ScanCooldown
7. Filter & Photo Modes Passings filter, snapshot capture rules Config.ScanningFilterMode, Config.PhotoCaptureFilter
8. Vehicle Exclusions NPC ambient traffic bypass, emergency vehicles Config.IgnoreNPCVehicles, Config.IgnoredVehicleClasses
9. CCTV Camera Viewer Interactive FOV, height offsets, timecycle filters Config.CamFOV, Config.CamTimecycle, Config.CamHeightOffset
10. Webhooks & CDN Discord upload webhooks, camera flashes Config.DiscordWebhook, Config.PhotoStorageMode
11. Retention & Cleanup Memory limits, route history, database cleanup Config.MaxScanHistory, Config.CleanupInterval
12. Master Bridges Framework, dispatch, MDT, garage adapters Config.Framework, Config.DispatchSystem, Config.MdtBoloSync
13. Discord Embeds Rich Discord embed templates and color hexes Config.EnableDiscordEmbeds, Config.DiscordEmbedTemplates

Config = {}
-- ============================================================================
-- 1. GENERAL SETTINGS & COMMANDS
-- ============================================================================
-- The GTA V prop model name used for ANPR CCTV camera poles
Config.PoleModel = "prop_cctv_pole_01a"
-- Client command name to enter interactive pole placement mode
Config.PlaceCommand = "placeanpr"
-- Client command name to toggle/open the main ANPR Tablet NUI interface
Config.OpenCommand = "anpr"
-- Enable Greenscreen Mode for UI filming / testing (Solid rgb(0,255,0) background)
Config.GreenscreenMode = false
-- Configurable signal reasons for BOLO alerts (displayed in tablet & dispatch)
Config.BoloReasons = {
"STOLEN VEHICLE",
"WANTED SUSPECT",
"SPEEDING VIOLATION",
"NO INSURANCE / INSPECTION",
"DRUG TRAFFICKING / CONTRABAND",
"TACTICAL SURVEILLANCE TARGET",
"SUSPICIOUS ACTIVITY / ANOMALY"
}
-- Time limit for storing BOLO scans in hours before automatic deletion (168 = 7 days)
Config.BoloScanExpiryHours = 168
-- Number of historical spot points to render on the route path of target tracking
Config.TrackingPathPoints = 10
-- Expansion speed scale factor for the BOLO predictive search radius circle (0.35 = controlled search area)
Config.PredictiveGrowthScale = 0.35
-- Maximum predictive search radius limit in meters before target is marked as lost (5000.0 = 5 km)
Config.MaxPredictiveRadiusMeters = 5000.0
-- Maximum predictive search duration in seconds before circle vanishes (1800 = 30 minutes)
Config.MaxPredictiveDurationSec = 1800
-- ============================================================================
-- 2. COMMANDS, PERMISSIONS & ACCESSIBILITY
-- ============================================================================
-- Client command name to execute diagnostic system checks
Config.DebugCommand = "checkanpr"
-- Toggle job-based access controls for placement and tablet commands
Config.UseJobCheck = true
-- List of job names authorized to open/place ANPR camera poles
Config.AllowedJobs = { "police", "sheriff" }
-- Interactive Admin Management Map command
Config.AdminMenuCommand = "anpr_admin"
-- Standalone ACE permission for admin access
Config.AdminAcePermission = "anpr.admin"
-- User roles permitted to access the admin management menu ("*" = wildcard for all admins)
Config.AdminRoles = { "admin", "god", "superadmin", "*" }
-- ============================================================================
-- 3. NUI CUSTOMIZATION & LANGUAGE
-- ============================================================================
-- System display language: "en" (English) or "nl" (Dutch)
Config.Language = "en"
-- Default officer name displayed on NUI header when unauthenticated
Config.DefaultOfficer = "Officer R. Albers"
-- License plate visual style: "universal" (US/GTA style) or "dutch" (Yellow NL style)
Config.PlateStyle = "universal"
-- Region / Server name header printed on top of universal license plates
Config.PlateServerName = "Mountain Mods"
-- ============================================================================
-- 4. SPEED MEASUREMENT & CALIBRATION
-- ============================================================================
-- Primary speed measurement unit: "kmh" (KM/H) or "mph" (MPH)
Config.SpeedUnit = "kmh"
-- Conversion multiplier from GTA V m/s (3.6 for KM/H, 2.236936 for MPH)
Config.SpeedMultiplier = 3.6
-- Speed calibration offset to align with custom vehicle handling/speedometer scripts
Config.SpeedOffset = 0
-- Default street speed limit in KM/H applied to unconfigured camera poles
Config.DefaultSpeedLimit = 80
-- Speed threshold (in KM/H above limit) required to trigger a SPEEDING alert (0 = exact speed limit)
Config.SpeedingThreshold = 0
-- ============================================================================
-- 5. CCTV CAMERA POLE STREAMING & PROPS
-- ============================================================================
-- Radius distance in meters to stream and spawn camera pole props on the client
Config.PoleSpawnDistance = 150.0
-- Interval in milliseconds between streaming distance check ticks
Config.StreamingCheckInterval = 1000
-- ============================================================================
-- 6. VEHICLE SCANNING LOOP & COOLDOWNS
-- ============================================================================
-- Interval in milliseconds between vehicle scanning ticks
Config.ScanInterval = 200
-- Minimum vehicle speed in m/s (~5 KM/H) required to trigger a camera scan
Config.ScanMinSpeed = 1.4
-- Maximum detection distance in meters from camera pole to passing vehicle
Config.ScanDistance = 30.0
-- Cooldown in milliseconds before the same camera can scan the same vehicle again
Config.ScanCooldown = 15000
-- ============================================================================
-- 7. SCANNING FILTER & PHOTO CAPTURE MODES
-- ============================================================================
-- Specifies which passing vehicles are scanned and recorded into system history:
-- "all" -> Scan and log every passing vehicle (Standard mode)
-- "only_bolo_and_speeding" -> Scan only vehicles on active BOLO or violating speed limit
-- "only_bolo" -> EXCLUSIVELY scan vehicles on active BOLO hotlist
Config.ScanningFilterMode = "all"
-- Specifies when camera snapshots, flashes, and shutter audio are executed:
-- "only_bolo_and_speeding" -> Take photos for active BOLO hits OR speeding violations
-- "only_bolo" -> EXCLUSIVELY take photos for active BOLO hits
-- "all" -> Take photos for all scanned vehicles
Config.PhotoCaptureFilter = "only_bolo_and_speeding"
-- ============================================================================
-- 8. ANPR VEHICLE EXCLUSION (EMERGENCY & NPC BYPASS)
-- ============================================================================
-- If true, ambient vehicles driven by AI/NPC peds will NEVER be scanned by ANPR
Config.IgnoreNPCVehicles = true
-- Vehicle classes completely bypassed by ANPR (Class 18 = Emergency vehicles)
Config.IgnoredVehicleClasses = {
18 -- Emergency Vehicles (Police, Ambulance, Fire Brigade)
}
-- Specific vehicle model names bypassed by ANPR scanning (case-insensitive)
Config.IgnoredVehicleModels = {
"police", "police2", "police3", "police4", "fbi", "fbi2",
"sheriff", "sheriff2", "policeb", "polmav", "ambulance", "firetruk"
}
-- ============================================================================
-- 9. CCTV CAMERA VIEWER & INTERACTIVE CONTROLS
-- ============================================================================
-- Vertical camera offset in meters above CCTV pole base
Config.CamHeightOffset = 4.5
-- Camera Field of View (FOV) angle
Config.CamFOV = 50.0
-- Minimum vertical look angle (Pitch)
Config.CamPitchMin = -35.0
-- Maximum vertical look angle (Pitch)
Config.CamPitchMax = 5.0
-- Maximum horizontal panning angle (Yaw) to left/right
Config.CamYawMaxDiff = 50.0
-- Mouse rotation sensitivity for camera viewer
Config.CamSensitivity = 2.5
-- Timecycle visual filter applied during CCTV viewing
Config.CamTimecycle = "scanline_cam_cheap"
-- Timecycle visual filter intensity
Config.CamTimecycleStrength = 1.2
-- Help text overlay instruction when camera viewer is active
Config.CamHelpText = "Use ~INPUT_LOOK_LR~ / ~INPUT_LOOK_UD~ (Mouse) to look around.~n~Press ~INPUT_CELLPHONE_CANCEL~ (Backspace) to exit."
-- ============================================================================
-- 10. VEHICLE PHOTO CAPTURE & DISCORD WEBHOOK
-- ============================================================================
-- Discord Webhook URL used to upload vehicle evidence photos
Config.DiscordWebhook = "https://discord.com/api/webhooks/YOUR_WEBHOOK_URL_HERE"
-- Toggle camera shutter audio and screen flash during photo capture
Config.EnableCameraFlash = true
-- Camera perspective mode:
-- false -> Switch 1 frame to CCTV pole perspective for camera photo capture
-- true -> Capture directly from player perspective (no camera switch)
Config.CaptureFromPlayerPOV = false
-- Name of the screenshot resource ("auto" automatically detects screenshot-basic)
Config.ScreenshotResource = "auto"
-- Photo storage mode: "discord" (Discord Webhook CDN) or "none" (text telemetry only)
Config.PhotoStorageMode = "discord"
-- Maximum number of photos stored per vehicle plate in storage (older ones pruned)
Config.MaxImagesPerPlate = 10
-- ============================================================================
-- 11. SERVER HISTORY, RETENTION & CLEANUP
-- ============================================================================
-- Maximum number of general scans kept in memory history cache
Config.MaxScanHistory = 50
-- Maximum number of scans returned for a single camera pole inspection
Config.MaxCamScans = 10
-- Maximum historical route points stored per plate for tracking analysis
Config.MaxRoutePointsPerPlate = 50
-- Maximum separate trips displayed in dossier route overview list
Config.MaxDisplayRoutes = 10
-- Default priority assigned to new BOLO entries ("LOW", "MEDIUM", "HIGH")
Config.DefaultPriority = "LOW"
-- Fallback vehicle model label when model name resolution fails
Config.FallbackModelName = "UNKNOWN"
-- Interval in minutes between periodic database & file storage cleanup ticks
Config.CleanupInterval = 10
-- Expiry period in days for local photo files
Config.LocalPhotoExpiryDays = 7
-- ============================================================================
-- 12. PERSISTENCE: FILE & DATABASE NAMES
-- ============================================================================
Config.PolesFile = "poles.json"
Config.BolosFile = "bolos.json"
Config.ScansFile = "scans.json"
Config.PolesTable = "anpr_poles"
Config.BolosTable = "anpr_bolos"
Config.ScansTable = "anpr_scans"
Config.ESXOwnedVehiclesTable = "owned_vehicles"
Config.QBPlayerVehiclesTable = "player_vehicles"
-- ============================================================================
-- 13. AUDIO, DISPATCH & HUD NOTIFICATIONS
-- ============================================================================
-- Toggle frontend notification sound effects
Config.PlaySound = true
-- Frontend sound name played on dispatch alert
Config.SoundName = "Event_Message_Purple"
-- Frontend soundset name
Config.SoundSet = "GTAO_FM_Events_Soundset"
-- Text template for dispatch notification alerts
Config.DispatchNotificationText = "~r~[ANPR DISPATCH]~w~ Vehicle %s (%s) spotted at %s"
-- Text template for GPS waypoint notifications
Config.GpsNotificationText = "~g~[ANPR]~w~ Waypoint set to %s"
-- Text template for unauthorized access warnings
Config.NoPermissionText = "~r~[ANPR]~w~ You do not have permission to access the ANPR system."
-- Dispatch alert NUI popup position: "top-right" or "center"
Config.DispatchAlertPosition = "top-right"
-- ============================================================================
-- 14. ANPR PATROL MONITOR HUD
-- ============================================================================
-- Command name to toggle in-car ANPR patrol monitor HUD
Config.MonitorCommand = "anpr_monitor"
-- Jobs permitted to activate the patrol monitor HUD
Config.MonitorAllowedJobs = { "police", "sheriff" }
-- Vehicles permitted to use patrol monitor ("*" = wildcard for all vehicles)
Config.MonitorAllowedVehicles = "*"
-- Front/rear scanning distance in meters for patrol monitor
Config.MonitorDistance = 40.0
-- Maximum lateral distance (lane width) in meters for patrol monitor scanning
Config.MonitorLaneWidth = 5.0
-- Position of patrol monitor HUD: "bottom-right" or "top-right"
Config.MonitorPosition = "bottom-right"
-- ============================================================================
-- 15. NOTIFICATION & DISPATCH CALLBACK FUNCTIONS
-- ============================================================================
-- Client-side custom notification wrapper function
Config.ShowNotification = function(message, type)
BeginTextCommandThefeedPost("STRING")
AddTextComponentSubstringPlayerName(message)
EndTextCommandThefeedPostTicker(false, true)
-- Framework example (e.g. QBCore):
-- QBCore.Functions.Notify(message, type)
end
-- Server-side dispatch event callback triggered on BOLO hits & alerts
Config.OnDispatch = function(scan)
local msg = string.format("[ANPR DISPATCH] Alert! Vehicle %s (%s, %s) detected at %s!",
scan.plate, scan.vehicle, scan.color, scan.location)
print(msg)
-- Custom dispatch example (e.g. ps-dispatch):
-- TriggerEvent("ps-dispatch:server:CreateDispatchDeliver", scan)
end
-- ============================================================================
-- 16. MASTER INTEGRATION BRIDGES & FRAMEWORKS
-- ============================================================================
-- Core framework bridge ("auto", "qbcore", "esx", "vrp", "qbx", "ox", "standalone")
Config.Framework = "auto"
-- Notification resource bridge ("auto", "okokNotify", "qbcore", "esx", "standalone")
Config.NotifySystem = "auto"
-- Dispatch resource bridge ("auto", "ps-dispatch", "qs-dispatch", "cd_dispatch", "core_dispatch", "rcore_dispatch", "codem-dispatch", "emergency-dispatch", "tmc_dispatch", "deltarix_dispatch", "lb-tablet", "none")
Config.DispatchSystem = "auto"
-- Garage resource bridge ("auto", "qs-garages", "okokGarage", "jg-advancedgarages", "cd_garage", "qbcore", "esx")
Config.GarageSystem = "auto"
-- Fake plate resource bridge ("auto", "brazzers-fakeplates", "cw-plateswap", "none")
Config.FakePlateSystem = "auto"
-- Vehicle insurance resource bridge ("auto", "m-insurance", "none")
Config.InsuranceSystem = "auto"
-- MDT BOLO synchronization bridge ("auto", "wasabi_mdt", "sonorancad", "redutzu-mdt", "tk_mdt", "kartik_mdt", "plt_departments", "meos", "none")
Config.MdtBoloSync = "auto"
-- Enable nearest postal integration for postcode display in dispatch alerts
Config.UseNearestPostal = true
-- ============================================================================
-- 17. CUSTOM RESOURCE NAME OVERRIDES
-- ============================================================================
Config.CustomResourceNames = {
Screenshot = "auto", -- e.g. "screenshot-basic" or "screenshot_basic"
Postal = "auto", -- e.g. "nearest-postal" or "qb-postals"
Dispatch = "auto", -- e.g. "ps-dispatch" or "qs-dispatch"
MDT = "auto", -- e.g. "wasabi_mdt" or "sonorancad"
Garage = "auto", -- e.g. "qs-garages" or "jg-advancedgarages"
FakePlate = "auto", -- e.g. "brazzers-fakeplates" or "cw-plateswap"
Insurance = "auto" -- e.g. "m-insurance"
}
-- ============================================================================
-- 18. RICH DISCORD LOGGING EMBEDS
-- ============================================================================
Config.EnableDiscordEmbeds = true
Config.DiscordEmbedWebhook = "" -- Leave empty to automatically use Config.DiscordWebhook
Config.DiscordEmbedTemplates = {
Bolo = {
Enable = true,
Title = "BOLO SPOTTED",
Color = 16711765, -- Red (#FF0055)
FieldLabels = {
Plate = "Plate:",
VehicleType = "Vehicle Type:",
Time = "Time:",
Color = "Color:",
Location = "Location:",
Speed = "Speed:",
Camera = "Camera:",
Reason = "BOLO Reason:"
}
},
Speeding = {
Enable = true,
Title = "SPEEDING VEHICLE",
Color = 16750848, -- Orange (#FF9900)
FieldLabels = {
Plate = "Plate:",
VehicleType = "Vehicle Type:",
Time = "Time:",
Color = "Color:",
Location = "Location:",
Speed = "Speed:",
Camera = "Camera:"
}
},
Clean = {
Enable = false,
Title = "VEHICLE DETECTED",
Color = 61695, -- Cyan (#00F0FF)
FieldLabels = {
Plate = "Plate:",
VehicleType = "Vehicle Type:",
Time = "Time:",
Color = "Color:",
Location = "Location:",
Speed = "Speed:",
Camera = "Camera:"
}
}
}