fivem-ts

a library to speed up the development of Fivem scripts and frameworks


Project maintained by Purpose-Dev Hosted on GitHub Pages — Theme by mattgraham

fivem-ts - Documentation v0.7.5Docs


fivem-ts - Documentation v0.7.5 / Client / VehicleWheelCollection

Class: VehicleWheelCollection

The VehicleWheelCollection class manages a collection of wheels associated with a vehicle. It provides utility functions to retrieve, burst, fix, and check the existence of wheels.

Constructors

new VehicleWheelCollection()

new VehicleWheelCollection(owner): VehicleWheelCollection

Parameters

owner: Vehicle

Returns

VehicleWheelCollection

Defined in

client/models/VehicleWheelCollection.ts:11

Accessors

Owner

get Owner(): Vehicle

Returns

Vehicle

Defined in

client/models/VehicleWheelCollection.ts:13


VehicleWheels

get VehicleWheels(): Map<number, VehicleWheel>

Returns

Map<number, VehicleWheel>

Defined in

client/models/VehicleWheelCollection.ts:17

Methods

burstAllWheels()

burstAllWheels(): void

Bursts all the wheels of the vehicle.

Iterates through each wheel in the vehicle’s list of wheels and calls the burst method on them.

Returns

void

Defined in

client/models/VehicleWheelCollection.ts:60


fixAllWheels()

fixAllWheels(): void

Repairs all wheels of the vehicle by invoking the fix method on each wheel.

Returns

void

Defined in

client/models/VehicleWheelCollection.ts:71


getAllVehicles()

getAllVehicles(): VehicleWheel[]

Retrieves an array of all vehicles that have wheels attached.

Returns

VehicleWheel[]

An array containing the vehicles with wheels attached.

Defined in

client/models/VehicleWheelCollection.ts:40


getWheel()

getWheel(index): VehicleWheel

Retrieves the wheel of the vehicle at the specified index.

Parameters

index: VehicleWheelIndex

The index of the wheel to retrieve.

Returns

VehicleWheel

The wheel at the specified index.

Defined in

client/models/VehicleWheelCollection.ts:28


hasWheel()

hasWheel(wheel): boolean

Checks if the vehicle has a specified wheel.

Parameters

wheel: VehicleWheelIndex

The index of the wheel to check.

Returns

boolean

Defined in

client/models/VehicleWheelCollection.ts:84