Retro Radar
Common problems and their solutions. If there is an error here that matches your situation, you can resolve it by applying the solution.
The radar is visible but not working
Section titled โThe radar is visible but not workingโIf the radar appears on the screen, everything is working correctly. However, you must activate the front and rear radar systems for the radar features to be active. After pressing the END key, you will enter edit mode. While in edit mode, click the settings icon at the bottom left of the radar. Then, activate the top two settings, the XMIT options. With these settings active, the radar will work without any problems.
If you want to change the radar detection range, you can modify the Config.RadarControlMeters setting in the config. This setting applies to both the front and rear.
The vehicle identification system is not working
Section titled โThe vehicle identification system is not workingโEnsure the radar is active. If the radar is not active, the vehicle identification system will not function. The Config.GetVehicleClass contains the system that defines the vehicle classes. You need to integrate this according to your own server.
It identifies the vehicle, but there is no change in the police vehicle
Section titled โIt identifies the vehicle, but there is no change in the police vehicleโIf you are using a Standalone framework, the tool change will not work. If you wish, you can easily integrate it.
If you are not using Standalone and there is no change to the tool, this is because your class definition is incomplete.
Below is an example of how to add a new class:
Config.OverrideAutomaticClassSelectorModes = { 'A', 'B', 'C',}
Config.GetVehicleClass = function(vehicle, vehicleModel, vehicleLabel) vehicleModel = joaat(vehicleModel)
if joaat('elegy') == vehicleModel then return "A" elseif joaat('sultan') == vehicleModel then return "B" elseif joaat('asbo') == vehicleModel then return "C" end
return "B"end
---
Config.VehicleHandlingFields = { ['fDriveInertia'] = true, ['fBrakeForce'] = true, ['fInitialDriveForce'] = true, ['fInitialDriveMaxFlatVel'] = true, ['fSteeringLock'] = true, ['fDriveBiasFront'] = true,}
Config.VehicleHandling = function(vehicle, activeClass) if not vehicle then return end if Config.Framework == 'Standalone' then return end
local function apply_vehicle_config(hConfig) for k, v in pairs(hConfig) do SetVehicleHandlingFloat(vehicle, 'CHandlingData', k, v) end
-- Refresh Handling local max = GetVehicleMod(vehicle, 11) SetVehicleMod(vehicle, 11, max, false) end
local function apply_vehicle_cosmetic(cosmetics) for k, v in pairs(cosmetics) do if k == "xenon_colour" then SetVehicleXenonLightsColor(vehicle, v) end end end
if activeClass == 'A' then SetVehicleHasUnbreakableLights(vehicle, true) -- Set unbreakable lights SetVehicleLights(vehicle, 0) -- Turn off lights SetVehicleLights(vehicle, 2) -- Turn on lights SetVehicleFullbeam(vehicle, true) -- Turn on fullbeam
ToggleVehicleMod(vehicle, 22, true) -- Xenon
apply_vehicle_config({ ['fInitialDriveForce'] = 0.700000, ['fInitialDriveMaxFlatVel'] = 500.0, ['fDriveInertia'] = 3.0, ['fSteeringLock'] = 70.0, }) apply_vehicle_cosmetic({ ["xenon_colour"] = 8 }) elseif activeClass == 'B' then SetVehicleHasUnbreakableLights(vehicle, true) -- Set unbreakable lights SetVehicleLights(vehicle, 0) -- Turn off lights SetVehicleLights(vehicle, 2) -- Turn on lights SetVehicleFullbeam(vehicle, true) -- Turn on fullbeam
ToggleVehicleMod(vehicle, 22, true) -- Xenon
apply_vehicle_config({ ['fDriveInertia'] = 1.5, ['fBrakeForce'] = 2.0, }) apply_vehicle_cosmetic({ ["xenon_colour"] = 5 }) elseif activeClass == 'C' then SetVehicleHasUnbreakableLights(vehicle, true) -- Set unbreakable lights SetVehicleLights(vehicle, 0) -- Turn off lights SetVehicleLights(vehicle, 2) -- Turn on lights SetVehicleFullbeam(vehicle, true) -- Turn on fullbeam
ToggleVehicleMod(vehicle, 22, true) -- Xenon
apply_vehicle_config({ ['fDriveBiasFront'] = 1.0, }) apply_vehicle_cosmetic({ ["xenon_colour"] = 11 }) else -- Default mode local VehiclePlate = GetVehicleNumberPlateText(vehicle) local VehicleOnChache = Config.VehicleCacheDB[VehiclePlate] if not VehicleOnChache then return end
SetVehicleXenonLightsColor(vehicle, 0)
for k, v in pairs(VehicleOnChache['custom_handling_vars']) do SetVehicleHandlingFloat(vehicle, 'CHandlingData', k, v) end VehicleOnChache['custom_handling_vars'] = nil
-- Refresh Handling local max = GetVehicleMod(vehicle, 11) SetVehicleMod(vehicle, 11, max, false)
Wait(250)
Config.VehicleCacheDB[VehiclePlate] = nil
SetVehicleHasUnbreakableLights(vehicle, false) -- Remove unbreakable lights endendHow can I localize?
Section titled โHow can I localize?โThere are 2 locations available for localization: config.lua and html/config.json
Config.Notification = function(text) if not text then return end
-- Language supports if text == 'cdWaitTime' then text = 'You cannot change modes that quickly! Only the radar lock active vehicle performance mode has not been changed.' end
if Config.Framework == 'ESX' then TriggerEvent('esx:showNotification', text) elseif Config.Framework == 'QBCore' or Config.Framework == 'QBX' then TriggerEvent('QBCore:Notify', text) endend{ "lang": { "FRONT": "FRONT", "REAR": "REAR", "MODEL": "MODEL", "COLOR": "COLOR", "CLASS": "CLASS", "SL": "SL", "HOLD": "HOLD", "XMIT": "XMIT", "FAST": "FAST", "SAME": "SAME", "OPP": "OPP", "MENU": "MENU", "FRONT_ANTENNA": "FRONT ANTENNA", "REAR_ANTENNA": "REAR ANTENNA", "PATROL_SPEED": "PATROL SPEED", "LOCK": "LOCK", "MODE": "MODE", "NONE": "NONE", "SETTINGS_TITLE": "SETTINGS", "SETTINGS_DESC": "CHANGE YOUR SETTINGS", "ANTENNA_FRONT": "Fromt Antenna", "ANTENNA_REAR": "Rear Antenna", "PLATE_SCANNER": "Plate Scanner", "DATA_SCREEN": "Data Screen", "RADAR_SECTION": "Radar", "MISC_SECTION": "Misc", "DISPLAY_SECTION": "Display", "TOGGLE_XMIT": "XMIT", "DESC_XMIT": "TURN ON/OFF THE ANTENNA", "TOGGLE_PLATE": "PLATE", "DESC_PLATE": "TURN ON/OFF PLATE SCANNER", "TOGGLE_DATA": "DATA SCREEN", "DESC_DATA": "TURN ON/OFF DATA SCREEN", "TOGGLE_RADAR": "RADAR", "DESC_RADAR": "TURN ON/OFF RADAR", "TOGGLE_FAST_LOCK": "ENABLE RADAR FAST LIMIT", "DESC_FAST_LOCK": "AUTOMATICALLY LOCK ON FAST VEHICLES", "LABEL_FAST_LIMIT": "VEHICLE RADAR FAST LIMIT", "DESC_FAST_LIMIT": "DETECT VEHICLES OVER THE SPEED LIMIT", "LABEL_RESET": "LOCKFAST RESET", "DESC_RESET": "RESET THE LOCKFAST", "BTN_RESET": "RESET", "LABEL_EDIT": "EDIT MODE", "DESC_EDIT": "EDIT THE POSITIONS OF ALL UI'S", "BTN_EDIT": "EDIT", "LABEL_SCALE_RADAR": "VEHICLE RADAR SCALE", "DESC_SCALE_RADAR": "SCALE OF THE VEHICLE RADAR", "LABEL_SCALE_PLATE": "VEHICLE PLATE SCALE", "DESC_SCALE_PLATE": "SCALE OF THE VEHICLE PLATE", "LABEL_SCALE_DATA": "VEHICLE DATA SCREEN SCALE", "DESC_SCALE_DATA": "SCALE OF THE VEHICLE DATA SCREEN", "LABEL_THEME": "THEME", "DESC_THEME": "COLOR SCHEME OF THE UI", "TOGGLE_FONT": "CLEAR FONT", "DESC_FONT": "USE A CLEARER FONT FOR TEXT", "LABEL_RESET_TIME": "TOP SPEED RESET TIME", "DESC_RESET_TIME": "TIME IN SECONDS TO RESET TOP SPEED" }, "settings": { "showModel": true, "showClass": true, "showLocation": true, "showSpeedLimit": true, "showColor": true, "useClearFont": false, "topSpeedResetTime": 5 }}