Server-side

Server side exports for OP GARAGES V2

addTempPrivateGarage


exports['op-garages']:addTempPrivateGarage(Label, Type, Coords, Radius, PrivatePlayersList)
  • Label: string

  • Type: car | air | sea

  • Coords: table

    • CenterOfZone: vec4

    • AccessPoint: vec4 (Only whe Type: sea | air)

  • Radius: number

  • PrivatePlayersList: object

    • id: string (Player CitizenID or Char)

    • name: string(Player Name and Lastname, you can leave it "")

This export return created garage id.

Example Usage:

local Coords = {
    CenterOfZone = vec4(-1796.2642, 398.0186, 110.9659, 161.2089),
    AccessPoint = vec4(0.0, 0.0, 0.0, 0.0) -- Leave 0.0 if it's 'car' garage.
}
local PrivatePlayersList = {
    {
        id = "char1:7e0ec7b80d186fd8c29f6631e4377e75812fe8fd",
        name = ""
    }
}
local garageId = exports['op-garages']:addTempPrivateGarage("Bagieta Garage", "car", Coords, 15, PrivatePlayersList)

removeTempPrivateGarage


  • Index: number

Example Usage:

addTempGangGarage


  • Label: string

  • Type: car | air | sea

  • Coords: table

    • CenterOfZone: vec4

    • AccessPoint: vec4 (Only whe Type: sea | air)

  • Radius: number

  • GangName: string

  • GangGrade: number

  • Mode: string: owned | spawner

  • zPoints: table | nil

  • onespawn: vec4 | nil

This export return created garage id.

Example Usage:

removeTempGangGarage


  • Index: number

Example Usage:

getAllGarages


Get List of all Available garages.

Example Returned Data:

getGarageByIndex


Get garage data by index

Example Usage:

Example returned Data:

getAllImpounds


Get List of all Available Impounds.

Example Returned Data:

getImpoundByIndex


Get Impound data by index

Example Usage:

Example returned Data:

getVehiclesLabels


Get Vehicles Custom Labels added through Garage Admin

Example returned Data:

getVehicleLabelByModel


Get Vehicle Custom Label added through Garage Admin by Model

Example Usage:

Example returned Data:

Last updated