Documentation

Config

Explanations and examples for the current Wheel Clamp configuration.

Edit zyke_wheelclamp/shared/unlocked/config.lua. Distances are metres, durations ending in Ms are milliseconds, and chances are percentages unless stated otherwise.

Keybinds can be changed in GTA / FiveM settings; see Commands. Framework, inventory, target, notification, and webhook settings live in zyke_lib. Grinder and disc settings live in zyke_anglegrinder, and the lockpick minigame's own settings in zyke_lockpick.

Every job list takes a job name or {name = "police", minGrade = 2}. An empty list allows everyone, except where noted.

#Full Default Config

#Config.Settings.wheelclamp

#enabled

Enables the resource. When disabled, the clamp items do nothing and the database table is left untouched.

Example:

lua
enabled = true

#jobRequirements

Jobs allowed to fit, remove, lockpick and grind clamps. An empty list allows everyone. remove applies to the key and the "Remove wheelclamp" option, not to paying the release fee.

Example:

lua
jobRequirements = {
    install = {"police", {name = "mechanic", minGrade = 2}},
    remove = {},
    lockpick = {},
    grind = {},
}

#previewPermissions

Who can run the development preview commands, such as wcpreview and wcfit. They only work while the zyke_wheelclamp_dev convar is 1, so live servers can leave this as it is. Entries are ACE permissions or framework groups: "admin" or "owner" on ESX, "god", "admin" or "mod" on QBCore, and "admin", "mod" or "support" on Qbox. ESX matches the exact group name, so list every ESX group that should have access.

Example:

lua
previewPermissions = {"command", "zyke_wheelclamp.preview", "admin", "superadmin", "owner"}

#Officers

Officers can take any wheel clamp off without its key, and read a windscreen clamp's release code on its keypad. Both are logged as officer overrides. Change who counts as an officer in server/unlocked/can_checks.lua.

#officer.jobs

Jobs that count as officers. An empty list turns both abilities off.

Example:

lua
jobs = {"police"}

#officer.onDutyOnly

Only counts players who are on duty, on frameworks with a duty state.

Example:

lua
onDutyOnly = true

#officer.override

Lets officers take any wheel clamp off without its key through the "Remove wheelclamp" option.

Example:

lua
override = true

#officer.codeLookup

Shows officers a windscreen clamp's release code on its keypad.

Example:

lua
codeLookup = true

#Admin Commands

#admin.permissions

Permissions checked by the admin commands through zyke_lib. Any match grants access. command is the ACE permission, and the remaining defaults are framework groups, as in previewPermissions.

Example:

lua
permissions = {"command", "admin", "superadmin", "owner"}

#admin.commands

Names of the admin commands. Set a command to false to turn it off. See Commands.

Example:

lua
commands = {info = "clampinfo", remove = "unclamp", clearDropped = "clearclamps"}

#Clamps & Keys

#clamps

The usable clamp items. Each entry maps an item to its prop model and fitting offset in metres (outward away from the wheel, forward, up). droppedModels picks the prop a clamp drops as after a forced removal, and droppedImages sets the inventory image the picked-up item shows. mount = "windscreen" fits the design to the windscreen instead of a wheel; there outward is off the glass and up is up the glass.

The item names must match your inventory. Every entry is registered as a usable item on start.

Example:

lua
clamps = {
    {item = "clamp_claw", model = "zyke_wc_claw_v2", droppedModels = {grind = "zyke_wc_claw_cut", lockpick = "zyke_wc_claw_open"}, droppedImages = {grind = "clamp_claw_cut", lockpick = "clamp_claw_open"}, offset = {outward = 0.0, forward = 0.0, up = 0.0}},
}

#consumeItem

Takes the clamp item when a clamp is fitted and gives it back when it is removed.

Example:

lua
consumeItem = true

#keyItem

The key item handed out when a wheel clamp is fitted. Only the matching key removes the clamp. false disables keys. Windscreen clamps never use a key.

Example:

lua
keyItem = "clamp_key"

#keyCount

Keys that come with a fresh clamp item, 0 or 1. With 0, a new clamp gives no key, so only payment, an officer or force takes it off.

Example:

lua
keyCount = 1

#Fitting & Removal

#installTimeMs

