---
description: Welcome to your complimentary apartment
---

# qb-apartments

## Introduction

* This resource manages the apartment system for players. It uses qb-interior to spawn shells at a specific set of coordinates and functions the same as housing except by default the apartments do not cost any money

## Preview

![](https://28573704-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F8LXqNDrsGXtPEmG1nWKu%2Fuploads%2FfMhwVy0ZsdVG0TCEH4PV%2Fimage%20\(7\).png?alt=media\&token=d184537b-7601-4009-acd5-787e40ba653a)

## Configuration

```lua
Apartments = {}
Apartments.Starting = true/false -- Enable or disable starting apartments 
Apartments.SpawnOffset = 30 -- How far under the map the apartment shell will spawn
Apartments.Locations = { -- Create new apartment locations
    ["apartment1"] = {
        name = "apartment1", -- The apartment name that saves in the database
        label = "South Rockford Drive", -- The label of the apartment (shown in preview)
        coords = { -- The apartment entrance location 
            enter = vector4(-667.02, -1105.24, 14.63, 242.32),
        },
        polyzoneBoxData = { -- The polyzone box information for the entrance
            heading = 245,
            minZ = 13.5,
            maxZ = 16.0,
            debug = false,
            length = 1,
            width = 3,
            distance = 2.0,
            created = false
        }
    },
}
```
