ATY Scripts Logo
ATY Scripts/Dokümanlar/Weapon Editor/Workbenches

Workbenches

Workbenches

A workbench is how a player reaches the workshop. You build them in game, they are stored in the database, they appear for everyone immediately, and each one is bound to whoever you say it is.

There is no /gunsmith command by default and no fixed workshop zone. This is the door.

Placing one

You need the lab scope.

1. Open the manager

/gunsmithadmin

2. Start a new workbench and pick its locations

The placement flow asks for two separate points, in order:

Point What it is Controls
Access point Where the player stands and interacts Aim, [E] to confirm · wheel = radius · [Backspace] cancel
Weapon spawn point Where the weapon appears on the bench Aim, [E] to confirm · arrows = heading · wheel = height · [Backspace] back
Two points, not one. On a real workbench the place a player stands is not the place the weapon sits. With a single point the player would end up standing inside the bench, or the weapon would float in mid-air.

3. Choose the object

Every workbench carries its own prop, picked while placing:

No object · Tool bench · Tool bench (small) · Tool chest · Table · Gun case
Gun rack · Gun locker · Gun locker (armoured) · Military crate · Ammo crate

No object is a real choice — use it when your map already has a bench there, or when you only want an interaction point.

4. Choose who may use it

Access type Who gets in
public Everyone
job Anyone with that job
grade That job, at or above a minimum grade
citizen One specific citizen ID

The rule is always enforced on the server, not in the UI.

5. Name it and save

The label is what appears on the interaction.

Configuration

Config.Tables = {
    enabled          = true,
    adminScope       = 'lab',
    adminCommand     = 'gunsmithadmin',
    defaultProp      = 'prop_tool_bench02',
    defaultRadius    = 1.2,
    maxSpawnDistance = 15.0,
    props            = { ... },   -- 11 entries
}
Key Default Description
enabled true Turns the whole workbench system off
adminScope 'lab' Scope required to place and remove benches
adminCommand 'gunsmithadmin' The placement command
props 11 entries Selectable objects. Adding one is a config line — no UI change needed
defaultProp 'prop_tool_bench02' Pre-selected in the placement form
defaultRadius 1.2 Interaction radius, metres
maxSpawnDistance 15.0 Warn when the spawn point is this far from the access point

maxSpawnDistance is a warning, not a block. It exists to catch a spawn point accidentally dropped on the other side of the map, not to stop a deliberate layout.

Removing one

The manager lists every workbench with its label, access rule and status. A workbench can be closed (enabled = 0) without deleting it, which is the right move for a business that shuts at night, and deleted outright when it is gone for good.

Fixed workshop zones

The alternative is a fixed point in Config.Zones, referenced from Config.Access.workshop.zones:

Config.Zones = {
    ammunation_1 = { coords = vector3(22.0, -1107.0, 29.8), radius = 1.6, label = 'workshop' },
}
A fixed zone is open to **everyone** and obeys no job or grade rule. Combining one with the workbench system leaves a back door that silently defeats every restriction you set on your benches. `Config.Access.workshop.zones` is empty by default for that reason.

Troubleshooting

A new workbench only appears after a script restart. Fixed in 1.0.1. Bench access depends on job and citizen identity, which is not resolved yet at the moment a player joins; the scan now re-runs when the player loads and whenever their job changes.

The same bench appears two or three times over. Fixed. Two refreshes arriving at once could each spawn the prop, leaving orphans behind. The symptom looks like it depends on player count, but the cause was concurrent refreshes.

The object failed to load. The placement flow says so and lets you continue without one. The workbench still works; it just has no prop.

ATY Scripts LogoATY SCRIPTS

QBCore & ESX için yüksek optimizasyonlu FiveM scriptleri üretiyoruz. Maksimum performans, hassas kod, sıfır gecikme.

Topluluğa Katıl

Partner

Tebex resmi partneri. Güvenli ödeme ve Cfx.re Keymaster entegrasyonu.

Yasal

Rockstar Games, Cfx.re, FiveM veya Take-Two Interactive ile bağlantılı değildir. Satın alımlar Tebex Hizmet Şartları'na tabidir.

© 2026 ATY SCRIPTS. Tüm hakları saklıdır.