Progress bar duration for fitting a clamp. 0 skips the bar.

Example:

lua
installTimeMs = 4500

#removeTimeMs

Progress bar duration for removing a clamp. 0 skips the bar.

Example:

lua
removeTimeMs = 3500

#interactDistance

Distance from the wheel within which a player can fit, remove, lockpick or grind a clamp.

Example:

lua
interactDistance = 2.0

#aimDistance

Using a clamp item holds it up to aim at a wheel or windscreen within this distance. Confirming walks the player over to fit it.

Example:

lua
aimDistance = 4.0

#maxVehicleSpeedKmh

Vehicles faster than this, in km/h, can't be clamped or unclamped.

Example:

lua
maxVehicleSpeedKmh = 5.0

#interaction

How players reach the options on fitted clamps, dropped clamps and supply peds. "point" shows zyke_lib interaction points: aim at one, scroll between its options and press E. "target" adds them to the target menu instead and needs ox_target or qb-target. Without one, it falls back to points.

Example:

lua
interaction = "point"

#targetRemoval

Offers "Remove wheelclamp" on clamped wheels, through the chosen interaction. On a keyed clamp, the option only shows to players who carry the matching key, and to officers.

Example:

lua
targetRemoval = true

#blockedClasses

Vehicle classes that can never be clamped. Motorcycles (class 8) can't take a windscreen clamp either way.

Example:

lua
blockedClasses = {
    [13] = true, -- Bicycles
    [14] = true, -- Boats
    [15] = true, -- Helicopters
    [16] = true, -- Planes
    [21] = true, -- Trains
}

#Immobilization

How a clamped vehicle is held in place. A windscreen clamp on its own never locks or freezes the vehicle; it blocks the view and sounds the alarm instead.

#immobilization

"wheel" locks the clamped wheels, so the vehicle strains, bumps and eventually bursts the tyre. "freeze" freezes the whole vehicle. "none" only shows the prop.

Example:

lua
immobilization = "wheel"

#wheelBrakePressure

Brake pressure on each clamped wheel in "wheel" mode.

Example:

lua
wheelBrakePressure = 10.0

#wheelDrag

Drag at the hub of each clamped wheel in "wheel" mode.

Example:

lua
wheelDrag = 2.0

#wheelBumpImpulse

Upward kick per bump while a clamped wheel is dragged. 0 disables bumps.

Example:

lua
wheelBumpImpulse = 0.65

#wheelBumpDistance

Metres between bumps while a clamped wheel is dragged.

Example:

lua
wheelBumpDistance = 1.2

#wheelBurstDistance

Metres a clamped wheel is dragged before its tyre bursts. 0 never bursts.

Example:

lua
wheelBurstDistance = 25.0

#burstTyreDropsClamp

A tyre that bursts under a wheel clamp, whether shot, slashed or dragged flat, drops the clamp to the ground undamaged. The wheel takes no clamp until the tyre is fixed. Needs dropped.enabled. false keeps the clamp on. Fitting to a burst tyre is refused either way.

Example:

lua
burstTyreDropsClamp = true

#Lockpicking

Settings under Config.Settings.wheelclamp.lockpicking cover lockpicking a wheel clamp off without its key. Windscreen clamps can't be lockpicked.

#lockpicking.enabled

Registers the lockpick items and allows lockpicking.

Example:

lua
enabled = true

#lockpicking.minigame

"auto" plays the zyke_lockpick minigame at the clamp while it is started, and the skill check without it. "skillcheck" always plays the skill check. zyke_lockpick needs its tension wrench and a pick listed in its own config, and wears the pick itself. itemUsageMode, the item durability values and the timed bar only apply to the skill check.

Example:

lua
minigame = "auto"

#lockpicking.pins

Pin count for the zyke_lockpick minigame, 3 to 9.

Example:

lua
pins = 6

#lockpicking.skillCheck

zyke_lib skill check difficulties, played in order. false skips the check.

Example:

lua
skillCheck = {"easy", "medium", "hard"}

#lockpicking.timeToLockpick

Seconds at the wheel after the skill check, scaled per item by timeMultiplier.

Example:

lua
timeToLockpick = 8

#lockpicking.itemUsageMode

