# location structure

Each entry in `Config.Locations` defines one garage location. Below are all accepted fields.

## Top-level fields

| Field         | Type                        | Required | Description                                                                                                      |
| ------------- | --------------------------- | -------- | ---------------------------------------------------------------------------------------------------------------- |
| `Job`         | `string`, `table`, or `nil` | No       | Job name(s) allowed to access this garage. Use a table for multiple jobs. Set to `nil` to skip job-based access. |
| `Gang`        | `string` or `nil`           | No       | Gang name allowed to access this garage. Set to `nil` for no gang access.                                        |
| `Logo`        | `string`                    | Yes      | Path to the logo image relative to the `html/` folder, e.g. `'logos/police.png'`.                                |
| `Theme`       | `table`                     | Yes      | Color theme for the NUI panel. See the **Theming** page.                                                         |
| `Ped`         | `table`                     | Yes      | Ped definition — model, spawn coords, display name, and target label.                                            |
| `SpawnCoords` | `vector4`                   | Yes      | World position and heading where vehicles are spawned.                                                           |
| `Vehicles`    | `table`                     | Yes      | List of vehicle entries available from this garage. See the **Vehicle Entry Structure** page.                    |

## Ped sub-table

| Field         | Type      | Description                                                 |
| ------------- | --------- | ----------------------------------------------------------- |
| `model`       | `string`  | Ped model name, e.g. `'s_m_y_cop_01'`.                      |
| `coords`      | `vector4` | Spawn position and heading of the ped (x, y, z, w).         |
| `name`        | `string`  | Displayed as the panel title inside the NUI menu.           |
| `targetLabel` | `string`  | Label shown in the target interaction prompt above the ped. |

## Access logic

* A player needs to match **either** the `Job` or the `Gang` to gain access — not both.
* When `Job` is a table, the player only needs to match **one** of the listed jobs.
* If both `Job` and `Gang` are `nil`, no player will be able to open the garage.

## Full example

```lua
[3] = { Job = {'police', 'swat'}, Gang = nil, Logo = 'logos/police.png', Theme = { accent = '#3B82F6', accent2 = '#1E3A8A', panelTop = '#121623', panelBot = '#0A0C14', btnTop = '#5078C8', btnBot = '#1E326E' }, Ped = { model = 's_m_y_cop_01', coords = vector4(435.45, -972.96, 25.70, 183.43), name = 'Police Garage', targetLabel = 'Open Police Garage' }, SpawnCoords = vector4(431.17, -988.30, 23.70, 180.39), Vehicles = { { VehicleName = 'Police Car 1', VehicleSpawnName = 'polbmwm3', Grade = 0, livery = 0, colors = {0,0}, extras = {1,2,3,4} }, { VehicleName = 'Police Car 2', VehicleSpawnName = 'nfsexpl', Grade = 0, livery = 2, colors = {0,0}, extras = {1,2,3,4,5,6,7} }, { VehicleName = 'Police Moto', VehicleSpawnName = 'policeb', Grade = 0, livery = 0, colors = {0,0}, extras = {1,2,3,4} }, } },
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://mohssins.gitbook.io/mohscriptsdocs/moh-jobgarage/location-structure.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
