Setup & Configuration - TrevorBarns/luxart-vehicle-control GitHub Wiki
Open SETTINGS.lua and configure settings to your liking. Items with prefix/postfix 'default' means the end player will be able to modify/override these later.
A community ID is required for version 3.2.3 and later. This unique set of characters for your community will be used for profile saving.
- The ID should be 4-6 alphanumerical characters however, more should work within reason.
- Spaces are not allowed and will not work, dashes can be used instead.
- Some examples may be your servers abbreviation, name, etc.
-
Examples:
'LCPS'
,'LCPSR'
,'SARP'
,'LSDOJ'
,'JakesRP'
, etc.
-
Examples:
- The purpose of this string is to differentiate the client side saves between servers. Since it is possible (and likely) that servers may use the same profile names, but different profile siren assignments.
-
Example:
John plays on two servers: server1 and server2. Both servers have LVC vehicle profiles 'pd1', but both have different siren configurations. John saves a profile on server1 with siren settings pertaining to tone IDs 1,2,3,4. Then jumps on server2 which has approved tones 6,7,8,9. LVC will display a warning stating that the save is not compatible as tones 1,2,3,4 are not approved in the SIREN_ASSIGNEMENTS. To prevent this we pre/postfix the save string with community_id which ensures the correct profile for the server is loaded.
-
Example:
⚠️ This string should be set once, and never changed as it will result in loss of LVC saves for all players. It is not public facing so even if the server name changes it does not need to change.
Default ID | Generic Name | String | WAV File Name |
---|---|---|---|
1 | Airhorn | SIRENS_AIRHORN | AIRHORN_EQD |
2 | Wail | VEHICLES_HORNS_SIREN_1 | SIREN_PA20A_WAIL |
3 | Yelp | VEHICLES_HORNS_SIREN_2 | SIREN_2 |
4 | Priority | VEHICLES_HORNS_POLICE_WARNING | POLICE_WARNING |
5 | CustomA | RESIDENT_VEHICLES_SIREN_WAIL_01 | SIREN_WAIL_01 |
6 | CustomB | RESIDENT_VEHICLES_SIREN_WAIL_02 | SIREN_WAIL_02 |
7 | CustomC | RESIDENT_VEHICLES_SIREN_WAIL_03 | SIREN_WAIL_03 |
8 | CustomD | RESIDENT_VEHICLES_SIREN_QUICK_01 | SIREN_QUICK_01 |
9 | CustomE | RESIDENT_VEHICLES_SIREN_QUICK_02 | SIREN_QUICK_02 |
10 | CustomF | RESIDENT_VEHICLES_SIREN_QUICK_03 | SIREN_QUICK_03 |
11 | Powercall | VEHICLES_HORNS_AMBULANCE_WARNING | AMBULANCE_WARNING |
12 | FireHorn | VEHICLES_HORNS_FIRETRUCK_WARNING | FIRE_TRUCK_HORN |
13 | Firesiren | RESIDENT_VEHICLES_SIREN_FIRETRUCK_WAIL_01 | SIREN_FIRETRUCK_WAIL_01 |
14 | Firesiren2 | RESIDENT_VEHICLES_SIREN_FIRETRUCK_QUICK_01 | SIREN_FIRETRUCK_QUICK_01 |
SIRENS = {
--[[1]] { Name = "Airhorn", String = "SIRENS_AIRHORN", Ref = 0 }, --1
--[[2]] { Name = "Wail", String = "VEHICLES_HORNS_SIREN_1", Ref = 0 }, --2
--[[3]] { Name = "Yelp", String = "VEHICLES_HORNS_SIREN_2", Ref = 0 }, --3
--[[4]] { Name = "Priority", String = "VEHICLES_HORNS_POLICE_WARNING", Ref = 0 }, --4
--[[5]] { Name = "Futura", String = "RESIDENT_VEHICLES_SIREN_WAIL_01", Ref = 0 }, --5
--[[6]] { Name = "Hetro", String = "RESIDENT_VEHICLES_SIREN_WAIL_02", Ref = 0 }, --6
--[[7]] { Name = "Sweep-1", String = "RESIDENT_VEHICLES_SIREN_WAIL_03", Ref = 0 }, --7
--[[8]] { Name = "Sweep-2", String = "RESIDENT_VEHICLES_SIREN_QUICK_01", Ref = 0 }, --8
--[[9]] { Name = "Hi-Low", String = "RESIDENT_VEHICLES_SIREN_QUICK_02", Ref = 0 }, --9
--[[10]] { Name = "Whine Down", String = "RESIDENT_VEHICLES_SIREN_QUICK_03", Ref = 0 }, --10
--[[11]] { Name = "Powercall", String = "VEHICLES_HORNS_AMBULANCE_WARNING", Ref = 0 }, --11
--[[12]] { Name = "QSiren", String = "VEHICLES_HORNS_FIRETRUCK_WARNING", Ref = 0 }, --12
--[[13]] { Name = "Fire Yelp", String = "RESIDENT_VEHICLES_SIREN_FIRETRUCK_WAIL_01", Ref = 0 }, --13
--[[14]] { Name = "Fire Yelp", String = "RESIDENT_VEHICLES_SIREN_FIRETRUCK_QUICK_01", Ref = 0 }, --14
}
- For most users,
Name
is the only field that needs to be modified. It determines the default name for each tone and will be displayed in LVC Menu, these can be generic like "Siren 1, Siren 2, etc." or specific based on departments recommended siren. The end user will be able to change these. - For advanced users:
-
String
andRef
can be changed to change which audio file is pulled based on tone. Rearranging default resident.rpf names is not recommended as it serves no benefit. Instead rearranging the siren assignments order would be easier. The only time changingString
andRef
would be recommended is for integration of server side siren integration. See Server Sided Audio Integration. -
Option
an additional key can be added to each tones table determines the default option state that each tone is in. The end user can change these later.
Example:{ Name = "CustomName", String = "SIREN_STRING", Ref = 0, Option = 1 },
Option Value Behavior 1 Cycle & Button 2 Cycle Only 3 Button Only 4 Disabled
-
SIREN_ASSIGNMENTS = {
--['<gameName>'] = { <airhorn tone>, <siren tone-1>, <siren tone-2>, ... <siren tone-n> },
['DEFAULT'] = { 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 },
['FIRETRUK'] = { 12, 13, 14, 11 },
['AMBULAN'] = { 1, 2, 3, 4, 11 },
['LGUARD'] = { 1, 2, 3, 4, 11 },
}
['DEFAULT']
should always be present and never removed. Doing so will result in issues.
- In this table you can add additional vehicles for assignment using the vehicles
<gameName>
exactly as found invehicles.meta
. It is case sensitive.
- Both R* and LVC however, truncate down to 11 characters. It is important that the first 11 characters are unique.
-
Example:
If my addon vehicles<gameName>
is "2008 Ford CVPI CHP" and I have another vehicle "2008 Ford CVPI LSPD" both of these after truncate equate to "2008 Ford C" therefor LVC will not be able to differentiate these. A more appropriate name may be "LSPDCVPI1". Of course the naming convention is going to be highly dependent on the number of vehicles you have.
-
Example:
- In the example above, you can see that the first tone in the vehicles tone table tells LVC what to use as a horn, followed by a number of sirens.
Supported Wildcards:
-
#
represents 1 or more digits.
How it works:
- LVC checks for vehicle profile matching game name. e.g.
['2008fpiu1']
- If not found, attempts wildcard search, meaning wildcards will be used secondary to custom profiles. e.g.
['2008fpiu#']
- If not found, attempts a less specific wildcard search, leading and trailing numbers. e.g.
['#fpiu#']
(v3.2.7) - If not found, use default profile. e.g.
['DEFAULT']
Example:
* ['veh#'] = { ... }
will be used for vehicles with game names veh1
, veh2
, ..., veh9999
, etc. where exact profile not found.
Examples and premade packs can be found here: https://github.com/TrevorBarns/luxart-vehicle-control-extras/
-
experimental
will mute experimental messages for server console. -
debug_mode
increases console logging for client, prints <gameName> of vehicle if no profile was found.
Toggling these require the refresh
command to be ran first, then restart the resource for changes to take effect.