Tuning

JG Mechanic includes powerful custom tuning functionality, such as engine swaps, custom drivetrains, traction options and more. These options allow you to take roleplay to a whole new level, creating options not previously available as part of the base GTA game.

These options directly modify the vehicle's handling file; which can be complex. We provide a suite of default custom tuning options that will be appealing to most players, but you may want to create your own. If you don't have any understanding of how handling files work, you will likely run into problems.

All customisation is done in config/config.tuning.lua. This docs page is designed to be an FAQ for this file, so you can get to creating your own custom tuning options as soon as possible.

I did an engine swap, why is my vehicle slower?

The script is not broken, this functionality modifies the vehicle's handling file, and some vehicles can have wildly different handling files. The default configured handling changes, therefore, don't work well on all vehicles. They have been specifically tuned for the vanilla GTA vehicles.

This typically happens with addon vehicles, when their handling file is unbalanced. By default, our engine swaps overwrite certain handling values (see below). If some of the values modified as part of the swap were set too high in the vehicle's base handling file to compensate for other values that were set improperly, this can actually make your vehicle slower.

In these cases, unfortunately it is up to you to modify config.tuning.lua to make the handling changes more appropriate for the vehicles in your server. Or, what we would recommend more, is to improve the handling files of the addon vehicles in your server.

What do the different config options mean?

Parameter
Explanation

name

The name of the modification that will be shown in the tablet.

info (optional)

Optional, but you can provide additional info that will show in the UI when clicking the info icon when they are selecting an upgrade. It could be used to warn mechanics of vehicles an upgrade shouldn't be applied on, or results from your testing of handling values.

itemName

For mechanics set up to use an item for upgrades, this is the name of the required item.

price

For mechanics set up to purchase upgrades, this will be the cost to the mechanic to apply the upgrade.

audioNameHash

Any in-game vehicle name, or addon sound pack name (ENGINE SWAPS ONLY!)

handling

Add/remove handling attributes & values. More help & info on handling values: https://gtamods.com/wiki/Handling.meta

handlingApplyOrder

The order in which this tuning option should be applied. This is useful when tuning options have overlapping handling values! Provide a priority number, and the lowest numbers will be applied first.

handlingOverwritesValues

Whether the handling values provided should overwrite the vehicle's existing values, or whether they should modify the vehicle's existing values. This also works for negative values too.

For example: a vehicle's current fDriveInertia value is at 1.0.

  • Set to "true" and a value of 0.5 sets fDriveInertia to 0.5.

  • Set to "false", and a value of 0.5 will mean [1.0 + 0.5] and set fDriveInertia to 1.5

restricted

Can either be false (unrestricted) "electric" or "combustion"

blacklist

List of archetype names (spawn codes) that cannot use this modification

Last updated