Introduction
Hello Forums,
My name is Serena and I am here to help with fixing YOUR Emergency Lights this can either be because they are really DIM or they are all over the place and broken.
This is an really badly broken light system so how to fix this? I personally have had little broken lights in my server how-ever sometimes a vehicle will break when you add TO MUCH light to the server this can be by adding new vehicles or replacing vehicles.
Fixing Process
The fixing process doesn’t take to long but you just need to know what you are doing. Which for some that do NOT code can be hard to do. So let’s get in the 2 Sections that we will be covering. Dim lights (Barely to no glow) & Broken Lights (They are not on places supposed to be).
Dim Lights
Dim lights are an easy issue to fix you can install any visual pack or even a server sided visual pack. I personally always had ran a client side visual pack because if the way I play GTA but you can put it in your server to! Here is the code to make YOUR lights brighter in your server.
visualsettings.dat
car.headlight.day.emissive.on 180.00
car.headlight.night.emissive.on 105.00
car.headlight.day.emissive.off 0.000
car.headlight.night.emissive.off 0.000
car.taillight.day.emissive.on 200.0
car.taillight.night.emissive.on 150.0
car.taillight.day.emissive.off 0.00
car.taillight.night.emissive.off 0.000
car.indicator.day.emissive.on 250.00
car.indicator.night.emissive.on 220.00
car.indicator.day.emissive.off 0.00
car.indicator.night.emissive.off 0.000
car.reversinglight.day.emissive.on 35.00
car.reversinglight.night.emissive.on 15.00
car.reversinglight.day.emissive.off 0.000
car.reversinglight.night.emissive.off 0.000
car.defaultlight.day.emissive.on 2300.00
car.defaultlight.night.emissive.on 1500.00
car.defaultlight.day.emissive.off 0.00
car.defaultlight.night.emissive.off 0.000
car.brakelight.day.emissive.on 240.00
car.brakelight.night.emissive.on 180.00
car.brakelight.day.emissive.off 0.00
car.brakelight.night.emissive.off 0.000
car.middlebrakelight.day.emissive.on 210.00
car.middlebrakelight.night.emissive.on 160.00
car.middlebrakelight.day.emissive.off 0.00
car.middlebrakelight.night.emissive.off 0.000
car.extralight.day.emissive.on 350.00
car.extralight.night.emissive.on 160.00
car.extralight.day.emissive.off 0.000
car.extralight.night.emissive.off 0.00
car.emissiveMultiplier 2.00
client.lua
function stringsplit(inputstr, sep)
if sep == nil then
sep = "%s"
end
local t={} ; i=1
for str in string.gmatch(inputstr, "([^"..sep.."]+)") do
t[i] = str
i = i + 1
end
return t
end
local function starts_with(str, start)
return str:sub(1, #start) == start
end
Citizen.CreateThread(function()
local settingsFile = LoadResourceFile(GetCurrentResourceName(), "visualsettings.dat")
local lines = stringsplit(settingsFile, "\n")
for k,v in ipairs(lines) do
if not starts_with(v, '#') and not starts_with(v, '//') and (v ~= "" or v ~= " ") and #v > 1 then
v = v:gsub("%s+", " ")
local setting = stringsplit(v, " ")
if setting[1] ~= nil and setting[2] ~= nil and tonumber(setting[2]) ~= nil then
if setting[1] ~= 'weather.CycleDuration' then
Citizen.InvokeNative(GetHashKey('SET_VISUAL_SETTING_FLOAT') & 0xFFFFFFFF, setting[1], tonumber(setting[2])+.0)
end
end
end
end
end)
resource.lua
files {
'visualsettings.dat'
}
client_script ‘client.lua’
So if you make a folder called visuals
in your resources
folder then add it to the server.cfg it will load and your lights will be brighter!
Vehicles Broken
Broken Lights are a common issue when installing LEO packs or EMS or any light pack that you can think off. Sometimes the codes of these ligths may interfere with othes and so they will break because 1 light takes priority over the other. How this works in a whole I am unsure about… But here is a quick guide.
- You open the folder of the vehicle that has broken lights.
- You open both the
carcols.meta
&carvariations.meta
Files.
- We will explain both files in it’s own section.
carcols
- You look for the vehicle that has the broken lights.
- You locate this line
<id value="2101"/>
it always consists of a number. - You change this number to a random 6 string line. It would look like
<id value="923478"/>
for example. DO NOT Repeat already used numbers<id value="425133"/>
Is invalid. - Save he file and go to
carvariations
carvariations
- You look for the vehicle like before.
- You locate this link
<sirenSettings value="2101"/>
of the vehicle that has the broken lights. - You change the number in the
sirenSettings value
to be the same as in thecarcols.meta
- Save the file and restart the resource.
If you did all steps correctly and restart the resource it may be fixed if it did not you may try again. For more info refer to below.
Other Details
It may take a few tries for the ligths to correctly fall in place again. I do NOT know why this is. All I know is that it sometimes may happen. Just restarting the resource is enough there is no need for a full server restart. There have only been 2 vehicles I had to remove due to it not wanting to fix.
Personally to view all these files I use Visual Studio Code. A good alternative is Notepad++
Video!
Here is the video guide!
As of 10:07 +2 4th of march.
(This video may still be procesing.)
CREDITS
I can not remember who made this pack please contact me if you are the creator and I will credit you!