How the pick wears with the skill check. "durability" drains item durability, "breakOnFail" rolls breakChance on a failed attempt, and "disabled" never damages it.

Example:

lua
itemUsageMode = "durability"

#lockpicking.items

Usable lockpick items. durability is the wear taken on success and failure in "durability" mode, breakChance the chance to break on failure in "breakOnFail" mode, and failChance the chance a finished attempt still fails. If your zyke_lockpick pick is a different item, such as hook_pick, add it here too.

Example:

lua
items = {
    lockpick = {
        timeMultiplier = 1.0,
        durability = {success = 0, failure = 20},
        breakChance = 25,
        failChance = 0,
        breakOnChanceFailure = false,
    },
}

#Grinding

Settings under Config.Settings.wheelclamp.grinding cover cutting a wheel clamp off with zyke_anglegrinder. Windscreen clamps can't be ground off.

#grinding.enabled

Offers clamped wheels to the angle grinder.

Example:

lua
enabled = true

#grinding.stages

Each stage is one cut: seconds of cutting plus the grinder's checks. checks takes a list of difficulties, a single difficulty, or false to skip them.

Example:

lua
stages = {
    {checks = {"medium"}, seconds = 2},
}

#grinding.durabilityLoss

Disc wear for a full cut. Mistakes wear more, and an empty disc fails the cut. The cut so far is kept on the clamp, so the next disc carries on from there.

Example:

lua
durabilityLoss = {min = 8, max = 20}

#grinding.standDistance

Metres further back from the wheel than the fitting spot, so the grinder and its sparks stay outside the bodywork. Unused while the grinder's work animation sets its own reach.

Example:

lua
standDistance = 0.3

#Dropped Clamps

Lockpicked, ground-off, burst-off and windscreen clamps drop to the ground for anyone to pick up. Ground-off clamps come back broken and can't be fitted again. Dropped clamps are deleted when the resource stops.

#dropped.enabled

Drops forced-off clamps to the ground. When disabled, the clamp goes to the remover's inventory instead and a ground-off clamp is destroyed.

Example:

lua
enabled = true

#dropped.interactDistance

Distance from which a player can pick up a dropped clamp.

Example:

lua
interactDistance = 2.5

#dropped.pickupAnimation

Animation played when picking up a dropped clamp.

Example:

lua
pickupAnimation = {
    enabled = true,
    dict = "pickup_object",
    clip = "pickup_low",
    duration = 1300,
    startDelay = 200,
}

#Police Alerts

Police are alerted when clamps are lockpicked or ground off in front of witnesses, and when windscreen clamp alarms go off. Plug in your dispatch in server/unlocked/police_alert.lua. See Police Alerts.

#policeAlert.enabled

Enables all police alerts.

Example:

lua
enabled = true

#policeAlert.jobs

Jobs that receive the built-in alert blip and notification.

Example:

lua
jobs = {"police"}

#policeAlert.onDutyOnly

Only alerts players who are on duty, on frameworks with a duty state.

Example:

lua
onDutyOnly = true

#policeAlert.chance

Chance an alert goes out, per type. 0 disables that alert. grind needs zyke_anglegrinder's witnesses enabled. alarm is the windscreen clamp alarm and needs no witness.

Example:

lua
chance = {
    lockpick = 60,
    grind = 80,
    alarm = 100,
}

#policeAlert.delay

Seconds before an alert reaches police, picked between min and max.

Example:

lua
delay = {min = 5, max = 10}

#policeAlert.cooldownSeconds

Seconds before the same vehicle can raise the same alert again.

Example:

lua
cooldownSeconds = 120

#policeAlert.blip

The built-in alert blip: radius in metres, colour id and seconds on the map.

Example:

lua
blip = {radius = 80.0, colour = 1, seconds = 60}

#Witnesses

NPCs that can see a lockpick attempt report it. Grinds use zyke_anglegrinder's own witness settings.

#witnesses.enabled

false alerts on every lockpick attempt without needing a witness.

Example:

lua
enabled = true

#witnesses.maxDistance

The furthest a ped or driven vehicle can be to notice the attempt.

Example:

lua
maxDistance = 30.0

#witnesses.fieldOfView

Sight cone in degrees for peds on foot.

Example:

lua
fieldOfView = 60.0

