Server Exports

Use these exports to interact with the garage system from other server-side scripts.

Player Data Exports

GetPlayerData

Returns formatted player data for a specific source.

local PlayerData = exports['kartik-garages']:GetPlayerData(source)

GetPlayerByCitizenId

Returns data for an online player by their citizen ID.

local PlayerData = exports['kartik-garages']:GetPlayerByCitizenId("CITIZEN1")

GetOfflinePlayerByCitizenId

Returns data for a player by their citizen ID, even if they are offline.

local PlayerData = exports['kartik-garages']:GetOfflinePlayerByCitizenId("CITIZEN1")

Banking & Transactions

AddPlayerBank

Adds money to a player's bank account.

RemovePlayerBank

Removes money from a player's bank account.

AddPlayerCash

Adds cash to a player.

RemovePlayerCash

Removes cash from a player.


Vehicle Management

InsertVehicleIntoDB

Manually inserts a vehicle into the player_vehicles table.

fetchPlate

Checks if a plate already exists in the database.


Utility Exports

GetCopCount

Returns the current number of police officers online and on duty.

GetGroupMembers

Returns a list of members for a specific gang/group.

Last updated