Skip to content

Exports (client)#

GetVehicleDeformation#

Gets the vehicles deformation in a table.

Parameters:
vehicle - number - The handle of the vehicle.

Returns:
table<table<offset: vector3, damage: number>> - List of offsets from the vehicle and the relative damage.

local deformation = exports["VehicleDeformation"]:GetVehicleDeformation(vehicle)

SetVehicleDeformation#

Sets the deformation on a vehicle.

Parameters:
vehicle - number - The handle of the vehicle.
deformation - table<table<offset: vector3, damage: vector3>> - The deformation values.

exports["VehicleDeformation"]:GetVehicleDeformation(vehicle, deformation)

FixVehicleDeformation#

Fixes the deformation of a vehicle.

Parameters:
vehicle - number - The handle of the vehicle.

exports["VehicleDeformation"]:FixVehicleDeformation(vehicle)

IsDeformationWorse#

Compares both deformation tables and returns if the first one is worse than the second.

Parameters:
firstDeformation - table<table<offset: vector3, damage: number>> - The first deformation table.
secondDeformation - table<table<offset: vector3, damage: number>> - The second deformation table.

Returns:
bool - True if the first deformation is worse than the second one.

local isWorse = exports["VehicleDeformation"]:IsDeformationWorse(firstDeformation, secondDeformation)

IsDeformationEqual#

Compares both deformation tables and returns if they are equal.

Parameters:
firstDeformation - table<table<offset: vector3, damage: number>> - The first deformation table.
secondDeformation - table<table<offset: vector3, damage: number>> - The second deformation table.

Returns:
bool - True if both deformation tables are equal.

local isWorse = exports["VehicleDeformation"]:IsDeformationEqual(firstDeformation, secondDeformation)

GetDeformationOffsets(vehicle)#

Returns all offsets for a specified vehicle

Parameters:
vehicle - number - The handle of the vehicle.

Returns:
table<vector3> - A table containing all offsets around a vehicle.

local offsets = exports["VehicleDeformation"]:GetDeformationOffsets(vehicle)