#witnesses.vehicleFieldOfView

Sight cone in degrees for drivers.

Example:

lua
vehicleFieldOfView = 120.0

#witnesses.recheckInterval

Milliseconds between checks during an attempt. 0 only checks as it starts.

Example:

lua
recheckInterval = 4000

#witnesses.blacklistedModels

Ped models that never count as witnesses.

Example:

lua
blacklistedModels = {"s_m_y_cop_01"}

#Windscreen Clamp

Windscreen clamps have no lock to pick or grind. They come off through the keypad or by breaking the windscreen. See Windscreen Clamp.

#windscreen.codeLength

Length of the release code the fitter sets while fitting. Codes are digits only, 1 to 12 long.

Example:

lua
codeLength = {min = 4, max = 8}

#windscreen.allowPayment

Lets people pay the release fee at the keypad instead of entering the code.

Example:

lua
allowPayment = true

#windscreen.fee

The release fee, fixed when the clamp is fitted. Price it per player or vehicle in GetWindscreenClampFee in server/unlocked/windscreen.lua, or let the fitter pick it through customPricing.

Example:

lua
fee = 750

#windscreen.account

Account the fee is paid from, "bank" or "cash".

Example:

lua
account = "bank"

#windscreen.society

Society account that receives the fee. false keeps the fee out of circulation.

Example:

lua
society = "police"

#windscreen.maxCodeAttempts

Wrong codes before the keypad stops taking codes for everyone and sounds the alarm. Paying still works while it is locked.

Example:

lua
maxCodeAttempts = 5

#windscreen.codeLockoutSeconds

Seconds until a locked keypad takes codes again.

Example:

lua
codeLockoutSeconds = 300

#windscreen.forceFirstPerson

Holds the driver in first person so the clamp blocks the view.

Example:

lua
forceFirstPerson = true

#windscreen.alarmDistance

Metres the vehicle can move before the alarm sounds.

Example:

lua
alarmDistance = 2.0

#windscreen.alarmSeconds

How long the alarm sounds for, in seconds.

Example:

lua
alarmSeconds = 30

#windscreen.alarmSound

The beep played from the clamp while the alarm sounds, through zyke_sounds 0.7.0 or newer. Without it, or set to false, the vehicle's own alarm sounds instead.

Example:

lua
alarmSound = {name = "vehicles/windscreen_clamp_alarm.wav", volume = 0.3, distance = 35.0}

#windscreen.smash

Breaking the windscreen frees the clamp. It needs one of weapons in hand, takes timeMs, and sounds the alarm from the first swing.

Example:

lua
smash = {
    enabled = true,
    timeMs = 6000,
    weapons = {"WEAPON_CROWBAR", "WEAPON_HAMMER", "WEAPON_BAT"},
    animation = {dict = "melee@large_wpn@streamed_core", clip = "ground_attack_on_spot"},
}

#Clamp Notice

A notice on every fitted clamp tells the driver how to get it off. Wheel clamps get a "Read clamp notice" option, and the windscreen keypad shows the same contacts and note. See Clamp Notice & Fees.

#notice.enabled

Shows the clamp notice. Payment at the notice also needs this.

Example:

lua
enabled = true

#notice.allowPayment

Lets the driver pay a wheel clamp's release fee from its notice and lift the clamp off on the spot. false leaves removal to whoever holds the key, so drivers have to get in touch. Windscreen clamps are paid at their keypad instead.

Example:

lua
allowPayment = true

#notice.fee

The wheel clamp release fee, fixed when the clamp is fitted. Price it per player or vehicle in GetWheelclampReleaseFee in server/unlocked/notice.lua, or let the fitter pick it through customPricing.

Example:

lua
fee = 500

#notice.account

Account the fee is paid from, "bank" or "cash".

Example:

lua
account = "bank"

#notice.society

Society account that receives the fee. false keeps the fee out of circulation. On ESX, a job name such as police is paid into society_police.

Example:

lua
society = "police"

#notice.instructions

Your own instructions printed on every notice. false prints the default text for the options enabled here.

Example:

lua
instructions = "Call the LSPD front desk to arrange the release of your vehicle."

#notice.contacts

