Configuration
Torches uses a config.json
file to store config values. Invalid JSON syntax in this file will cause errors.
Value List
Name | Default Value |
---|---|
allowAnyPed | false |
torchesDistance | 30 |
torchesBrightness | 1.5 |
torchesRoundness | 0.5 |
torchesRadius | 20 |
torchesFallOff | 100 |
command | torch |
defaultKeybind | None |
defaults | See Below |
peds | See Below |
mppeds | See Below |
Values Explained
Allow Any Ped
allowAnyPed
If this value is false
, only preconfigured Peds and MP Peds will be able to use Torches.
If this value is true
, any Ped or MP Ped can use Torches. Where no preset exists, defaults will be used.
Torch Distance
torchDistance
This value controls the distance a Torch will be drawn with.
Torch Brightness
torchBrightness
This value controls the brightness a Torch will be drawn with.
Torch Roundness
torchRoundness
This value controls the roundness a Torch will be drawn with.
Torch Radius
torchRadius
This value controls the radius a Torch will be drawn with.
Torch Falloff
torchFallOff
This value controls the falloff a Torch will be drawn with.
Command
Command
The name of the command.
Default Keybind
defaultKeybind
The keyboard mapping name for the key to use for the keybind.
For a full list of options, see here.
By default, no default is provided, meaning there is no keybind.
Players can add one via their GTA V/FiveM Keybind Settings
Defaults
defaults
The values listed in the defaults
are values used when no other matching preset can be found.
There are two default entries, one for head
and one for chest
.
Changing these values will change the default torch positions on a ped.
Peds
peds
This config option is where you list presets for non-MP Peds, such as base game peds or addon peds.
Unlike MP Peds, this config option is not split into Male and Female.
Entries for this config option can be created in-game using the Tool. See here for more info.
Below is an example of an entry:
{
"model": "s_m_y_fireman_01",
"mountType": "Chest",
"source": {
"X": 0.16,
"Y": 0.212,
"Z": 0.148
},
"corona": {
"X": 0.16,
"Y": 0.212,
"Z": 0.148
}
}
model
is the spawn name of the modelmountType
is eitherhead
orchest
source
is a Vector3 offset from the ped for where the torch's light source should appear fromcorona
is a Vector3 offset from the ped for where the torch's corona should appear from
MP Peds
mppeds
This config option is where you list presets for MP Peds.
This config option is split into Male and Female.
Entries for this config option can be created in-game using the Tool. See here for more info.
Below is an example of an entry:
{
"collectionName": "mp_m_smuggler_01",
"localIndex": 6,
"isProp": true,
"variationId": 0,
"mountType": "Head",
"source": {
"X": 0.15,
"Y": 0,
"Z": 0.15
},
"corona": {
"X": 0.148,
"Y": 0.0735,
"Z": 0.115
}
}
collectionName
is the cloth collection the preset item is set tolocalIndex
is the local id of the selected cloth item within the selected collectionisProp
istrue
if using a prop, orfalse
if using a componentvariationId
is the type of prop or component of the preset itemmountType
is eitherhead
orchest
source
is a Vector3 offset from the ped for where the torch's light source should appear fromcorona
is a Vector3 offset from the ped for where the torch's corona should appear from
Default Config File
{
"allowAnyPed": false,
"torchDistance": "30",
"torchBrightness": "1.5",
"torchRoundness": "0.5",
"torchRadius": "20",
"torchFallOff": "100",
"command": "torch",
"defaultKeybind": "",
"defaults": {
"head": {
"source": {
"X": 0.15,
"Y": 0,
"Z": -0.15
},
"corona": {
"X": 0.15,
"Y": 0,
"Z": -0.15
}
},
"chest": {
"source": {
"X": 0.16,
"Y": 0.225,
"Z": 0.15
},
"corona": {
"X": 0.16,
"Y": 0.2,
"Z": 0.15
}
}
},
"peds": [
{
"model": "s_m_y_fireman_01",
"mountType": "Chest",
"source": {
"X": 0.16,
"Y": 0.212,
"Z": 0.148
},
"corona": {
"X": 0.16,
"Y": 0.212,
"Z": 0.148
}
}
],
"mppeds": {
"male": [
{
"collectionName": "mp_m_smuggler_01",
"localIndex": 6,
"isProp": true,
"variationId": 0,
"mountType": "Head",
"source": {
"X": 0.15,
"Y": 0,
"Z": 0.15
},
"corona": {
"X": 0.148,
"Y": 0.0735,
"Z": 0.115
}
},
{
"collectionName": "mp_m_heist3",
"localIndex": 0,
"isProp": false,
"variationId": 8,
"mountType": "Chest",
"source": {
"X": 0.157,
"Y": 0.22,
"Z": 0.15
},
"corona": {
"X": 0.157,
"Y": 0.215,
"Z": 0.15
}
}
],
"female": [
{
"CollectionName": "mp_f_smuggler_01",
"LocalIndex": 6,
"IsProp": true,
"VariationId": 0,
"MountType": "Head",
"Source": {
"X": 0.1475,
"Y": 0.0575,
"Z": 0.1199
},
"Corona": {
"X": 0.1475,
"Y": 0.0525,
"Z": 0.1199
}
},
{
"collectionName": "mp_f_heist3",
"localIndex": 0,
"isProp": false,
"variationId": 8,
"mountType": "Chest",
"source": {
"X": 0.155,
"Y": 0.222,
"Z": 0.15
},
"corona": {
"X": 0.155,
"Y": 0.217,
"Z": 0.15
}
}
]
}
}