Garry's Mod Wiki

VehicleParamsEngine

Description

The structure used by VehicleParams structure.

Members

number axleRatio
This acts as the final ratio of the gearbox.

It's like a master coefficient of the gearbox.

number boostDelay
Amount of seconds between being able to use the boost ( by pressing Shift key by default )
number boostDuration
Duration of the boost in seconds
number boostMaxSpeed
Maximum speed while boosting
The Vehicle:SetVehicleParams function takes this in miles per hour, but Vehicle:GetVehicleParams returns this in hammer units per second!

In this case HU = inches, so 1 MPH is 17.6 HU/s.

number gearCount
Amount of gears this vehicle has.
table gearRatio
A table of numbers, of gear rations.

Table length is equal to "gearCount" member of this table.

number horsepower
The HP amount of the vehicle

This value is used to calculate the effectively applied torque, along with ratios and maxRPM.

boolean isAutoTransmission
If true, the gearbox shifts gears, if false the gearbox stays stuck to the 1st gear (gear number 0).
number maxRPM
Maximum RPM of the vehicle.

Despite this being a maximum value, the vehicle can exceed it.

Attempts to exceed the max RPM will force the active gear ratio to be that of the 1st gear, which will provide even more torque. This is the opposite of a rev limiter. This value is only used for the calculation of the effectively applied torque.
number maxRevSpeed
Maximum reverse speed of the vehicle
The Vehicle:SetVehicleParams function takes this in miles per hour, but Vehicle:GetVehicleParams returns this in hammer units per second!

In this case HU = inches, so 1 MPH is 17.6 HU/s.

number maxSpeed
Maximum forward going speed of the vehicle without boosting
The Vehicle:SetVehicleParams function takes this in miles per hour, but Vehicle:GetVehicleParams returns this in hammer units per second!

In this case HU = inches, so 1 MPH is 17.6 HU/s.

number shiftDownRPM
Amount of RPM to automatically shift one gear down
number shiftUpRPM
Amount of RPM to automatically shift one gear up