ktoxktox docs

Getting Started

Installation and setup guide for ktx_garages, a walk-in garage system for FiveM.

Getting Started

ktx_garages is a walk-in garage system for FiveM. Players physically enter garage interiors to store, retrieve, and manage their vehicles - no traditional menus. Supports ESX, QBox, QB-Core, and ox_core.

Requirements

  • oxmysql - async MySQL driver
  • ox_lib - utility library (notifications, callbacks, vehicle props)
  • OneSync - must be enabled on your server

Installation

  1. Download from Keymaster
  2. Extract to your server's resources folder
  3. Add to server.cfg

Warning: Load order matters. ox_lib must start before ktx_garages.

ensure ox_lib
ensure ktx_garages

Framework Setup

Open shared/config.lua and set your framework:

Config.GarageSystem = {
    framework = "esx",       -- "esx" | "qb-core" | "qbox" | "ox" | "custom"
    ESXMode = "legacy",      -- "legacy" | "old" (only when framework = "esx")
}

Database Setup

The default database mapping works for QBox and QB-Core:

database = {
    owned_vehicles = {
        table = "player_vehicles",
        identifier = "citizenid",
        vehicle = "mods",
        garage = "garage",
        plate = "plate",
        stored = "state"
    },
    users = {
        table = "players",
        identifier = "citizenid",
        position = "position"
    },
}

For ESX, change the mapping to match ESX's table structure:

database = {
    owned_vehicles = {
        table = "owned_vehicles",
        identifier = "owner",
        vehicle = "vehicle",
        garage = "garage",
        plate = "plate",
        stored = "stored"
    },
    users = {
        table = "users",
        identifier = "identifier",
        position = "position"
    },
}

Note: QBox and QB-Core share the same database mapping. QB-Core uses state values: 0 = out, 1 = garaged, 2 = impound.

First Launch

On first start, these tables are created automatically:

TablePurpose
ktx_garagesGarage ownership records
ktx_garages_builderGarage definitions from the builder
ktx_garages_coownersCo-ownership records
ktx_garages_logsActivity log entries

Use the /garages command in-game to open the builder and create your first garage. Requires admin permissions by default - see Builder Guide for permission setup.