Numbers printed on every notice, such as a towing company or the police front desk. Tapping one copies it, or dials it once CallClampContact in client/unlocked/notice.lua is tied to your phone.

Example:

lua
contacts = {
    {label = "Parking Enforcement", number = "555-0142"},
}

#notice.fitterNumber

Prints the fitter's own phone number on the notice. It is read from the framework character by default. Change GetClampFitterNumber in server/unlocked/notice.lua to read it from your phone resource.

Example:

lua
fitterNumber = false

#notice.fitterNote

Lets the fitter leave an optional note while fitting, such as where to call or pay.

Example:

lua
fitterNote = false

#notice.noteMaxLength

Maximum length of the fitter's note in characters, at most 500.

Example:

lua
noteMaxLength = 200

#Phone App

Settings under Config.Settings.wheelclamp.phone cover the Clamp Release phone app, which ships with sd-phone, lb-phone and YSeries support. The laptop website follows every setting here except enabled. See Phone App & Website.

#phone.enabled

Turns the phone app on and off. The website keeps working through laptop.site.enabled.

Example:

lua
enabled = true

#phone.searchRadius

Metres from a clamped vehicle within which the app finds it.

Example:

lua
searchRadius = 30.0

#phone.allowPayment

Pays clamps off in the app, after which they drop off the vehicle. While a supported phone is running, clamps are then paid only in the app, and the clamp notice and keypad point players there. false, or no supported phone, keeps payment at the clamp. Wheel clamps also need notice.allowPayment, and windscreen clamps windscreen.allowPayment.

Example:

lua
allowPayment = true

#phone.assistance

Lets drivers ask for someone to come to the vehicle. Requests reach the players on jobs and, with notifyFitter, whoever fitted a clamp on the vehicle, as a notification and a map blip. An empty jobs list leaves requests to the fitter. messageLength is the longest message the driver can add (0 leaves it out, at most 300), expireMinutes how long a request stays open, and cooldownSeconds how long a character waits before asking again.

Example:

lua
assistance = {
    enabled = true,
    jobs = {"police"},
    onDutyOnly = true,
    notifyFitter = true,
    messageLength = 120,
    expireMinutes = 15,
    cooldownSeconds = 60,
    blip = {sprite = 225, colour = 5, seconds = 180},
}

#Laptop Website

#laptop.site

The LS Parking Authority website for zyke_laptop, used only while zyke_laptop is started. url is the address typed into the laptop's browser.

Example:

lua
site = {enabled = true, url = "lsparking.gov"}

#Fee Pricing

#customPricing

Lets the fitter price the release fee while fitting. The fitting form lists the configured fee as the default next to the tiers. With custom.enabled, the fitter can also type any whole amount between min and max. It only shows for clamps that can be paid: wheel clamps need notice.enabled and notice.allowPayment, windscreen clamps windscreen.allowPayment.

Example:

lua
customPricing = {
    enabled = true,
    tiers = {
        {label = "Reduced", price = 250},
        {label = "Repeat offence", price = 1000},
        {label = "Obstruction", price = 1500},
    },
    custom = {enabled = true, min = 0, max = 10000},
}

#Supply Peds

Supply peds hand out, sell and buy back clamps through a menu. Item entries use the configured item names, so renamed items need their entries updated too. See Clamping & Removing.

#vendor.enabled

Spawns the supply peds.

Example:

lua
enabled = true

#vendor.positions

One entry per ped. jobs and onDutyOnly limit who may use it, in the job list format. price is per piece, and 0 hands the item out for free. Purchases are paid from cash first, then bank. buyback lists the items the ped buys back, paid in cash per piece. blip = false hides the map blip; otherwise it takes a table with sprite, color and scale.

Example:

lua
positions = {
    {
        label = "Police Supply",
        model = "s_m_y_cop_01",
        coords = vec4(452.49572753906, -983.80017089844, 30.68959236145, 47.426624298096),
        scenario = "WORLD_HUMAN_CLIPBOARD",
        blip = {sprite = 1, color = 0, scale = 0.7},
        jobs = {"police"},
        onDutyOnly = true,
        items = {
            {name = "clamp_triangle", price = 0},
            {name = "clamp_windscreen", price = 250},
        },
        buyback = {
            {name = "clamp_triangle", price = 100},
        },
    },
}