Zones
Market zones define where players can list and buy vehicles. Each zone has an NPC, a blip, and a set of parking slot boxes (where vehicles are physically displayed for sale).
Structure
shared/config.lua
Config.Zones = {
{
id = "zone1",
coords = vector4(-2187.8787, -409.0271, 13.1511, 231.3093),
distance = 1.5,
name = "Mark",
blip = {
sprite = 1,
colour = 1,
scale = 1.0,
display = 4,
},
npc = {
name = "Mark",
hash = 0x18CE57D0,
scenario = "WORLD_HUMAN_CLIPBOARD",
target = {
icon = "fas fa-shopping-basket",
label = "Mark - Car Market",
distance = 2.0,
key = 38,
},
},
CarMarketBoxes = {
{ id = 'zone1_slot1', coords = vec3(-2160.43, -402.35, 13.39), size = vec3(3, 5, 3), rotation = 82.9 },
{ id = 'zone1_slot2', coords = vec3(-2159.97, -396.41, 13.39), size = vec3(3, 5, 3), rotation = 82.9 },
{ id = 'zone1_slot3', coords = vec3(-2158.71, -390.22, 13.39), size = vec3(3, 5, 3), rotation = 82.9 },
},
},
-- more zones...
}Fields
| Field | Type | Purpose |
|---|---|---|
id | string | Unique identifier (referenced in DB, slot ownership, etc.) |
coords | vector4 | NPC position + heading |
distance | number | Interaction radius (meters) |
name | string | Display name (shown in UI) |
blip | table | Standard FiveM blip config |
npc | table | Ped model + scenario + targeting config |
CarMarketBoxes | table[] | Slot boxes where listed vehicles spawn |
CarMarketBoxes
Each box represents one physical slot in the world.
| Field | Type | Purpose |
|---|---|---|
id | string | Unique slot ID — players buy individual slots by this |
coords | vec3 | World position of the slot |
size | vec3 | Bounding box used for proximity checks |
rotation | number | Heading the vehicle spawns with |
Adding a new zone
-
Pick coords in-game
Use/copycoordsfromkoja-libor any dev tool to grabvector4for the NPC spawn. -
Add the zone entry
Append a new table toConfig.Zoneswith a uniqueid. -
Place slot boxes
Walk around the parking area and place 3–10CarMarketBoxes. Eachcoordsshould be the center of where a parked car will sit. -
Restart and test
refreshandrestart koja-carmarket. The blip + NPC should appear at the new zone.
Default zones shipped
| Zone ID | Name | Location |
|---|---|---|
zone1 | Mark | Mark's car shop, near La Mesa |
zone2 | Legion | Legion Square |
zone3 | Sandy Shores | Sandy Shores |
zone4 | Lotnisko | LSIA airport area |
zone5 | Paleto | Paleto Bay |
Feel free to remove or replace any of them — they're examples.
Related pages
- Configuration — Configure zones, parking, exchange rules, test drives, and custom images.
- Features — Player-facing flows and core marketplace features.
- Installation — Welcome to Koja-Carmarket, a player-driven car market with auctions, exchange zones, rentable parking slots and test drives.
- Exports & Commands — All public API surface of koja-carmarket.
- Database — Full reference for every table created by koja-carmarket.
- CarMarket — back to the section overview