ANPR Installation & Setup
Setting up the MTM-ANPR system on your FiveM server requires a few straightforward steps. Follow this guide to import database schemas, configure external Discord CDN storage, and adjust essential resource parameters.
Prerequisites & Dependencies
Section titled “Prerequisites & Dependencies”Ensure your server environment has the following resources installed and operational before starting MTM-ANPR:
| Dependency | Purpose | Minimum Version |
|---|---|---|
oxmysql |
Asynchronous database connection engine | v2.4.0+ |
MTM-CORE |
Core gizmo and math library for 3D camera pole placement | Latest |
screenshot-basic |
High-resolution WebGL camera perspective buffer capture | Latest |
| Database Server | MySQL / MariaDB server | MariaDB 10.4+ / MySQL 5.7+ |
Installation Process
Section titled “Installation Process”-
Extract Resource Files Extract the downloaded
.ziparchive from Keymaster directly into your server’sresources/folder. Ensure the folder name remainsMTM-ANPR. -
Execute Database SQL Schema Open your database management client (HeidiSQL, DBeaver, or phpMyAdmin) and execute the
database.sqlscript located in the root of theMTM-ANPRfolder:SOURCE C:/FXServer/resources/MTM-ANPR/database.sql; -
Configure Discord Webhook for Photographic Evidence The ANPR system utilizes Discord as an external content delivery network (CDN) for vehicle infraction photos:
- In your Discord server, open your desired evidence channel settings.
- Navigate to Integrations -> Webhooks -> New Webhook.
- Copy the generated Webhook URL.
- Open
shared/config.luaand insert the URL intoConfig.DiscordWebhook:Config.DiscordWebhook = "https://discord.com/api/webhooks/1234567890/abcdefghij..."
-
Verify Framework & Speed Unit Settings Open
shared/config.luato review key operational parameters:- Set
Config.SpeedUnitto"kmh"or"mph". - Verify
Config.AllowedJobsmatches your server’s police job names (e.g.{ "police", "sheriff", "kmar" }). - Confirm
Config.Frameworkis set to"auto"(or explicitly set"qbcore","esx","qbx","vrp","ox","standalone").
- Set
-
Configure Boot Sequencing in
server.cfgAdd the resource to yourserver.cfgfile, ensuring dependencies start prior to the script:# Database & Utilitiesensure oxmysqlensure ox_libensure screenshot-basic# Framework (Optional - Skip if Standalone)ensure qb-core # or es_extended / qbx_core / vrp / ox_core# MTM Resource Suiteensure MTM-COREensure MTM-ANPR -
Start FXServer Launch your FiveM server and check the console output to verify database connectivity and license authorization.
Database Table Structure
Section titled “Database Table Structure”The database.sql script initializes three dedicated tables:
| Table Name | Description | Key Fields |
|---|---|---|
anpr_poles |
Stores deployed camera locations, rotation, speed limits, and detection radii. | id, name, coords, heading, speed_limit, detection_range |
anpr_bolos |
Stores the active watchlist of wanted vehicles, suspect descriptions, and priority levels. | id, plate, model, reason, priority, notes, officer |
anpr_scans |
Stores historical vehicle passings, timestamps, calculated speeds, locations, and image URLs. | id, plate, model, speed, street, postal, image_url, created_at |
Essential Configuration Summary
Section titled “Essential Configuration Summary”-- Primary speed measurement standard ("kmh" or "mph")Config.SpeedUnit = "kmh"
-- System interface language ("en" or "nl")Config.Language = "en"
-- Authorized job roles for tablet and camera placementConfig.AllowedJobs = { "police", "sheriff" }
-- Scanning filter mode: "all" or "only_bolo_and_speeding"Config.ScanningFilterMode = "all"
-- Bypass ambient non-player NPC traffic (true = player-driven vehicles only)Config.IgnoreNPCVehicles = true