Looking for FiveM hosting? View our current hosting offer.
Activation Video
Click to view our locations and postal install video.Activation Guide
- Download and Install the Core
If you haven’t already, be sure to install and configure the SonoranCAD Core first.
- Activate the Submodule and all Dependencies
Follow the submodule activation guide for the required submodules.
- Configure Postal Script and Exports
- If you’re using the publicly available nearest-postal script, you will need to follow the steps in the usage section below.
- If you’re using a custom postal codes file, you will need to add the file to the plugin and Sonoran CAD’s fxmanifest as shown in the usage section below.
- If you’re using an event triggered by a custom postals script, you must configure it as explained in the usage section below.
Configuration
Usage
If the configured postal resource or custom postal data is unavailable at runtime, SonoranCAD will now continue sending regular street names and coordinate-based location updates without a postal prefix. Check the troubleshooting error codes
ERR-LOC-104, ERR-LOC-105, and ERR-LOC-106 if postal data is missing or failing.Using Nearest-Postal
If you’re using the publicly available nearest-postal script, some minor configuration is required.
- Set the Resource Name
In the Sonoran CAD postals plugin config, change the nearestPostalsResourceName value to the exact name of your nearest postals resource.Ex:
nearest-postals-1.5
- Ensure Proper Startup Order
Be sure that you are starting the nearest-postals addon/resource before/above where you ensure sonorancad in your server.cfg.
Be sure to restart both the Sonoran CAD resource and the nearest-postal script, or restart your server entirely to apply the changes made.
Custom Postal Codes File
If you want to use your own custom postal codes file with this plugin, open the config and changemode to file.
Next, copy your custom postal codes file to the submodules/postals folder, and set the value of customPostalCodesFile to the name of this file. Include the .json file extension in the name.
Custom Postal Events
If you’re not using the nearest-postal script or a custom postal codes file, you will need to create a export in your postals script, and have it return the player’s current postal as a string. Additionally, you will need to edit the config to setmode to event, then specify the name of this event in nearestPostalEvent.
Need help? You can always hire a developer.
Troubleshooting
If postal lookup fails, location updates for units will still continue using normal street/location data. Postal-specific failures now surface through the troubleshooting codes below instead of stopping all location updates:ERR-LOC-104: postal resource unavailableERR-LOC-105: configured postal file missing or invalidERR-LOC-106: postal lookup failed at runtime
The configured postals file (postals_file.json) was not found
This error may be seen by users attempting to set up the plugin to use a custom postal codes file. Specifically, the error will look something like this, substitutingpostals_file.json for whatever you’ve named your custom postal codes file to:
files { } section of your fxmanifest with the given code snippet, then changing postals_file.json to match the name of whatever postals file you’re using.
If you’ve manually entered the line, verify that all the lines in the section except for the last are followed with a comma to ensure that the system can properly read it.
