> For the complete documentation index, see [llms.txt](https://zloma-scripts.gitbook.io/zloma-scripts/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://zloma-scripts.gitbook.io/zloma-scripts/zloma_garages-paid/api-reference/client-exports.md).

# Client Exports

## Garage / Impound State

### GetCurrentGarage / SetCurrentGarage

```lua
local garageId = exports['zloma_garages']:GetCurrentGarage()
exports['zloma_garages']:SetCurrentGarage(garageId)
```

### GetCurrentImpound / SetCurrentImpound

```lua
local impoundId = exports['zloma_garages']:GetCurrentImpound()
exports['zloma_garages']:SetCurrentImpound(impoundId)
```

***

## Vehicle Properties

### GetVehicleProperties

Gets comprehensive vehicle properties.

```lua
local props = exports['zloma_garages']:GetVehicleProperties(vehicle)
```

| Param       | Type   | Description                   |
| ----------- | ------ | ----------------------------- |
| vehicle     | number | Vehicle entity handle         |
| **Returns** | table  | Full vehicle properties table |

***

### SetVehicleProperties

Applies vehicle properties to a spawned vehicle.

```lua
exports['zloma_garages']:SetVehicleProperties(vehicle, props)
```

***

### GetEnhancedVehicleProperties / ApplyEnhancedVehicleProperties

Extended property getters including custom data.

```lua
local props = exports['zloma_garages']:GetEnhancedVehicleProperties(vehicle)
exports['zloma_garages']:ApplyEnhancedVehicleProperties(vehicle, props)
```

***

## Vehicle Nicknames

### GetVehicleNickname / SetVehicleNickname

```lua
local name = exports['zloma_garages']:GetVehicleNickname(plate)
exports['zloma_garages']:SetVehicleNickname(plate, 'My Car')
```

### GetVehicleDisplayName

Returns nickname if set, otherwise the model name.

```lua
local display = exports['zloma_garages']:GetVehicleDisplayName(plate, model)
```

***

## Spawn System

### SpawnVehicle

Spawns a vehicle from garage.

```lua
exports['zloma_garages']:SpawnVehicle(params)
```

### SpawnVehicleHybrid

Hybrid spawn handler that works for all vehicle types and sources.

```lua
exports['zloma_garages']:SpawnVehicleHybrid(params)
```

### Type-Specific Spawns

```lua
exports['zloma_garages']:SpawnFromGarage(params)
exports['zloma_garages']:SpawnFromPersonalImpound(params)
exports['zloma_garages']:SpawnFromPoliceImpound(params)
exports['zloma_garages']:SpawnFromOrgImpound(params)
```

***

## Spawn Points

### SpawnPoints\_FindFirstFree

Finds the first unoccupied spawn point.

```lua
local point = exports['zloma_garages']:SpawnPoints_FindFirstFree(spawnPoints)
```

### SpawnPoints\_FindWithFallback

Finds a spawn point, with automatic offset fallback if all are occupied.

```lua
local point = exports['zloma_garages']:SpawnPoints_FindWithFallback(spawnPoints)
```

### SpawnPoints\_IsPointFree

Checks if a specific spawn location is unoccupied.

```lua
local free = exports['zloma_garages']:SpawnPoints_IsPointFree(coords, radius)
```

### SpawnPoints\_GetForGarage / SpawnPoints\_GetForImpound

```lua
local points = exports['zloma_garages']:SpawnPoints_GetForGarage(garageId)
local points = exports['zloma_garages']:SpawnPoints_GetForImpound(impoundId)
```

***

## Vehicle Preview

### StartPreviewSession / EndPreviewSession

```lua
exports['zloma_garages']:StartPreviewSession(params)
exports['zloma_garages']:EndPreviewSession()
```

### CreatePreviewVehicle / DeletePreviewVehicle / UpdatePreviewVehicle

```lua
exports['zloma_garages']:CreatePreviewVehicle(params)
exports['zloma_garages']:DeletePreviewVehicle()
exports['zloma_garages']:UpdatePreviewVehicle(params)
```

### Camera Controls

```lua
exports['zloma_garages']:CycleNextView()
exports['zloma_garages']:CyclePrevView()
local view = exports['zloma_garages']:GetCurrentCameraView()
local active = exports['zloma_garages']:IsPreviewActive()
```

***

## UI Controls

### CloseUI / ForceCloseNUI

```lua
exports['zloma_garages']:CloseUI()
exports['zloma_garages']:ForceCloseNUI()
```

### IsNuiOpen

```lua
local isOpen = exports['zloma_garages']:IsNuiOpen()
```

### ShowNotification

```lua
exports['zloma_garages']:ShowNotification(message, type)
-- type: 'success', 'error', 'info', 'warning'
```

***

## Shared Access

### OpenSharedVehiclesMenu / OpenSharedGaragesMenu

```lua
exports['zloma_garages']:OpenSharedVehiclesMenu()
exports['zloma_garages']:OpenSharedGaragesMenu()
```

### GetSharedWithMe / GetSharedByMe

```lua
local sharedWithMe = exports['zloma_garages']:GetSharedWithMe()
local sharedByMe = exports['zloma_garages']:GetSharedByMe()
```

***

## Fake Plates (Client)

### applyFakePlates / removeFakePlates

```lua
exports['zloma_garages']:applyFakePlates(vehicle)  -- 10s animation
exports['zloma_garages']:removeFakePlates(vehicle)  -- 10s animation
```

Both functions include a progress bar animation that can be cancelled by the player.

***

## Utility

### DeleteVehicleSafe

Safely deletes a vehicle entity with proper cleanup.

```lua
exports['zloma_garages']:DeleteVehicleSafe(vehicle)
```

### GiveVehicleKeys

Client-side key grant via zloma\_core.

```lua
exports['zloma_garages']:GiveVehicleKeys(plate)
```

### L (Localization)

Returns a translated string for the current locale.

```lua
local text = exports['zloma_garages']:L('garage_opened', garageName)
```

***

## Police Impound (Client)

### OpenImpoundVehicleMenu

Opens the police impound dialog for a nearby vehicle.

```lua
exports['zloma_garages']:OpenImpoundVehicleMenu()
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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://zloma-scripts.gitbook.io/zloma-scripts/zloma_garages-paid/api-reference/client-exports.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.
